Running ‘testthat.R’ [32s/34s]
Running the tests in ‘tests/testthat.R’ failed.
Complete output:
  > library(testthat)
  > library(sjmisc)
  > 
  > test_check("sjmisc")
  
   iter imp variable
    1   1  Species
    1   2  Species
    1   3  Species
    1   4  Species
    1   5  Species
    2   1  Species
    2   2  Species
    2   3  Species
    2   4  Species
    2   5  Species
    3   1  Species
    3   2  Species
    3   3  Species
    3   4  Species
    3   5  Species
    4   1  Species
    4   2  Species
    4   3  Species
    4   4  Species
    4   5  Species
    5   1  Species
    5   2  Species
    5   3  Species
    5   4  Species
    5   5  Species
  One or more of the old values are recoded into identical new values.
  Please check if you correctly specified the recode-pattern,
  else separate multiple values with comma, e.g. rec="a,b,c=1; d,e,f=2".
  [ FAIL 6 | WARN 2 | SKIP 11 | PASS 134 ]
  
  ══ Skipped tests ═══════════════════════════════════════════════════════════════
  • On CRAN (3)
  • empty test (8)
  
  ══ Failed tests ════════════════════════════════════════════════════════════════
  ── Error (test-frq_whitespace.R:10:1): (code run outside of `test_that()`) ─────
  Error in `set_labels_helper(x = .dat, labels = labels, force.labels = force.labels, 
      force.values = force.values, drop.na = drop.na, var.name = NULL)`: Package 'haven' required for this function. Please install it.
  Backtrace:
      ▆
   1. ├─sjmisc::rec(dat, y.char, suffix = "_r", as.num = TRUE, rec = "Category1 = 1 [Label 1]; Category2 = 2 [Label 2]; Category3 = 3 [Label 3];") at test-frq_whitespace.R:10:0
   2. └─sjmisc:::rec.default(...)
   3.   └─sjmisc:::rec_core_fun(...)
   4.     └─sjmisc:::rec_helper(...)
   5.       ├─base::suppressWarnings(sjlabelled::set_labels(x = new_var, labels = val_lab))
   6.       │ └─base::withCallingHandlers(...)
   7.       └─sjlabelled::set_labels(x = new_var, labels = val_lab)
   8.         └─sjlabelled:::set_labels_helper(...)
  ── Error (test-rec.R:12:3): rec ────────────────────────────────────────────────
  Error in `get_na_helper(x, as.tag)`: Package 'haven' required for this function. Please install it.
  Backtrace:
       ▆
    1. ├─testthat::expect_equal(...) at test-rec.R:12:2
    2. │ └─testthat::quasi_label(enquo(object), label, arg = "object")
    3. │   └─rlang::eval_bare(expr, quo_get_env(quo))
    4. ├─base::unique(rec(efc$c82cop1, rec = "1,2=1; NA=9; else=copy"))
    5. ├─sjmisc::rec(efc$c82cop1, rec = "1,2=1; NA=9; else=copy")
    6. └─sjmisc:::rec.default(efc$c82cop1, rec = "1,2=1; NA=9; else=copy")
    7.   └─sjmisc:::rec_core_fun(...)
    8.     └─sjmisc:::rec_helper(...)
    9.       ├─sjlabelled::get_na(x)
   10.       └─sjlabelled:::get_na.default(x)
   11.         └─sjlabelled:::get_na_helper(x, as.tag)
  ── Error (test-rec.R:39:3): rec rev ────────────────────────────────────────────
  Error in `set_labels_helper(x = .dat, labels = labels, force.labels = force.labels, 
      force.values = force.values, drop.na = drop.na, var.name = NULL)`: Package 'haven' required for this function. Please install it.
  Backtrace:
      ▆
   1. └─sjlabelled::set_labels(x, labels = c(`1` = "a", `2` = "b", `3` = "c")) at test-rec.R:39:2
   2.   └─sjlabelled:::set_labels_helper(...)
  ── Error (test-reflvl.R:8:3): ref_lvl ──────────────────────────────────────────
  Error in `set_labels_helper(x = .dat, labels = labels, force.labels = force.labels, 
      force.values = force.values, drop.na = drop.na, var.name = NULL)`: Package 'haven' required for this function. Please install it.
  Backtrace:
      ▆
   1. ├─sjlabelled::to_factor(efc$e42dep) at test-reflvl.R:8:2
   2. └─sjlabelled:::as_factor.default(efc$e42dep)
   3.   └─sjlabelled:::to_fac_helper(x, add.non.labelled)
   4.     ├─base::suppressMessages(...)
   5.     │ └─base::withCallingHandlers(...)
   6.     └─sjlabelled::set_labels(...)
   7.       └─sjlabelled:::set_labels_helper(...)
  ── Error (test-setna.R:8:3): set_na ────────────────────────────────────────────
  Error in `set_na_helper(x = .dat, value = na, drop.levels = drop.levels, 
      as.tag = as.tag, var.name = NULL)`: Package 'haven' required for this function. Please install it.
  Backtrace:
      ▆
   1. ├─testthat::expect_equal(...) at test-setna.R:8:2
   2. │ └─testthat::quasi_label(enquo(object), label, arg = "object")
   3. │   └─rlang::eval_bare(expr, quo_get_env(quo))
   4. ├─base::nlevels(set_na(x, na = "b", as.tag = TRUE))
   5. │ └─base::levels(x)
   6. └─sjlabelled::set_na(x, na = "b", as.tag = TRUE)
   7.   └─sjlabelled:::set_na_helper(...)
  ── Error (test-setna.R:14:3): set_na ───────────────────────────────────────────
  Error in `set_na_helper(x = .dat, value = na, drop.levels = drop.levels, 
      as.tag = as.tag, var.name = NULL)`: Package 'haven' required for this function. Please install it.
  Backtrace:
      ▆
   1. ├─testthat::expect_true(...) at test-setna.R:14:2
   2. │ └─testthat::quasi_label(enquo(object), label, arg = "object")
   3. │   └─rlang::eval_bare(expr, quo_get_env(quo))
   4. └─sjlabelled::set_na(x, na = 1, as.tag = FALSE)
   5.   └─sjlabelled:::set_na_helper(...)
  
  [ FAIL 6 | WARN 2 | SKIP 11 | PASS 134 ]
  Error: Test failures
  Execution halted