CRAN Package Check Results for Package backports

Last updated on 2024-03-28 07:52:44 CET.

Flavor Version Tinstall Tcheck Ttotal Status Flags
r-devel-linux-x86_64-debian-clang 1.4.1 4.32 37.88 42.20 OK
r-devel-linux-x86_64-debian-gcc 1.4.1 2.97 30.30 33.27 OK
r-devel-linux-x86_64-fedora-clang 1.4.1 56.19 OK
r-devel-linux-x86_64-fedora-gcc 1.4.1 54.10 OK
r-devel-windows-x86_64 1.4.1 9.00 3615.00 3624.00 ERROR
r-patched-linux-x86_64 1.4.1 4.26 37.57 41.83 OK
r-release-linux-x86_64 1.4.1 3.94 38.32 42.26 OK
r-release-macos-arm64 1.4.1 26.00 OK
r-release-macos-x86_64 1.4.1 4.00 OK
r-release-windows-x86_64 1.4.1 8.00 61.00 69.00 OK
r-oldrel-macos-arm64 1.4.1 23.00 OK
r-oldrel-windows-x86_64 1.4.1 12.00 72.00 84.00 OK

Check Details

Version: 1.4.1
Check: tests
Result: ERROR Running 'test_R_user_dir.R' [0s] Running 'test_URLencode.R' [165s] Running 'test_anyNA.R' [164s] Running 'test_asplit.R' [157s] Running 'test_capture.output.R' [0s] Running 'test_dQuote.R' [156s] Running 'test_deparse1.R' [154s] Running 'test_dir.exists.R' [151s] Running 'test_dotsElt.R' [165s] Running 'test_dotsLength.R' [169s] Running 'test_dotsNames.R' [166s] Running 'test_file.info.R' [170s] Running 'test_file.mode.R' [0s] Running 'test_file.mtime.R' [155s] Running 'test_file.size.R' [0s] Running 'test_get0.R' [0s] Running 'test_hasName.R' [157s] Running 'test_isFALSE.R' [0s] Running 'test_isNamespaceLoaded.R' [156s] Running 'test_isTRUE.R' [153s] Running 'test_lengths.R' [176s] Running 'test_list2DF.R' [177s] Running 'test_paste.R' [173s] Running 'test_removeSource.R' [0s] Running 'test_startsWith.R' [160s] Running 'test_stopifnot.R' [158s] Running 'test_str2expression.R' [158s] Running 'test_str2lang.R' [173s] Running 'test_strrep.R' [0s] Running 'test_suppressWarnings.R' [0s] Running 'test_trimws.R' [0s] Running 'test_valid.factor.R' [156s] Running 'test_warningCondition.R' [0s] Running the tests in 'tests/test_URLencode.R' failed. Complete output: > source("helper/helper.R") > > f = get("URLencode", envir = getNamespace("utils")) > z = "ab%20cd" > expect_identical(backports:::URLencode(z, repeated = TRUE), "ab%2520cd") > > if (getRversion() >= "3.2.0") { + expect_same = makeCompareFun(f, backports:::URLencode) + expect_same(z) + expect_same(z, repeated = FALSE) + expect_same(z, repeated = TRUE) + } else { + expect_identical(f(z), backports:::URLencode(z, repeated = TRUE)) + } > > proc.time() user system elapsed 0.17 0.09 0.25 Running the tests in 'tests/test_anyNA.R' failed. Complete output: > source("helper/helper.R") > > if (exists("anyNA", envir = baseenv())) { + f = get("anyNA", envir = baseenv()) + expect_same = makeCompareFun(f, backports:::anyNA) + + expect_same(1) + expect_same(NA) + expect_same(iris) + if (getRversion() >= "3.2.0") { + expect_same(list(1, 2, list(3, 4, list(NA))), recursive = FALSE) + expect_same(list(1, 2, list(3, 4, list(NA))), recursive = TRUE) + } + } > > proc.time() user system elapsed 0.20 0.04 0.23 Running the tests in 'tests/test_asplit.R' failed. Complete output: > source("helper/helper.R") > > if (exists("asplit", envir = baseenv())) { + f = get("asplit", envir = baseenv()) + expect_same = makeCompareFun(f, backports:::asplit) + + d <- 2 : 4 + x <- array(seq_len(prod(d)), d) + expect_same(x, 2) + expect_same(x, c(1, 2)) + x <- matrix(1 : 6, 2, 3) + expect_same(x, 1) + } > > proc.time() user system elapsed 0.21 0.01 0.21 Running the tests in 'tests/test_dQuote.R' failed. Complete output: > source("helper/helper.R") > > f = get("dQuote", envir = baseenv()) > expect_same = makeCompareFun(f, backports:::dQuote) > > expect_same("foo") > if (getRversion() >= "3.6.0") { + expect_same("foo", q = TRUE) + expect_same("foo", q = FALSE) + } > > > f = get("sQuote", envir = baseenv()) > expect_same = makeCompareFun(f, backports:::sQuote) > > expect_same("foo") > if (getRversion() > "3.6.0") { + expect_same("foo", q = TRUE) + expect_same("foo", q = FALSE) + } > > proc.time() user system elapsed 0.14 0.12 0.25 Running the tests in 'tests/test_deparse1.R' failed. Complete output: > source("helper/helper.R") > > if (exists("deparse1", envir = baseenv())) { + f = get("deparse1", envir = baseenv()) + expect_same = makeCompareFun(f, backports:::deparse1) + + expect_same(args(stats::lm)) + e = quote(`foo bar`) + expect_same(e) + expect_same(e, backtick = TRUE) + e = quote(`foo bar`+1) + expect_same(e) + expect_same(e, control = "all") + + } > > proc.time() user system elapsed 0.21 0.06 0.26 Running the tests in 'tests/test_dir.exists.R' failed. Complete output: > source("helper/helper.R") > > if (exists("dir.exists", envir = baseenv())) { + f = get("dir.exists", envir = baseenv()) + expect_same = makeCompareFun(f, backports:::dir.exists) + + expect_same(tempdir()) + expect_same(tempfile()) + expect_same(rep.int(tempdir(), 2)) + expect_same(TRUE) + } > > proc.time() user system elapsed 0.14 0.07 0.20 Running the tests in 'tests/test_dotsElt.R' failed. Complete output: > source("helper/helper.R") > > wb = function(n, ...) backports:::...elt(n) > > if (exists("...elt", envir = baseenv())) { + f = get("...elt", envir = baseenv()) + wf = function(n, ...) f(n) + expect_same = makeCompareFun(wf, wb) + + expect_same(1, 1, 2, 3) + expect_same(2, 1, 2, 3) + expect_same(3, 1, 2, 3) + } > > expect_identical(wb(1, "a", "b", "c"), "a") > expect_identical(wb(2, "a", "b", "c"), "b") > expect_identical(wb(3, "a", "b", "c"), "c") > expect_error(wb(0, "a"), "non-positive") > expect_error(wb(2, "a"), "does not contain") > > proc.time() user system elapsed 0.20 0.07 0.25 Running the tests in 'tests/test_dotsLength.R' failed. Complete output: > source("helper/helper.R") > > wb = function(...) backports:::...length() > > if (exists("...length", envir = baseenv())) { + f = get("...length", envir = baseenv()) + wf = function(...) f() + expect_same = makeCompareFun(wf, wb) + + expect_same(1) + expect_same(1, 2) + expect_same() + } > > expect_identical(wb(1, "a", "b", "c"), 4L) > expect_identical(wb(2, "a", "b"), 3L) > expect_identical(wb(1), 1L) > expect_identical(wb(), 0L) > > f = function(n) backports:::...length() > expect_error(f(), "current call") > expect_error(f(1), "current call") > > proc.time() user system elapsed 0.23 0.07 0.29 Running the tests in 'tests/test_dotsNames.R' failed. Complete output: > source("helper/helper.R") > > wb = function(...) backports:::...names() > > if (exists("...names", envir = baseenv()) && getRversion() > "4.1.2") { + f = get("...names", envir = baseenv()) + wf = function(...) f() + expect_same = makeCompareFun(wf, wb) + + expect_same(1, 2) + expect_same(a = 1) + expect_same(1, b = 2) + expect_same() + + expect_identical(wb(a = 1, 2), c("a", "")) + } > > expect_identical(wb(a = 1, b = 2), c("a", "b")) > > proc.time() user system elapsed 0.21 0.07 0.28 Running the tests in 'tests/test_file.info.R' failed. Complete output: > source("helper/helper.R") > > x = tempdir() > res1 = backports:::file.info(x, extra_cols = TRUE) > res2 = backports:::file.info(x, extra_cols = FALSE) > stopifnot(is.data.frame(res1), nrow(res1) == 1L, ncol(res1) >= 7L) > stopifnot(is.data.frame(res2), nrow(res2) == 1L, ncol(res2) == 6L) > > expect_identical(res1, base::file.info(x)) > expect_identical(res1[, 1:6, drop = FALSE], res2) > > proc.time() user system elapsed 0.20 0.06 0.25 Running the tests in 'tests/test_file.mtime.R' failed. Complete output: > source("helper/helper.R") > > if (exists("file.mtime", envir = baseenv())) { + f = get("file.mtime", envir = baseenv()) + expect_same = makeCompareFun(f, backports:::file.mtime) + + expect_same(R.home()) + expect_same(file.path(R.home(), "COPYING")) + } > > proc.time() user system elapsed 0.21 0.06 0.21 Running the tests in 'tests/test_hasName.R' failed. Complete output: > source("helper/helper.R") > > if (exists("hasName", envir = getNamespace("utils"))) { + f = get("hasName", envir = getNamespace("utils")) + expect_same = makeCompareFun(f, backports:::hasName) + + x = list(1, a = 12, bbb = 99) + expect_same(x, "a") + expect_same(x, "c") + expect_same(x, "bbb") + expect_same(x, "b") + } > > proc.time() user system elapsed 0.17 0.10 0.21 Running the tests in 'tests/test_isNamespaceLoaded.R' failed. Complete output: > source("helper/helper.R") > > expect_true(isNamespaceLoaded("base")) > expect_true(isNamespaceLoaded("backports")) > expect_false(isNamespaceLoaded("..notexisting..")) > > proc.time() user system elapsed 0.18 0.06 0.23 Running the tests in 'tests/test_isTRUE.R' failed. Complete output: > source("helper/helper.R") > > f = backports:::isTRUE > expect_identical(f(TRUE), TRUE) > expect_identical(f(FALSE), FALSE) > expect_identical(f(1), FALSE) > expect_identical(f(iris), FALSE) > expect_identical(f(structure(TRUE, foo = "bar")), TRUE) > > proc.time() user system elapsed 0.17 0.09 0.25 Running the tests in 'tests/test_lengths.R' failed. Complete output: > source("helper/helper.R") > > if (exists("lengths", envir = baseenv())) { + f = get("lengths", envir = baseenv()) + expect_same = makeCompareFun(f, backports:::lengths) + + expect_same(1:3) + expect_same(setNames(1:3, letters[1:3])) + expect_same(setNames(1:3, letters[1:3]), use.names = FALSE) + expect_same(iris) + } > > proc.time() user system elapsed 0.15 0.10 0.25 Running the tests in 'tests/test_list2DF.R' failed. Complete output: > source("helper/helper.R") > > if (exists("list2DF", envir = baseenv())) { + f = get("list2DF", envir = baseenv()) + expect_same = makeCompareFun(f, backports:::list2DF) + + x <- list(c("A", "B"), c("B", "C")) + n <- lengths(x) + expect_same(list(x = x, n = n)) + + ## Create data frames with no variables and the desired number of rows: + expect_same() + expect_same(nrow = 3L) + } > > proc.time() user system elapsed 0.21 0.04 0.25 Running the tests in 'tests/test_paste.R' failed. Complete output: > source("helper/helper.R") > > if (getRversion() >= "4.0.0") { + + f = get("paste", envir = baseenv()) + expect_same = makeCompareFun(f, backports:::paste) + + expect_same(letters[1:3], character()) + expect_same(letters[1:3], character(), recycle0 = TRUE) + expect_same(letters[1:3], character(), sep = "_", recycle0 = TRUE) + expect_same(letters[1:3], character(), sep = "_", collapse = "+", recycle0 = TRUE) + expect_same(letters[1:3], character(), collapse = NULL, recycle0 = TRUE) + expect_same(letters[1:3], character(), sep = NULL, recycle0 = TRUE) + expect_same(letters[1:3], character(), sep = NULL, collapse = NULL, recycle0 = TRUE) + expect_same(letters[1:3], character(), sep = character(), collapse = character(), recycle0 = TRUE) + + expect_same(character()) + expect_same(character(), recycle0 = TRUE) + expect_same(character(), sep = "_", recycle0 = TRUE) + expect_same(character(), sep = "_", collapse = "+", recycle0 = TRUE) + expect_same(character(), collapse = NULL, recycle0 = TRUE) + expect_same(character(), sep = NULL, recycle0 = TRUE) + expect_same(character(), sep = NULL, collapse = NULL, recycle0 = TRUE) + expect_same(character(), sep = character(), collapse = character(), recycle0 = TRUE) + + + + f = get("paste0", envir = baseenv()) + expect_same = makeCompareFun(f, backports:::paste0) + + expect_same(letters[1:3], character()) + expect_same(letters[1:3], character(), recycle0 = TRUE) + expect_same(letters[1:3], character(), recycle0 = TRUE) + expect_same(letters[1:3], character(), collapse = "+", recycle0 = TRUE) + expect_same(letters[1:3], character(), collapse = NULL, recycle0 = TRUE) + expect_same(letters[1:3], character(), collapse = NULL, recycle0 = TRUE) + expect_same(letters[1:3], character(), collapse = character(), recycle0 = TRUE) + + expect_same(character()) + expect_same(character(), recycle0 = TRUE) + expect_same(character(), recycle0 = TRUE) + expect_same(character(), collapse = "+", recycle0 = TRUE) + expect_same(character(), collapse = NULL, recycle0 = TRUE) + expect_same(character(), collapse = NULL, recycle0 = TRUE) + expect_same(character(), collapse = character(), recycle0 = TRUE) + } > > expect_identical( + paste(letters[1:3], character(), collapse = NULL, recycle0 = TRUE), + character() + ) > > expect_identical( + paste(letters[1:3], character(), collapse = "_", recycle0 = TRUE), + "" + ) > > expect_identical( + paste0(letters[1:3], character(), collapse = NULL, recycle0 = TRUE), + character() + ) > > expect_identical( + paste0(letters[1:3], character(), collapse = "_", recycle0 = TRUE), + "" + ) > > proc.time() user system elapsed 0.20 0.06 0.26 Running the tests in 'tests/test_startsWith.R' failed. Complete output: > source("helper/helper.R") > > if (exists("startsWith", envir = baseenv())) { + f = get("startsWith", envir = baseenv()) + expect_same = makeCompareFun(f, backports:::startsWith) + + expect_same("a", "a") + expect_same(NA, "a") + expect_same("a", NA) + expect_same("a", "") + expect_same("", "a") + expect_same("", "") + expect_same(c("a", NA, "b"), "b") + expect_same("b", c("a", NA, "b")) + expect_same(letters, c("m", NA, "")) + } > > if (exists("endsWith", envir = baseenv())) { + f = get("endsWith", envir = baseenv()) + expect_same = makeCompareFun(f, backports:::endsWith) + + expect_same("a", "a") + expect_same(NA, "a") + expect_same("a", NA) + expect_same("a", "") + expect_same("", "a") + expect_same("", "") + expect_same(c("a", NA, "b"), "b") + expect_same("b", c("a", NA, "b")) + expect_same(letters, c("m", NA, "")) + } > > # adapted from R's unit tests > t1 = c("Foobar", "bla bla", "something", "another", "blu", "brown", "blau blüht der Enzian") > t2 = c("some text", "any text") > t3 = c("Martin", "Zürich", "Mächler") > > expect_true(all(backports:::startsWith(t1, ""))) > expect_true(all(backports:::endsWith(t1, ""))) > expect_true(all(backports:::endsWith(t2, ""))) > expect_true(all(backports:::startsWith(t2, ""))) > expect_true(all(backports:::endsWith(t3, ""))) > expect_true(all(backports:::startsWith(t3, ""))) > expect_true(all(backports:::endsWith(t2, "text"))) > expect_true(all(backports:::endsWith(t2, " text"))) > expect_identical(backports:::startsWith(t1, "b" ), c(FALSE, TRUE, FALSE, FALSE, TRUE, TRUE, TRUE)) > expect_identical(backports:::startsWith(t1, "bl"), c(FALSE, TRUE, FALSE, FALSE, TRUE, FALSE, TRUE)) > expect_identical(backports:::startsWith(t1, "bla"),c(FALSE, TRUE, FALSE, FALSE,FALSE, FALSE, TRUE)) > expect_identical(backports:::endsWith(t1, "n"), c(FALSE,FALSE, FALSE, FALSE,FALSE, TRUE, TRUE)) > expect_identical(backports:::endsWith(t1, "an"), c(FALSE,FALSE, FALSE, FALSE,FALSE, FALSE, TRUE)) > expect_identical(backports:::startsWith(t3, "M" ), c( TRUE, FALSE, TRUE)) > expect_identical(backports:::startsWith(t3, "Ma"), c( TRUE, FALSE, FALSE)) > expect_identical(backports:::startsWith(t3, "Mä"), c(FALSE, FALSE, TRUE)) > > proc.time() user system elapsed 0.21 0.04 0.26 Running the tests in 'tests/test_stopifnot.R' failed. Complete output: > source("helper/helper.R") > > expect_silent = function(x) { + ok = try(eval.parent(substitute(x)), silent = TRUE) + if (inherits(ok, "try-error")) + stop(deparse(substitute(x)), " threw an error") + } > > f = backports:::stopifnot > expect_error(f("Test" = 1 == 2), "Test") > expect_silent(f("Test" = 1 == 1)) > expect_error(f("Test 1" = 1 == 2, "Test 2" = 2 == 2), "Test 1") > expect_error(f("Test 1" = 1 == 2, "Test 2" = 2 == 3), "Test 1") > expect_error(f("Test 1" = 1 == 1, "Test 2" = 2 == 3), "Test 2") > expect_silent(f("Test 1" = 1 == 1, "Test 2" = 2 == 2)) > > proc.time() user system elapsed 0.18 0.07 0.25 Running the tests in 'tests/test_str2expression.R' failed. Complete output: > source("helper/helper.R") > > if (exists("str2expression", envir = baseenv())) { + f = get("str2expression", envir = baseenv()) + expect_same = makeCompareFun(f, backports:::str2expression) + + expect_same("x[3] <- 1+4") + expect_same("log(y)") + expect_same("abc") + expect_same("1.375") + } > > proc.time() user system elapsed 0.15 0.07 0.20 Running the tests in 'tests/test_str2lang.R' failed. Complete output: > source("helper/helper.R") > > if (exists("str2lang", envir = baseenv())) { + f = get("str2lang", envir = baseenv()) + expect_same = makeCompareFun(f, backports:::str2lang) + + expect_same("x[3] <- 1+4") + expect_same("log(y)") + expect_same("abc") + expect_same("1.375") + } > > proc.time() user system elapsed 0.17 0.09 0.25 Running the tests in 'tests/test_valid.factor.R' failed. Complete output: > source("helper/helper.R") > > f = backports:::.valid.factor > x = factor(letters[1:3]) > expect_identical(f(x), TRUE) > > x = 1:2 > attr(x, "levels") = c("a", "a") > expect_true(is.character(.valid.factor(x))) > > if (exists(".valid.factor", envir = baseenv())) { + f = get(".valid.factor", envir = baseenv()) + expect_same = makeCompareFun(f, backports:::.valid.factor) + + expect_same(letters[1:2]) + expect_same(NULL) + expect_same(iris) + expect_same(factor("a")) + expect_same(factor(1:3, levels = 1:3)) + + x = 1:2 + class(x) = "factor" + attr(x, "levels") = c("a", "b") + expect_same(x) + + attr(x, "levels") = c("a", "a") + expect_same(x) + + attr(x, "levels") = 1:2 + expect_same(x) + } > > proc.time() user system elapsed 0.17 0.04 0.20 Flavor: r-devel-windows-x86_64