Running 'testthat.R' [203s]
Running the tests in 'tests/testthat.R' failed.
Complete output:
  > library(testthat)
  > library(CAST)
  > 
  > test_check("CAST")
  Loading required package: ggplot2
  Loading required package: lattice
  note: variables were not weighted either because no weights or model were given,
      no variable importance could be retrieved from the given model, or the model has a single feature.
      Check caret::varImp(model)
  note: No model and no CV folds were given. The DI threshold is therefore based on all training data
  note: variables were not weighted either because no weights or model were given,
      no variable importance could be retrieved from the given model, or the model has a single feature.
      Check caret::varImp(model)
  note: No model and no CV folds were given. The DI threshold is therefore based on all training data
  [1] "model using Sepal.Length,Sepal.Width will be trained now..."
  note: only 1 unique complexity parameters in default grid. Truncating the grid to 1 .
  
  [1] "maximum number of models that still need to be trained: 8"
  [1] "model using Sepal.Length,Petal.Length will be trained now..."
  note: only 1 unique complexity parameters in default grid. Truncating the grid to 1 .
  
  [1] "maximum number of models that still need to be trained: 7"
  [1] "model using Sepal.Length,Petal.Width will be trained now..."
  note: only 1 unique complexity parameters in default grid. Truncating the grid to 1 .
  
  [1] "maximum number of models that still need to be trained: 6"
  [1] "model using Sepal.Width,Petal.Length will be trained now..."
  note: only 1 unique complexity parameters in default grid. Truncating the grid to 1 .
  
  [1] "maximum number of models that still need to be trained: 5"
  [1] "model using Sepal.Width,Petal.Width will be trained now..."
  note: only 1 unique complexity parameters in default grid. Truncating the grid to 1 .
  
  [1] "maximum number of models that still need to be trained: 4"
  [1] "model using Petal.Length,Petal.Width will be trained now..."
  note: only 1 unique complexity parameters in default grid. Truncating the grid to 1 .
  
  [1] "maximum number of models that still need to be trained: 3"
  [1] "vars selected: Petal.Length,Petal.Width with Accuracy 0.953"
  [1] "model using additional variable Sepal.Length will be trained now..."
  note: only 2 unique complexity parameters in default grid. Truncating the grid to 2 .
  
  [1] "maximum number of models that still need to be trained: 2"
  [1] "model using additional variable Sepal.Width will be trained now..."
  note: only 2 unique complexity parameters in default grid. Truncating the grid to 2 .
  
  [1] "maximum number of models that still need to be trained: 1"
  [1] "vars selected: Petal.Length,Petal.Width,Sepal.Width with Accuracy 0.954"
  [1] "model using additional variable Sepal.Length will be trained now..."
  [1] "maximum number of models that still need to be trained: 0"
  [1] "vars selected: Petal.Length,Petal.Width,Sepal.Width with Accuracy 0.954"
  Spherical geometry (s2) switched off
  Spherical geometry (s2) switched on
  Spherical geometry (s2) switched off
  Saving _problems/test-geodist-38.R
  Spherical geometry (s2) switched on
  Saving _problems/test-geodist-85.R
  Saving _problems/test-geodist-107.R
  Saving _problems/test-geodist-125.R
  Saving _problems/test-geodist-145.R
  Spherical geometry (s2) switched off
  Spherical geometry (s2) switched on
  Saving _problems/test-geodist-188.R
  variable(s) 'fct' is (are) treated as categorical variables
  Spherical geometry (s2) switched off
  Saving _problems/test-geodist-242.R
  time variable that has been selected: Date
  time variable that has been selected: Date
  time variable that has been selected: Date
  note: only 2 unique complexity parameters in default grid. Truncating the grid to 2 .
  
  note: only 2 unique complexity parameters in default grid. Truncating the grid to 2 .
  
  Spherical geometry (s2) switched on
  although coordinates are longitude/latitude, st_sample assumes that they are
  planar
  although coordinates are longitude/latitude, st_sample assumes that they are
  planar
  1000 prediction points are sampled from the modeldomain
  Gij <= Gj; a random CV assignment is returned
  1000 prediction points are sampled from the modeldomain
  Gij <= Gj; a random CV assignment is returned
  1000 prediction points are sampled from the modeldomain
  predictor values are extracted for prediction points
  Gij <= Gj; a random CV assignment is returned
  1000 prediction points are sampled from the modeldomain
  predictor values are extracted for prediction points
  Gij <= Gj; a random CV assignment is returned
  1000 prediction points are sampled from the modeldomain
  although coordinates are longitude/latitude, st_sample assumes that they are
  planar
  predictor values are extracted for prediction points
  variable(s) 'fct' is (are) treated as categorical variables
  some prediction points contain NAs, which will be removed
  Gij <= Gj; a random CV assignment is returned
  1000 prediction points are sampled from the modeldomain
  predictor values are extracted for prediction points
  variable(s) 'fct' is (are) treated as categorical variables
  1000 prediction points are sampled from the modeldomain
  predictor values are extracted for prediction points
  variable(s) 'fct' is (are) treated as categorical variables
  1000 prediction points are sampled from the modeldomain
  although coordinates are longitude/latitude, st_sample assumes that they are
  planar
  predictor values are extracted for prediction points
  1000 prediction points are sampled from the modeldomain
  predictor values are extracted for prediction points
  1000 prediction points are sampled from the modeldomain
  predictor values are extracted for prediction points
  1000 prediction points are sampled from the modeldomain
  1000 prediction points are sampled from the modeldomain
  1000 prediction points are sampled from the modeldomain
  1000 prediction points are sampled from the modeldomain
  [ FAIL 7 | WARN 11 | SKIP 10 | PASS 100 ]
  
  ══ Skipped tests (10) ══════════════════════════════════════════════════════════
  • On CRAN (10): 'test-errorProfiles.R:3:3', 'test-errorProfiles.R:36:3',
    'test-errorProfiles.R:67:3', 'test-fss.R:3:3', 'test-fss.R:27:3',
    'test-fss.R:47:3', 'test-fss.R:70:3', 'test-fss.R:120:5', 'test-fss.R:135:5',
    'test-fss.R:152:5'
  
  ══ Failed tests ════════════════════════════════════════════════════════════════
  ── Error ('test-geodist.R:34:3'): geodist works with points and polygon in feature space ──
  Error: [project] cannot get output boundaries for the target crs
  Backtrace:
      ▆
   1. └─CAST::geodist(...) at test-geodist.R:34:3
   2.   └─CAST:::sampleFromArea(...)
   3.     ├─terra::project(modeldomain, "epsg:4326")
   4.     └─terra::project(modeldomain, "epsg:4326")
   5.       └─terra (local) .local(x, ...)
   6.         └─terra:::messages(x, "project")
   7.           └─terra:::error(f, x@pntr$getError())
  ── Error ('test-geodist.R:84:3'): geodist works with points and preddata in feature space ──
  Error: [rast] empty srs
  Backtrace:
      ▆
   1. ├─terra::rast(...) at test-geodist.R:84:3
   2. └─terra::rast(...)
   3.   └─terra (local) .local(x = x, ...)
   4.     └─terra:::new_rast(...)
   5.       └─terra:::messages(r, "rast")
   6.         └─terra:::error(f, x@pntr$getError())
  ── Error ('test-geodist.R:106:3'): geodist works with points and raster in geographic space ──
  Error: [rast] empty srs
  Backtrace:
      ▆
   1. ├─terra::rast(...) at test-geodist.R:106:3
   2. └─terra::rast(...)
   3.   └─terra (local) .local(x = x, ...)
   4.     └─terra:::new_rast(...)
   5.       └─terra:::messages(r, "rast")
   6.         └─terra:::error(f, x@pntr$getError())
  ── Error ('test-geodist.R:124:3'): geodist works with points and raster in feature space ──
  Error: [rast] empty srs
  Backtrace:
      ▆
   1. ├─terra::rast(...) at test-geodist.R:124:3
   2. └─terra::rast(...)
   3.   └─terra (local) .local(x = x, ...)
   4.     └─terra:::new_rast(...)
   5.       └─terra:::messages(r, "rast")
   6.         └─terra:::error(f, x@pntr$getError())
  ── Error ('test-geodist.R:143:3'): geodist works with points and stars raster in geographic space ──
  Error: [rast] empty srs
  Backtrace:
      ▆
   1. ├─stars::st_as_stars(...) at test-geodist.R:143:3
   2. ├─terra::rast(...)
   3. └─terra::rast(...)
   4.   └─terra (local) .local(x = x, ...)
   5.     └─terra:::new_rast(...)
   6.       └─terra:::messages(r, "rast")
   7.         └─terra:::error(f, x@pntr$getError())
  ── Error ('test-geodist.R:187:3'): geodist works with points and test data in feature space ──
  Error: [rast] empty srs
  Backtrace:
      ▆
   1. ├─terra::rast(...) at test-geodist.R:187:3
   2. └─terra::rast(...)
   3.   └─terra (local) .local(x = x, ...)
   4.     └─terra:::new_rast(...)
   5.       └─terra:::messages(r, "rast")
   6.         └─terra:::error(f, x@pntr$getError())
  ── Error ('test-geodist.R:238:3'): geodist works with categorical variables in feature space ──
  Error: [project] cannot get output boundaries for the target crs
  Backtrace:
      ▆
   1. └─CAST::geodist(...) at test-geodist.R:238:3
   2.   └─CAST:::sampleFromArea(...)
   3.     ├─terra::project(modeldomain, "epsg:4326", method = "near")
   4.     └─terra::project(modeldomain, "epsg:4326", method = "near")
   5.       └─terra (local) .local(x, ...)
   6.         └─terra:::messages(x, "project")
   7.           └─terra:::error(f, x@pntr$getError())
  
  [ FAIL 7 | WARN 11 | SKIP 10 | PASS 100 ]
  Error:
  ! Test failures.
  Execution halted