Running ‘testthat.R’ [4s/15s]
Running the tests in ‘tests/testthat.R’ failed.
Complete output:
  > Sys.setenv("R_TESTS" = "")
  > if (require(testthat, quietly = TRUE)) {
  +   require(treatSens)
  +   test_check("treatSens")
  + } else {
  +   cat("package 'testthat' not available; cannot run unit tests\n")
  + }
  Loading required package: treatSens
  Loading required package: Rcpp
  
   *** caught segfault ***
  address 40222816, cause 'memory not mapped'
  
  Traceback:
   1: treatSens:::cibart(data$y, data$z, data$x, data$x.test, data$zeta.y,     data$zeta.z, data$theta, "ATE", probit(family = "normal"),     control)
   2: doTryCatch(return(expr), name, parentenv, handler)
   3: tryCatchOne(expr, names, parentenv, handlers[[1L]])
   4: tryCatchList(expr, classes, parentenv, handlers)
   5: tryCatch(treatSens:::cibart(data$y, data$z, data$x, data$x.test,     data$zeta.y, data$zeta.z, data$theta, "ATE", probit(family = "normal"),     control), error = function(e) e)
   6: eval(code, test_env)
   7: eval(code, test_env)
   8: 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)
   9: doTryCatch(return(expr), name, parentenv, handler)
  10: tryCatchOne(expr, names, parentenv, handlers[[1L]])
  11: tryCatchList(expr, names[-nh], parentenv, handlers[-nh])
  12: doTryCatch(return(expr), name, parentenv, handler)
  13: tryCatchOne(tryCatchList(expr, names[-nh], parentenv, handlers[-nh]),     names[nh], parentenv, handlers[[nh]])
  14: tryCatchList(expr, classes, parentenv, handlers)
  15: 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) {    })
  16: test_code(desc, code, env = parent.frame())
  17: test_that("cibart works with various treatmentModel specification methods",     {        data <- generateData()        control <- treatSens:::cibartControl(5L, 20L, n.thin = 3L,             n.thread = 1L)        result <- tryCatch(treatSens:::cibart(data$y, data$z,             data$x, data$x.test, data$zeta.y, data$zeta.z, data$theta,             "ATE", probit(family = "normal"), control), error = function(e) e)        expect_is(result, "list")        result <- tryCatch(treatSens:::cibart(data$y, data$z,             data$x, data$x.test, data$zeta.y, data$zeta.z, data$theta,             "ATE", probit, control), error = function(e) e)        expect_is(result, "list")        result <- tryCatch(treatSens:::cibart(data$y, data$z,             data$x, data$x.test, data$zeta.y, data$zeta.z, data$theta,             "ATE", "probit(family = 'normal')", control), error = function(e) e)        expect_is(result, "list")        result <- tryCatch(treatSens:::cibart(data$y, data$z,             data$x, data$x.test, data$zeta.y, data$zeta.z, data$theta,             "ATE", "probit", control), error = function(e) e)        expect_is(result, "list")        trtModel <- treatSens:::probit(family = "normal")        result <- tryCatch(treatSens:::cibart(data$y, data$z,             data$x, data$x.test, data$zeta.y, data$zeta.z, data$theta,             "ATE", trtModel, control), error = function(e) e)        expect_is(result, "list")        expect_error(treatSens:::cibart(data$y, data$z, data$x,             data$x.test, data$zeta.y, data$zeta.z, data$theta,             "ATE", notAnObject, control))    })
  18: eval(code, test_env)
  19: eval(code, test_env)
  20: 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)
  21: doTryCatch(return(expr), name, parentenv, handler)
  22: tryCatchOne(expr, names, parentenv, handlers[[1L]])
  23: tryCatchList(expr, names[-nh], parentenv, handlers[-nh])
  24: doTryCatch(return(expr), name, parentenv, handler)
  25: tryCatchOne(tryCatchList(expr, names[-nh], parentenv, handlers[-nh]),     names[nh], parentenv, handlers[[nh]])
  26: tryCatchList(expr, classes, parentenv, handlers)
  27: 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) {    })
  28: test_code(NULL, exprs, env)
  29: source_file(path, new.env(parent = env), chdir = TRUE, wrap = wrap)
  30: force(code)
  31: 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()    })
  32: FUN(X[[i]], ...)
  33: lapply(paths, test_file, env = env, reporter = current_reporter,     start_end_reporter = FALSE, load_helpers = FALSE, wrap = wrap)
  34: force(code)
  35: with_reporter(reporter = current_reporter, results <- lapply(paths,     test_file, env = env, reporter = current_reporter, start_end_reporter = FALSE,     load_helpers = FALSE, wrap = wrap))
  36: test_files(paths, reporter = reporter, env = env, stop_on_failure = stop_on_failure,     stop_on_warning = stop_on_warning, wrap = wrap)
  37: 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)
  38: 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)
  39: test_check("treatSens")
  An irrecoverable exception occurred. R is aborting now ...