Running ‘testthat.R’ [17s/26s]
Running the tests in ‘tests/testthat.R’ failed.
Complete output:
  > library(testthat)
  > library(posterior)
  This is posterior version 1.2.2
  
  Attaching package: 'posterior'
  
  The following objects are masked from 'package:stats':
  
      mad, sd, var
  
  > 
  > test_check("posterior")
  [ FAIL 4 | WARN 0 | SKIP 4 | PASS 1000 ]
  
  ══ Skipped tests ═══════════════════════════════════════════════════════════════
  • On CRAN (4)
  
  ══ Failed tests ════════════════════════════════════════════════════════════════
  ── Error (test-rstar.R:33:3): rstar with uncertainty returns vectors of correct length ──
  Error: Required packages are missing: gbm
  Backtrace:
      ▆
   1. └─posterior::rstar(x, method = "gbm", uncertainty = T, verbose = F) at test-rstar.R:33:2
   2.   ├─caret::train(...)
   3.   └─caret:::train.formula(...)
   4.     ├─caret::train(x, y, weights = w, ...)
   5.     └─caret:::train.default(x, y, weights = w, ...)
   6.       └─caret::checkInstall(models$library)
  ── Error (test-rstar.R:49:3): rstar with uncertainty returns reasonable values ──
  Error: Required packages are missing: gbm
  Backtrace:
      ▆
   1. └─posterior::rstar(x, method = "gbm", uncertainty = T, verbose = F) at test-rstar.R:49:2
   2.   ├─caret::train(...)
   3.   └─caret:::train.formula(...)
   4.     ├─caret::train(x, y, weights = w, ...)
   5.     └─caret:::train.default(x, y, weights = w, ...)
   6.       └─caret::checkInstall(models$library)
  ── Error (test-rstar.R:56:3): rstar accepts different classifiers ──────────────
  Error: Required packages are missing: gbm
  Backtrace:
      ▆
   1. └─posterior::rstar(x, method = "gbm", verbose = F) at test-rstar.R:56:2
   2.   ├─caret::train(...)
   3.   └─caret:::train.formula(...)
   4.     ├─caret::train(x, y, weights = w, ...)
   5.     └─caret:::train.default(x, y, weights = w, ...)
   6.       └─caret::checkInstall(models$library)
  ── Error (test-rstar.R:72:3): rstar accepts different hyperparameters ──────────
  Error: Required packages are missing: gbm
  Backtrace:
      ▆
   1. └─posterior::rstar(x, method = "gbm", verbose = F, hyperparameters = caret_grid) at test-rstar.R:72:2
   2.   ├─caret::train(...)
   3.   └─caret:::train.formula(...)
   4.     ├─caret::train(x, y, weights = w, ...)
   5.     └─caret:::train.default(x, y, weights = w, ...)
   6.       └─caret::checkInstall(models$library)
  
  [ FAIL 4 | WARN 0 | SKIP 4 | PASS 1000 ]
  Error: Test failures
  Execution halted