We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 70f681d commit 348db73Copy full SHA for 348db73
R/testthat-helpers.R
@@ -1,5 +1,5 @@
1
all_attr_but_dim <- function(object, expected) {
2
- ignore_attr <- names(attributes(object))
+ ignore_attr <- as.character(names(attributes(object)))
3
ignore_attr <- c(ignore_attr, names(attributes(expected)))
4
ignore_attr[ignore_attr != "dim"]
5
}
@@ -38,6 +38,8 @@ expect_roughly <- function(object,
38
expected.label = NULL) {
39
if (is.null(ignore_attr)) {
40
ignore_attr <- all_attr_but_dim(object, expected)
41
+ } else {
42
+ ignore_attr <- FALSE
43
44
45
testthat::expect_equal(
0 commit comments