Running 'testthat.R' [137s]
Running the tests in 'tests/testthat.R' failed.
Complete output:
  > if (requireNamespace("testthat", quietly = TRUE)) {
  +   library(testthat)
  +   library(mlr3mbo)
  +   test_check("mlr3mbo")
  + }
  Loading required package: mlr3tuning
  Loading required package: mlr3
  Loading required package: paradox
  Loading required namespace: mlr3learners
  Loading required namespace: DiceKriging
  Loading required namespace: rgenoud
  WARN  [18:08:42.483] [bbotk] Optimizer Error.
  WARN  [18:08:50.354] [bbotk] Assertion on 'y' failed: May not be NA.
  WARN  [18:08:50.845] [bbotk] Cannot predict, Learner 'regr.featureless' has not been trained yet
  WARN  [18:09:18.708] [bbotk] Surrogate Train Error.
  WARN  [18:09:21.441] [bbotk] attempt to apply non-function
  WARN  [18:09:26.686] [bbotk] Surrogate Train Error.
  WARN  [18:09:30.578] [bbotk] Cannot predict, Learner 'regr.km' has not been trained yet
  WARN  [18:09:50.968] [bbotk] Current insample performance of the Surrogate Model does not meet the performance threshold.
  WARN  [18:09:53.301] [bbotk] Optimizer Error.
  WARN  [18:09:53.442] [bbotk] Surrogate Train Error.
  WARN  [18:09:53.615] [bbotk] Surrogate Predict Error.
  WARN  [18:09:59.988] [bbotk] Cannot predict, Learner 'regr.featureless' has not been trained yet
  WARN  [18:10:00.187] [bbotk] Cannot predict, Learner 'regr.featureless' has not been trained yet
  WARN  [18:10:00.372] [bbotk] Cannot predict, Learner 'regr.featureless' has not been trained yet
  WARN  [18:10:02.075] [bbotk] Cannot predict, Learner 'regr.km' has not been trained yet
  WARN  [18:10:02.243] [bbotk] Cannot predict, Learner 'regr.km' has not been trained yet
  WARN  [18:10:03.750] [bbotk] Assertion on 'y' failed: May not be NA.
  WARN  [18:10:20.693] [bbotk] Cannot predict, Learner 'regr.error' has not been trained yet
  [ FAIL 12 | WARN 2 | SKIP 2 | PASS 669 ]
  
  ══ Skipped tests ═══════════════════════════════════════════════════════════════
  • On CRAN (2)
  
  ══ Failed tests ════════════════════════════════════════════════════════════════
  ── Error ('test_AcqFunctionEIPS.R:27'): AcqFunctionEIPS works ──────────────────
  Error: Cannot predict, Learner 'regr.featureless' has not been trained yet
  Backtrace:
       ▆
    1. └─acqf$eval_dt(xdt) at test_AcqFunctionEIPS.R:27:2
    2.   └─mlr3mbo:::.__AcqFunction__eval_dt(...)
    3.     ├─mlr3misc::invoke(private$.fun, xdt, .args = self$constants$values)
    4.     │ └─base::eval.parent(expr, n = 1L)
    5.     │   └─base::eval(expr, p)
    6.     │     └─base::eval(expr, p)
    7.     └─private$.fun(xdt)
    8.       └─mlr3mbo:::.__AcqFunctionEIPS__.fun(...)
    9.         └─self$surrogate$predict(xdt)
   10.           └─mlr3mbo:::.__SurrogateLearnerCollection__predict(...)
   11.             └─base::lapply(...)
   12.               └─mlr3mbo (local) FUN(X[[i]], ...)
   13.                 └─model$predict_newdata(newdata = xdt)
   14.                   └─mlr3:::.__Learner__predict_newdata(...)
   15.                     └─self$predict(task)
   16.                       └─mlr3:::.__Learner__predict(...)
   17.                         └─mlr3misc::stopf(...)
  ── Error ('test_AcqFunctionMean.R:20'): AcqFunctionMean works ──────────────────
  Error in ``[.data.table`(res, , self$codomain$ids(), with = FALSE)`: column(s) not found: acq_mean
  Backtrace:
       ▆
    1. └─acqf$eval_dt(xdt) at test_AcqFunctionMean.R:20:2
    2.   └─mlr3mbo:::.__AcqFunction__eval_dt(...)
    3.     ├─self$codomain$assert_dt(res[, self$codomain$ids(), with = FALSE])
    4.     │ └─paradox:::.__ParamSet__assert_dt(...)
    5.     │   ├─checkmate::makeAssertion(...)
    6.     │   │ └─base::isTRUE(res)
    7.     │   └─self$check_dt(xdt)
    8.     │     └─paradox:::.__ParamSet__check_dt(...)
    9.     │       ├─mlr3misc::map(transpose_list(xdt), discard, is.na)
   10.     │       │ └─base::lapply(.x, .f, ...)
   11.     │       └─mlr3misc::transpose_list(xdt)
   12.     │         ├─checkmate::assert(check_list(.l), check_data_frame(.l))
   13.     │         │ └─base::eval(dots[[i]], envir = env)
   14.     │         │   └─base::eval(dots[[i]], envir = env)
   15.     │         └─checkmate::check_list(.l)
   16.     │           └─... %and% checkListTypes(x, types)
   17.     │             └─base::isTRUE(lhs)
   18.     ├─res[, self$codomain$ids(), with = FALSE]
   19.     └─data.table:::`[.data.table`(res, , self$codomain$ids(), with = FALSE)
  ── Failure ('test_AcqFunctionPI.R:24'): AcqFunctionPI works ────────────────────
  Check on 'res' failed: Must have exactly 5 rows, but has 0 rows
  Backtrace:
      ▆
   1. └─checkmate::expect_data_table(res, ncols = 1L, nrows = 5L, any.missing = FALSE) at test_AcqFunctionPI.R:24:2
   2.   └─checkmate::makeExpectation(x, res, info, label)
  ── Error ('test_AcqOptimizer.R:58'): AcqOptimizer API works ────────────────────
  <acq_optimizer_error/mbo_error/error/condition>
  Error: Assertion on 'y' failed: May not be NA.
  Backtrace:
      ▆
   1. └─acqopt$optimize() at test_AcqOptimizer.R:58:2
   2.   └─mlr3mbo:::.__AcqOptimizer__optimize(...)
   3.     └─base::tryCatch(...)
   4.       └─base (local) tryCatchList(expr, classes, parentenv, handlers)
   5.         └─base (local) tryCatchOne(expr, names, parentenv, handlers[[1L]])
   6.           └─value[[3L]](cond)
  ── Error ('test_AcqOptimizer.R:104'): AcqOptimizer trafo ───────────────────────
  <acq_optimizer_error/mbo_error/error/condition>
  Error: Cannot predict, Learner 'regr.featureless' has not been trained yet
  Backtrace:
      ▆
   1. └─acqopt$optimize() at test_AcqOptimizer.R:104:2
   2.   └─mlr3mbo:::.__AcqOptimizer__optimize(...)
   3.     └─base::tryCatch(...)
   4.       └─base (local) tryCatchList(expr, classes, parentenv, handlers)
   5.         └─base (local) tryCatchOne(expr, names, parentenv, handlers[[1L]])
   6.           └─value[[3L]](cond)
  ── Error ('test_SurrogateLearner.R:40'): predict_types are recognized ──────────
  Error: Cannot predict, Learner 'regr.featureless' has not been trained yet
  Backtrace:
       ▆
    1. ├─testthat::expect_named(surrogate$predict(xdt), c("mean", "se")) at test_SurrogateLearner.R:40:2
    2. │ └─testthat::quasi_label(enquo(object), label, arg = "object")
    3. │   └─rlang::eval_bare(expr, quo_get_env(quo))
    4. └─surrogate$predict(xdt)
    5.   └─mlr3mbo:::.__SurrogateLearner__predict(...)
    6.     └─self$model$predict_newdata(newdata = xdt)
    7.       └─mlr3:::.__Learner__predict_newdata(...)
    8.         └─self$predict(task)
    9.           └─mlr3:::.__Learner__predict(...)
   10.             └─mlr3misc::stopf(...)
  ── Error ('test_SurrogateLearner.R:79'): insample_perf ─────────────────────────
  <surrogate_update_error/mbo_error/error/condition>
  Error: attempt to apply non-function
  Backtrace:
      ▆
   1. └─surrogate$update() at test_SurrogateLearner.R:79:2
   2.   └─mlr3mbo:::.__Surrogate__update(...)
   3.     └─base::tryCatch(...)
   4.       └─base (local) tryCatchList(expr, classes, parentenv, handlers)
   5.         └─base (local) tryCatchOne(expr, names, parentenv, handlers[[1L]])
   6.           └─value[[3L]](cond)
  ── Error ('test_SurrogateLearnerCollection.R:89'): insample_perf ───────────────
  <surrogate_update_error/mbo_error/error/condition>
  Error: Cannot predict, Learner 'regr.km' has not been trained yet
  Backtrace:
      ▆
   1. └─surrogate$update() at test_SurrogateLearnerCollection.R:89:2
   2.   └─mlr3mbo:::.__Surrogate__update(...)
   3.     └─base::tryCatch(...)
   4.       └─base (local) tryCatchList(expr, classes, parentenv, handlers)
   5.         └─base (local) tryCatchOne(expr, names, parentenv, handlers[[1L]])
   6.           └─value[[3L]](cond)
  ── Error ('test_TunerMbo.R:34'): Constructing TunerMbo and ABs ─────────────────
  Error in `load_dataset("iris", "datasets")`: lazy-load database 'D:\RCompile\recent\R\library\datasets/data/Rdata.rdb' is corrupt
  Backtrace:
       ▆
    1. ├─TuningInstanceSingleCrit$new(...) at test_TunerMbo.R:34:2
    2. │ └─mlr3tuning (local) initialize(...)
    3. │   └─mlr3tuning:::.__TuningInstanceSingleCrit__initialize(...)
    4. │     └─mlr3::assert_measures(...)
    5. │       └─base::lapply(...)
    6. │         └─mlr3 (local) FUN(X[[i]], ...)
    7. └─mlr3::tsk("iris")
    8.   └─mlr3misc::dictionary_sugar_get(mlr_tasks, .key, ...)
    9.     └─mlr3misc:::dictionary_get(dict, .key)
   10.       └─mlr3misc:::dictionary_initialize_item(key, obj, dots)
   11.         ├─base::do.call(constructor, cargs)
   12.         └─mlr3 (local) `<fn>`()
   13.           ├─mlr3::as_data_backend(load_dataset("iris", "datasets"))
   14.           └─mlr3misc::load_dataset("iris", "datasets")
  ── Error ('test_TunerMbo.R:92'): TunerMbo param_classes ────────────────────────
  Error in `load_dataset("iris", "datasets")`: lazy-load database 'D:\RCompile\recent\R\library\datasets/data/Rdata.rdb' is corrupt
  Backtrace:
       ▆
    1. ├─TuningInstanceSingleCrit$new(...) at test_TunerMbo.R:92:2
    2. │ └─mlr3tuning (local) initialize(...)
    3. │   └─mlr3tuning:::.__TuningInstanceSingleCrit__initialize(...)
    4. │     └─mlr3::assert_measures(...)
    5. │       └─base::lapply(...)
    6. │         └─mlr3 (local) FUN(X[[i]], ...)
    7. └─mlr3::tsk("iris")
    8.   └─mlr3misc::dictionary_sugar_get(mlr_tasks, .key, ...)
    9.     └─mlr3misc:::dictionary_get(dict, .key)
   10.       └─mlr3misc:::dictionary_initialize_item(key, obj, dots)
   11.         ├─base::do.call(constructor, cargs)
   12.         └─mlr3 (local) `<fn>`()
   13.           ├─mlr3::as_data_backend(load_dataset("iris", "datasets"))
   14.           └─mlr3misc::load_dataset("iris", "datasets")
  ── Failure ('test_bayesopt_ego.R:156'): bayesopt_ego random interleave ─────────
  is.na(instance$archive$data$acq_ei) (`actual`) not identical to c(rep(TRUE, 4L), FALSE, TRUE, FALSE, TRUE, FALSE, TRUE) (`expected`).
  
  `actual`:                                                       
  `expected`: TRUE TRUE TRUE TRUE FALSE TRUE FALSE TRUE FALSE TRUE
  ── Failure ('test_bayesopt_parego.R:17'): default bayesopt_parego ──────────────
  !is.na(instance$archive$data$acq_ei[5L]) is not TRUE
  
  `actual`:       
  `expected`: TRUE
  
  [ FAIL 12 | WARN 2 | SKIP 2 | PASS 669 ]
  Error: Test failures
  Execution halted