Running ‘testthat.R’ [62s/89s]
Running the tests in ‘tests/testthat.R’ failed.
Complete output:
  > library("testthat")
  > library("popEpi")
  > library("data.table")
  > 
  > using_r_devel <- grepl(pattern = "devel", x = R.version$status)
  > if (using_r_devel) {
  +   ## memory leak problem in data.table 1.11.2 in R-devel (3.6.0 atm)
  +   requireNamespace("data.table")
  +   data.table::setDTthreads(threads = 1L)
  + }
  > 
  > test_check("popEpi")
  NOTE: entry.status has been set to "DM" for all.
     first.bad.surv.int last.bad.surv.int surv.obs
  1:                 61               120      NaN
     first.bad.surv.int last.bad.surv.int surv.obs
  1:                 61               120      NaN
     agegr first.bad.surv.int last.bad.surv.int surv.obs
  1:     3                 61               120      NaN
     agegr first.bad.surv.int last.bad.surv.int surv.obs
  1:     3                 61               120      NaN
  ── 1. Failure: Ederer I expected survival curve agrees with survival::survexp (@
  `e1` not equal to `su`.
  Column 'surv.exp': Mean absolute difference: 1.257595e-05
  
  ── 2. Failure: Ederer I expected survival curve agrees with survival::survexp (@
  max(abs(e1$surv.exp - su$surv.exp)) not equal to 0.
  1/1 mismatches
  [1] 2.35e-05 - 0 == 2.35e-05
  
  ── 3. Failure: evalPopFormula & usePopFormula output is stable (@test_utils.R#25
  data.table(r1a) not equal to res[, list(time, status)].
  Column 'status': Mean relative difference: 2
  
  ── 4. Failure: evalPopFormula & usePopFormula output is stable (@test_utils.R#25
  r5$lex.Xst not equal to c(1, 1, 0, 1, 1).
  2/5 mismatches (average diff: 1)
  [2] 0 - 1 == -1
  [3] 1 - 0 ==  1
  
  ── 5. Failure: evalPopFormula & usePopFormula output is stable (@test_utils.R#26
  data.table(r6) not equal to res[, list(lex.Xst, sex)].
  Column 'lex.Xst': Mean relative difference: 2
  
  ── 6. Failure: evalPopFormula & usePopFormula output is stable (@test_utils.R#26
  data.table(r9) not equal to res[, list(lex.Xst, `factor(sex)` = factor(sex))].
  Column 'lex.Xst': Mean relative difference: 2
  
  ── 7. Failure: evalPopFormula & usePopFormula output is stable (@test_utils.R#26
  `r3` not equivalent to res[, .SD, .SDcols = names(r3)].
  Column 'status': Mean relative difference: 2
  
  ── 8. Failure: evalPopFormula & usePopFormula output is stable (@test_utils.R#28
  `r3` not equivalent to list(...).
  Component "y": Column 'status': Mean relative difference: 2
  
  ── 9. Failure: evalPopFormula & usePopFormula output is stable (@test_utils.R#29
  `r4` not equivalent to list(...).
  Component "y": Column 'status': Mean relative difference: 2
  
  ── 10. Failure: evalPopFormula & usePopFormula output is stable (@test_utils.R#3
  `r6` not equivalent to list(...).
  Component "y": Column 'lex.Xst': Mean relative difference: 2
  
  ── 11. Failure: evalPopFormula & usePopFormula output is stable (@test_utils.R#3
  `r7` not equivalent to list(...).
  Component "y": Column 'lex.Xst': Mean relative difference: 2
  
  ── 12. Failure: evalPopFormula & usePopFormula output is stable (@test_utils.R#3
  `r8` not equivalent to list(...).
  Component "y": Column 'lex.Xst': Mean relative difference: 2
  
  ── 13. Failure: evalPopFormula & usePopFormula output is stable (@test_utils.R#3
  `r9` not equivalent to list(...).
  Component "y": Column 'lex.Xst': Mean relative difference: 2
  
  ══ testthat results  ═══════════════════════════════════════════════════════════
  OK: 253 SKIPPED: 41 FAILED: 13
  1. Failure: Ederer I expected survival curve agrees with survival::survexp (@test_survtab_relative.R#192) 
  2. Failure: Ederer I expected survival curve agrees with survival::survexp (@test_survtab_relative.R#193) 
  3. Failure: evalPopFormula & usePopFormula output is stable (@test_utils.R#255) 
  4. Failure: evalPopFormula & usePopFormula output is stable (@test_utils.R#259) 
  5. Failure: evalPopFormula & usePopFormula output is stable (@test_utils.R#260) 
  6. Failure: evalPopFormula & usePopFormula output is stable (@test_utils.R#264) 
  7. Failure: evalPopFormula & usePopFormula output is stable (@test_utils.R#268) 
  8. Failure: evalPopFormula & usePopFormula output is stable (@test_utils.R#289) 
  9. Failure: evalPopFormula & usePopFormula output is stable (@test_utils.R#296) 
  1. ...
  
  Error: testthat unit tests failed
  Execution halted