Running ‘testthat.R’ [12s/15s]
Running the tests in ‘tests/testthat.R’ failed.
Complete output:
  > library(testthat)
  > test_check("penaltyLearning")
  Loading required package: penaltyLearning
  Loading required package: data.table
  ── 1. Error: (unknown) (@test-demo8.R#8)  ──────────────────────────────────────
  The implementation of future_lapply() in the 'future' package is defunct. Please use the one in the 'future.apply' package instead.
  1: with(demo8, IntervalRegressionCV(feature.mat, target.mat, min.observations = 8)) at testthat/test-demo8.R:8
  2: with.default(demo8, IntervalRegressionCV(feature.mat, target.mat, min.observations = 8))
  3: eval(substitute(expr), data, enclos = parent.frame())
  4: eval(substitute(expr), data, enclos = parent.frame())
  5: IntervalRegressionCV(feature.mat, target.mat, min.observations = 8)
  6: LAPPLY(validation.fold.vec, function(validation.fold) {
         is.validation <- fold.vec == validation.fold
         is.train <- !is.validation
         train.features <- feature.mat[is.train, all.finite, drop = FALSE]
         train.targets <- target.mat[is.train, , drop = FALSE]
         dt.list <- LAPPLY(margin.vec, function(margin) {
             if (1 <= verbose) {
                 cat(sprintf("margin=%f vfold=%d\n", margin, validation.fold))
             }
             fit <- IntervalRegressionRegularized(train.features, train.targets, verbose = verbose, 
                 margin = margin, initial.regularization = initial.regularization, ...)
             validation.features <- feature.mat[is.validation, , drop = FALSE]
             pred.log.lambda <- fit$predict(validation.features)
             validation.targets <- target.mat[is.validation, , drop = FALSE]
             too.small <- pred.log.lambda < validation.targets[, 1]
             too.big <- validation.targets[, 2] < pred.log.lambda
             is.error <- too.small | too.big
             getLoss <- function(m) colMeans({
                 squared.hinge(pred.log.lambda - validation.targets[, 1], m) + squared.hinge(validation.targets[, 
                     2] - pred.log.lambda, m)
             })
             dt <- data.table(margin, validation.fold, regularization = fit$regularization.vec, 
                 squared.hinge.loss = getLoss(margin), mean.squared.error = getLoss(0), 
                 incorrect.intervals = colSums(is.error))
             if (!is.null(incorrect.labels.db)) {
                 dt$negative.auc <- NA_real_
                 dt$incorrect.labels <- NA_real_
                 for (regularization.i in seq_along(fit$regularization.vec)) {
                     pred.dt <- data.table(pred.log.lambda = pred.log.lambda[, regularization.i])
                     pred.dt[[key(incorrect.labels.db)]] <- rownames(feature.mat)[is.validation]
                     roc <- ROChange(incorrect.labels.db, pred.dt, key(incorrect.labels.db))
                     dt[regularization.i, `:=`(negative.auc, -roc$auc)]
                     predicted.thresh <- roc$thresholds[threshold == "predicted", ]
                     dt[regularization.i, `:=`(incorrect.labels, predicted.thresh$errors)]
                 }
             }
             dt
         })
         do.call(rbind, dt.list)
     })
  7: .Defunct(msg = "The implementation of future_lapply() in the 'future' package is defunct. Please use the one in the 'future.apply' package instead.")
  8: stop(paste(msg, collapse = ""), call. = FALSE, domain = NA)
  
  ── 2. Failure: error for constant features (@test-errors.R#110)  ───────────────
  `{ ... }` threw an error with unexpected message.
  Expected match: "after filtering NA and constant features, none remain for training"
  Actual message: "The implementation of future_lapply() in the 'future' package is defunct. Please use the one in the 'future.apply' package instead."
  
  ── 3. Failure: error for NA and constant features (@test-errors.R#124)  ────────
  `{ ... }` threw an error with unexpected message.
  Expected match: "after filtering NA and constant features, none remain for training"
  Actual message: "The implementation of future_lapply() in the 'future' package is defunct. Please use the one in the 'future.apply' package instead."
  
  ══ testthat results  ═══════════════════════════════════════════════════════════
  OK: 50 SKIPPED: 0 FAILED: 3
  1. Error: (unknown) (@test-demo8.R#8) 
  2. Failure: error for constant features (@test-errors.R#110) 
  3. Failure: error for NA and constant features (@test-errors.R#124) 
  
  Error: testthat unit tests failed
  Execution halted