Running ‘testthat.R’ [6s/8s]
Running the tests in ‘tests/testthat.R’ failed.
Complete output:
  > library(testthat)
  > library(multilevelTools)
  > library(JWileymisc)
  > 
  > test_check("multilevelTools")
  Saving _problems/test-descriptives-2.R
  Saving _problems/test-descriptives-19.R
  [ FAIL 2 | WARN 0 | SKIP 19 | PASS 45 ]
  
  ══ Skipped tests (19) ══════════════════════════════════════════════════════════
  • On CRAN (19): 'test-diagnostics.R:2:3', 'test-diagnostics.R:14:3',
    'test-diagnostics.R:31:3', 'test-diagnostics.R:50:3',
    'test-diagnostics.R:73:3', 'test-diagnostics.R:85:3',
    'test-diagnostics.R:100:3', 'test-diagnostics.R:115:3',
    'test-diagnostics.R:130:3', 'test-models.R:2:3', 'test-models.R:36:3',
    'test-models.R:48:3', 'test-models.R:72:3', 'test-models.R:98:3',
    'test-models.R:133:3', 'test-models.R:186:3', 'test-plotting.R:2:3',
    'test-plotting.R:22:3', 'test-styler.R:2:3'
  
  ══ Failed tests ════════════════════════════════════════════════════════════════
  ── Error ('test-descriptives.R:2:3'): meanDecompose works with one grouping factor ──
  Error in ``[.data.table`(data, , `:=`((vname), mean(get(vres), na.rm = TRUE)), by = c(v[2:i]))`: attempt access index 3/3 in VECTOR_ELT
  Backtrace:
      ▆
   1. └─multilevelTools::meanDecompose(mpg ~ cyl, data = mtcars) at test-descriptives.R:2:3
   2.   ├─data[, `:=`((vname), mean(get(vres), na.rm = TRUE)), by = c(v[2:i])]
   3.   └─data.table:::`[.data.table`(...)
  ── Error ('test-descriptives.R:19:3'): meanDecompose works with two grouping factors ──
  Error in ``[.data.table`(data, , `:=`((vname), mean(get(vres), na.rm = TRUE)), by = c(v[2:i]))`: attempt access index 4/4 in VECTOR_ELT
  Backtrace:
      ▆
   1. └─multilevelTools::meanDecompose(mpg ~ vs + cyl, data = mtcars) at test-descriptives.R:19:3
   2.   ├─data[, `:=`((vname), mean(get(vres), na.rm = TRUE)), by = c(v[2:i])]
   3.   └─data.table:::`[.data.table`(...)
  
  [ FAIL 2 | WARN 0 | SKIP 19 | PASS 45 ]
  Error:
  ! Test failures.
  Execution halted