Running ‘run-all.R’ [3s/17s]
Running the tests in ‘tests/run-all.R’ failed.
Complete output:
  > library(testthat)
  > test_check("BBmisc")
  Loading required package: BBmisc
  
  Attaching package: 'BBmisc'
  
  The following object is masked from 'package:base':
  
      isFALSE
  
  ── 1. Error: asMatrix (@test_asMatrix.R#16)  ───────────────────────────────────
  STRING_ELT() can only be applied to a 'character vector', not a 'language'
  1: expect_equal(asMatrixCols(list(c(1, 2), c(3, 3), c(4, 4))), matrix(c(1, 2, 3, 3, 
         4, 4), nrow = 2, ncol = 3, byrow = FALSE)) at testthat/test_asMatrix.R:16
  2: quasi_label(enquo(object), label)
  3: eval_bare(get_expr(quo), get_env(quo))
  4: asMatrixCols(list(c(1, 2), c(3, 3), c(4, 4)))
  5: assertList(xs, types = "vector")
  6: checkList(x, types, any.missing, all.missing, len, min.len, max.len, unique, names, 
         null.ok)
  7: .Call(c_check_list, x, any.missing, all.missing, len, min.len, max.len, unique, names, 
         null.ok) %and% checkListTypes(x, types)
  8: checkListTypes(x, types)
  9: qassert(types, "S")
  
  
   *** caught illegal operation ***
  address 8c479ba, cause 'illegal opcode'
  
  Traceback:
   1: qassert(null.ok, "B1")
   2: checkChoice(x, choices, null.ok, fmatch)
   3: assertChoice(ties.method, c("first", "random", "last"))
   4: computeMode(as.factor(c(1:2, 2L, 2L)))
   5: eval_bare(get_expr(quo), get_env(quo))
   6: quasi_label(enquo(object), label)
   7: expect_equal(computeMode(as.factor(c(1:2, 2L, 2L))), "2")
   8: eval(code, test_env)
   9: eval(code, test_env)
  10: withCallingHandlers({    eval(code, test_env)    if (!handled && !is.null(test)) {        skip_empty()    }}, expectation = handle_expectation, skip = handle_skip, warning = handle_warning,     message = handle_message, error = handle_error)
  11: doTryCatch(return(expr), name, parentenv, handler)
  12: tryCatchOne(expr, names, parentenv, handlers[[1L]])
  13: tryCatchList(expr, names[-nh], parentenv, handlers[-nh])
  14: doTryCatch(return(expr), name, parentenv, handler)
  15: tryCatchOne(tryCatchList(expr, names[-nh], parentenv, handlers[-nh]),     names[nh], parentenv, handlers[[nh]])
  16: tryCatchList(expr, classes, parentenv, handlers)
  17: tryCatch(withCallingHandlers({    eval(code, test_env)    if (!handled && !is.null(test)) {        skip_empty()    }}, expectation = handle_expectation, skip = handle_skip, warning = handle_warning,     message = handle_message, error = handle_error), error = handle_fatal,     skip = function(e) {    })
  18: test_code(desc, code, env = parent.frame())
  19: test_that("computeMode", {    expect_equal(computeMode(as.factor(c(1:2, 2L, 2L))), "2")    expect_equal(computeMode(c("1", "2", "3"), ties.method = "last"),         "3")    expect_equal(computeMode(c(1, 1, 2, 3)), 1)    expect_equal(computeMode(c(1:2, 2L, 2L), ties.method = "first"),         2L)    expect_equal(computeMode(c(1:2, 2L, 2L), ties.method = "random"),         2L)    expect_equal(computeMode(c(1:2, 2L, 2L), ties.method = "last"),         2L)    expect_equal(computeMode(c(TRUE, FALSE, FALSE)), FALSE)    expect_equal(computeMode(c(TRUE, TRUE, FALSE)), TRUE)    expect_equal(computeMode(c(1, 1, 2, 3, NA, NA, NA), na.rm = FALSE),         as.numeric(NA))    expect_equal(computeMode(c(1, 1, 2, 3, NA, NA, NA), na.rm = TRUE),         1)})
  20: eval(code, test_env)
  21: eval(code, test_env)
  22: withCallingHandlers({    eval(code, test_env)    if (!handled && !is.null(test)) {        skip_empty()    }}, expectation = handle_expectation, skip = handle_skip, warning = handle_warning,     message = handle_message, error = handle_error)
  23: doTryCatch(return(expr), name, parentenv, handler)
  24: tryCatchOne(expr, names, parentenv, handlers[[1L]])
  25: tryCatchList(expr, names[-nh], parentenv, handlers[-nh])
  26: doTryCatch(return(expr), name, parentenv, handler)
  27: tryCatchOne(tryCatchList(expr, names[-nh], parentenv, handlers[-nh]),     names[nh], parentenv, handlers[[nh]])
  28: tryCatchList(expr, classes, parentenv, handlers)
  29: tryCatch(withCallingHandlers({    eval(code, test_env)    if (!handled && !is.null(test)) {        skip_empty()    }}, expectation = handle_expectation, skip = handle_skip, warning = handle_warning,     message = handle_message, error = handle_error), error = handle_fatal,     skip = function(e) {    })
  30: test_code(NULL, exprs, env)
  31: source_file(path, new.env(parent = env), chdir = TRUE, wrap = wrap)
  32: force(code)
  33: with_reporter(reporter = reporter, start_end_reporter = start_end_reporter,     {        lister$start_file(basename(path))        source_file(path, new.env(parent = env), chdir = TRUE,             wrap = wrap)        end_context()    })
  34: FUN(X[[i]], ...)
  35: lapply(paths, test_file, env = env, reporter = current_reporter,     start_end_reporter = FALSE, load_helpers = FALSE, wrap = wrap)
  36: force(code)
  37: with_reporter(reporter = current_reporter, results <- lapply(paths,     test_file, env = env, reporter = current_reporter, start_end_reporter = FALSE,     load_helpers = FALSE, wrap = wrap))
  38: test_files(paths, reporter = reporter, env = env, stop_on_failure = stop_on_failure,     stop_on_warning = stop_on_warning, wrap = wrap)
  39: test_dir(path = test_path, reporter = reporter, env = env, filter = filter,     ..., stop_on_failure = stop_on_failure, stop_on_warning = stop_on_warning,     wrap = wrap)
  40: test_package_dir(package = package, test_path = test_path, filter = filter,     reporter = reporter, ..., stop_on_failure = stop_on_failure,     stop_on_warning = stop_on_warning, wrap = wrap)
  41: test_check("BBmisc")
  An irrecoverable exception occurred. R is aborting now ...