Running ‘testthat.R’
Running the tests in ‘tests/testthat.R’ failed.
Complete output:
  > suppressPackageStartupMessages(library("tna"))
  > library("testthat")
  
  Attaching package: 'testthat'
  
  The following object is masked from 'package:tna':
  
      compare
  
  > 
  > test_check("tna")
  Error in `source_dir()`:
  ! Failed to evaluate './helper-mock.R'.
  Caused by error in `[.data.table`:
  ! attempt access index 6/6 in VECTOR_ELT
  Backtrace:
       ▆
    1. ├─testthat::test_check("tna")
    2. │ └─testthat::test_dir(...)
    3. │   └─testthat:::test_files(...)
    4. │     └─testthat:::test_files_serial(...)
    5. │       └─testthat:::test_files_setup_state(...)
    6. │         └─testthat::source_test_helpers(".", env)
    7. │           └─testthat::source_dir(path, "^helper.*\\.[rR]$", env = env, wrap = FALSE)
    8. │             └─base::lapply(...)
    9. │               └─testthat (local) FUN(X[[i]], ...)
   10. │                 └─testthat::source_file(...)
   11. │                   ├─base::withCallingHandlers(...)
   12. │                   └─base::eval(exprs, env)
   13. │                     └─base::eval(exprs, env)
   14. │                       └─tna::group_tna(engagement_mmm) at ./helper-mock.R:47:1
   15. │                         ├─tna::group_model(x = x, type = "relative", ...)
   16. │                         └─tna:::group_model.mhmm(x = x, type = "relative", ...)
   17. │                           ├─tna:::group_model.default(...)
   18. │                           │ └─group %m% seq_len(nrow(x))
   19. │                           ├─base::summary(x)
   20. │                           └─seqHMM:::summary.mhmm(x)
   21. │                             └─seqHMM::posterior_cluster_probabilities(object)
   22. │                               ├─seqHMM::posterior_probs(x)
   23. │                               └─seqHMM:::posterior_probs.mhmm(x)
   24. │                                 ├─...[]
   25. │                                 └─data.table:::`[.data.table`(...)
   26. └─base::.handleSimpleError(...)
   27.   └─testthat (local) h(simpleError(msg, call))
   28.     └─cli::cli_abort(...)
   29.       └─rlang::abort(...)
  Execution halted