Running ‘testthat.R’ [13s/20s]
Running the tests in ‘tests/testthat.R’ failed.
Complete output:
  > library(testthat)
  > library(cchsflow)
  Loading required package: haven
  Loading required package: dplyr
  
  Attaching package: 'dplyr'
  
  The following object is masked from 'package:testthat':
  
      matches
  
  The following objects are masked from 'package:stats':
  
      filter, lag
  
  The following objects are masked from 'package:base':
  
      intersect, setdiff, setequal, union
  
  Loading required package: sjlabelled
  
  Attaching package: 'sjlabelled'
  
  The following object is masked from 'package:dplyr':
  
      as_label
  
  The following objects are masked from 'package:haven':
  
      as_factor, read_sas, read_spss, read_stata, write_sas, zap_labels
  
  Loading required package: stringr
  Loading required package: magrittr
  
  Attaching package: 'magrittr'
  
  The following objects are masked from 'package:testthat':
  
      equals, is_less_than, not
  
  > 
  > test_check("cchsflow")
  ── 1. Failure: rec_with_table matches the standard 2001 recode (@test-recode-wit
  act$val[exp_nms] not equal to exp$val.
  Component "ADL_01": Attributes: < Component "labels": Modes: numeric, character >
  Component "ADL_01": Attributes: < Component "labels": Lengths: 2, 5 >
  Component "ADL_01": Attributes: < Component "labels": Names: Lengths (2, 5) differ (string compare on first 2) >
  Component "ADL_01": Attributes: < Component "labels": Names: 'is.NA' value mismatch: 0 in current 1 in target >
  Component "ADL_01": Attributes: < Component "labels": target is numeric, current is character >
  Component "ADL_01": Attributes: < Component "labels_long": Modes: list, character >
  Component "ADL_03": Attributes: < Component "labels": Modes: numeric, character >
  Component "ADL_03": Attributes: < Component "labels": Lengths: 2, 5 >
  Component "ADL_03": Attributes: < Component "labels": Names: Lengths (2, 5) differ (string compare on first 2) >
  ...
  
  ── 2. Failure: rec_with_table matches the standard 2003 recode (@test-recode-wit
  act$val[exp_nms] not equal to exp$val.
  Component "ADL_01": Attributes: < Component "labels": Modes: numeric, character >
  Component "ADL_01": Attributes: < Component "labels": Lengths: 2, 5 >
  Component "ADL_01": Attributes: < Component "labels": Names: Lengths (2, 5) differ (string compare on first 2) >
  Component "ADL_01": Attributes: < Component "labels": Names: 'is.NA' value mismatch: 0 in current 1 in target >
  Component "ADL_01": Attributes: < Component "labels": target is numeric, current is character >
  Component "ADL_01": Attributes: < Component "labels_long": Modes: list, character >
  Component "ADL_02": Attributes: < Component "labels": Modes: numeric, character >
  Component "ADL_02": Attributes: < Component "labels": Lengths: 2, 5 >
  Component "ADL_02": Attributes: < Component "labels": Names: Lengths (2, 5) differ (string compare on first 2) >
  ...
  
  ── 3. Failure: rec_with_table matches the standard 2005 recode (@test-recode-wit
  act$val[exp_nms] not equal to exp$val.
  Component "ADL_01": Attributes: < Component "labels": Modes: numeric, character >
  Component "ADL_01": Attributes: < Component "labels": Lengths: 2, 5 >
  Component "ADL_01": Attributes: < Component "labels": Names: Lengths (2, 5) differ (string compare on first 2) >
  Component "ADL_01": Attributes: < Component "labels": Names: 'is.NA' value mismatch: 0 in current 1 in target >
  Component "ADL_01": Attributes: < Component "labels": target is numeric, current is character >
  Component "ADL_01": Attributes: < Component "labels_long": Modes: list, character >
  Component "ADL_02": Attributes: < Component "labels": Modes: numeric, character >
  Component "ADL_02": Attributes: < Component "labels": Lengths: 2, 5 >
  Component "ADL_02": Attributes: < Component "labels": Names: Lengths (2, 5) differ (string compare on first 2) >
  ...
  
  ── 4. Failure: rec_with_table matches the standard 2014 recode (@test-recode-wit
  act$val[exp_nms] not equal to exp$val.
  Component "ADL_01": Attributes: < Component "labels": Modes: numeric, character >
  Component "ADL_01": Attributes: < Component "labels": Lengths: 2, 5 >
  Component "ADL_01": Attributes: < Component "labels": Names: Lengths (2, 5) differ (string compare on first 2) >
  Component "ADL_01": Attributes: < Component "labels": Names: 'is.NA' value mismatch: 0 in current 1 in target >
  Component "ADL_01": Attributes: < Component "labels": target is numeric, current is character >
  Component "ADL_01": Attributes: < Component "labels_long": Modes: list, character >
  Component "ADL_02": Attributes: < Component "labels": Modes: numeric, character >
  Component "ADL_02": Attributes: < Component "labels": Lengths: 2, 5 >
  Component "ADL_02": Attributes: < Component "labels": Names: Lengths (2, 5) differ (string compare on first 2) >
  ...
  
  ══ testthat results  ═══════════════════════════════════════════════════════════
  [ OK: 155 | SKIPPED: 0 | WARNINGS: 0 | FAILED: 4 ]
  1. Failure: rec_with_table matches the standard 2001 recode (@test-recode-with-table.R#6) 
  2. Failure: rec_with_table matches the standard 2003 recode (@test-recode-with-table.R#14) 
  3. Failure: rec_with_table matches the standard 2005 recode (@test-recode-with-table.R#22) 
  4. Failure: rec_with_table matches the standard 2014 recode (@test-recode-with-table.R#30) 
  
  Error: testthat unit tests failed
  Execution halted