Running ‘testthat.R’ [26s/30s]
Running the tests in ‘tests/testthat.R’ failed.
Complete output:
  > library(testthat)
  > library(xpose)
  Loading required package: ggplot2
  
  Attaching package: 'xpose'
  
  The following object is masked from 'package:stats':
  
      filter
  
  > 
  > test_check("xpose")
  ── 1. Error: (unknown) (@test-console_outputs.R#4)  ────────────────────────────
  no applicable method for 'filter_' applied to an object of class "uneval"
  1: xpdb_ex_pk %>% vpc_data(opt = vpc_opt(n_bins = 2), quiet = TRUE) %>% filter(ID == 
         110, .source = "data") %>% filter(ITERATION == 0, .source = "ext") %>% filter(bin == 
         2, .problem = 3, .source = "special", .where = "vpc_dat") at testthat/test-console_outputs.R:4
  2: withVisible(eval(quote(`_fseq`(`_lhs`)), env, env))
  3: eval(quote(`_fseq`(`_lhs`)), env, env)
  4: eval(quote(`_fseq`(`_lhs`)), env, env)
  5: `_fseq`(`_lhs`)
  6: freduce(value, `_function_list`)
  7: function_list[[i]](value)
  8: filter(., ID == 110, .source = "data")
  9: filter.default(., ID == 110, .source = "data")
  10: filter_(.data, .dots = compat_as_lazy_dots(...))
  
  ── 2. Error: (unknown) (@test-edits.R#4)  ──────────────────────────────────────
  Bad input to the argument `xpdb`
  1: xpdb_ex_pk %>% mutate.xpose_data(DV = log(DV), .problem = 1) %>% distinct.xpose_data(DV, 
         .problem = 1) %>% select.xpose_data(ID:TAD, DV, EVID, .problem = 1) %>% rename.xpose_data(TSLD = TAD, 
         .problem = 1) %>% get_data(.problem = 1) at testthat/test-edits.R:4
  2: withVisible(eval(quote(`_fseq`(`_lhs`)), env, env))
  3: eval(quote(`_fseq`(`_lhs`)), env, env)
  4: eval(quote(`_fseq`(`_lhs`)), env, env)
  5: `_fseq`(`_lhs`)
  6: freduce(value, `_function_list`)
  7: function_list[[i]](value)
  8: distinct.xpose_data(., DV, .problem = 1)
  9: edit_xpose_data(.fun = function(.data, ...) {
         dplyr::distinct(.data, ..., .keep_all = TRUE)
     }, .fname = "distinct", .data = .data, .problem = .problem, .source = .source, .where = .where, 
         ...)
  10: check_xpdb(xpdb, check = .source)
  11: stop("Bad input to the argument `xpdb`", call. = FALSE)
  
  ── 3. Failure: have proper error check for distribution_function res_distrib (@t
  `xpdb_ex_pk %>% filter(ITERATION == 0, .source = "ext") %>% prm_vs_iteration()` threw an error with unexpected message.
  Expected match: "No parameters varying across ITERATION were found"
  Actual message: "Bad input to the argument `xpdb`"
  
  ── 4. Failure: have proper error check for distribution_function res_distrib (@t
  `xpdb_ex_pk %>% mutate(ETA1 = 0, ETA2 = 0, ETA3 = 0) %>% eta_qq(drop_fixed = TRUE)` threw an error with unexpected message.
  Expected match: "No non-fixed variables available for plotting"
  Actual message: "Bad input to the argument `xpdb`"
  
  ── 5. Error: have proper error check for distribution_function res_distrib  ────
  Bad input to the argument `xpdb`
  1: quasi_label(enquo(object), label)
  2: eval_bare(get_expr(quo), get_env(quo))
  3: is.xpose.plot(xpdb_ex_pk %>% mutate(ETA1 = 0, ETA2 = 0, ETA3 = 0) %>% eta_qq(drop_fixed = FALSE))
  4: xpdb_ex_pk %>% mutate(ETA1 = 0, ETA2 = 0, ETA3 = 0) %>% eta_qq(drop_fixed = FALSE)
  5: withVisible(eval(quote(`_fseq`(`_lhs`)), env, env))
  6: eval(quote(`_fseq`(`_lhs`)), env, env)
  7: eval(quote(`_fseq`(`_lhs`)), env, env)
  8: `_fseq`(`_lhs`)
  9: freduce(value, `_function_list`)
  10: withVisible(function_list[[k]](value))
  11: function_list[[k]](value)
  12: eta_qq(., drop_fixed = FALSE)
  13: check_xpdb(xpdb, check = "data")
  14: stop("Bad input to the argument `xpdb`", call. = FALSE)
  
  ── 6. Failure: have proper error check for distribution_function res_qq (@test-p
  `xpdb_ex_pk %>% filter(ITERATION == 0, .source = "ext") %>% prm_vs_iteration()` threw an error with unexpected message.
  Expected match: "No parameters varying across ITERATION were found"
  Actual message: "Bad input to the argument `xpdb`"
  
  ── 7. Failure: have proper error check for distribution_function res_qq (@test-p
  `xpdb_ex_pk %>% mutate(ETA1 = 0, ETA2 = 0, ETA3 = 0) %>% eta_qq(drop_fixed = TRUE)` threw an error with unexpected message.
  Expected match: "No non-fixed variables available for plotting"
  Actual message: "Bad input to the argument `xpdb`"
  
  ── 8. Error: have proper error check for distribution_function res_qq  ─────────
  Bad input to the argument `xpdb`
  1: quasi_label(enquo(object), label)
  2: eval_bare(get_expr(quo), get_env(quo))
  3: is.xpose.plot(xpdb_ex_pk %>% mutate(ETA1 = 0, ETA2 = 0, ETA3 = 0) %>% eta_qq(drop_fixed = FALSE))
  4: xpdb_ex_pk %>% mutate(ETA1 = 0, ETA2 = 0, ETA3 = 0) %>% eta_qq(drop_fixed = FALSE)
  5: withVisible(eval(quote(`_fseq`(`_lhs`)), env, env))
  6: eval(quote(`_fseq`(`_lhs`)), env, env)
  7: eval(quote(`_fseq`(`_lhs`)), env, env)
  8: `_fseq`(`_lhs`)
  9: freduce(value, `_function_list`)
  10: withVisible(function_list[[k]](value))
  11: function_list[[k]](value)
  12: eta_qq(., drop_fixed = FALSE)
  13: check_xpdb(xpdb, check = "data")
  14: stop("Bad input to the argument `xpdb`", call. = FALSE)
  
  ── 9. Failure: have proper error check for distribution_function prm_distrib (@t
  `xpdb_ex_pk %>% filter(ITERATION == 0, .source = "ext") %>% prm_vs_iteration()` threw an error with unexpected message.
  Expected match: "No parameters varying across ITERATION were found"
  Actual message: "Bad input to the argument `xpdb`"
  
  ── 10. Failure: have proper error check for distribution_function prm_distrib (@
  `xpdb_ex_pk %>% mutate(ETA1 = 0, ETA2 = 0, ETA3 = 0) %>% eta_qq(drop_fixed = TRUE)` threw an error with unexpected message.
  Expected match: "No non-fixed variables available for plotting"
  Actual message: "Bad input to the argument `xpdb`"
  
  ── 11. Error: have proper error check for distribution_function prm_distrib  ───
  Bad input to the argument `xpdb`
  1: quasi_label(enquo(object), label)
  2: eval_bare(get_expr(quo), get_env(quo))
  3: is.xpose.plot(xpdb_ex_pk %>% mutate(ETA1 = 0, ETA2 = 0, ETA3 = 0) %>% eta_qq(drop_fixed = FALSE))
  4: xpdb_ex_pk %>% mutate(ETA1 = 0, ETA2 = 0, ETA3 = 0) %>% eta_qq(drop_fixed = FALSE)
  5: withVisible(eval(quote(`_fseq`(`_lhs`)), env, env))
  6: eval(quote(`_fseq`(`_lhs`)), env, env)
  7: eval(quote(`_fseq`(`_lhs`)), env, env)
  8: `_fseq`(`_lhs`)
  9: freduce(value, `_function_list`)
  10: withVisible(function_list[[k]](value))
  11: function_list[[k]](value)
  12: eta_qq(., drop_fixed = FALSE)
  13: check_xpdb(xpdb, check = "data")
  14: stop("Bad input to the argument `xpdb`", call. = FALSE)
  
  ── 12. Failure: have proper error check for distribution_function prm_qq (@test-
  `xpdb_ex_pk %>% filter(ITERATION == 0, .source = "ext") %>% prm_vs_iteration()` threw an error with unexpected message.
  Expected match: "No parameters varying across ITERATION were found"
  Actual message: "Bad input to the argument `xpdb`"
  
  ── 13. Failure: have proper error check for distribution_function prm_qq (@test-
  `xpdb_ex_pk %>% mutate(ETA1 = 0, ETA2 = 0, ETA3 = 0) %>% eta_qq(drop_fixed = TRUE)` threw an error with unexpected message.
  Expected match: "No non-fixed variables available for plotting"
  Actual message: "Bad input to the argument `xpdb`"
  
  ── 14. Error: have proper error check for distribution_function prm_qq  ────────
  Bad input to the argument `xpdb`
  1: quasi_label(enquo(object), label)
  2: eval_bare(get_expr(quo), get_env(quo))
  3: is.xpose.plot(xpdb_ex_pk %>% mutate(ETA1 = 0, ETA2 = 0, ETA3 = 0) %>% eta_qq(drop_fixed = FALSE))
  4: xpdb_ex_pk %>% mutate(ETA1 = 0, ETA2 = 0, ETA3 = 0) %>% eta_qq(drop_fixed = FALSE)
  5: withVisible(eval(quote(`_fseq`(`_lhs`)), env, env))
  6: eval(quote(`_fseq`(`_lhs`)), env, env)
  7: eval(quote(`_fseq`(`_lhs`)), env, env)
  8: `_fseq`(`_lhs`)
  9: freduce(value, `_function_list`)
  10: withVisible(function_list[[k]](value))
  11: function_list[[k]](value)
  12: eta_qq(., drop_fixed = FALSE)
  13: check_xpdb(xpdb, check = "data")
  14: stop("Bad input to the argument `xpdb`", call. = FALSE)
  
  ── 15. Failure: have proper error check for distribution_function eta_distrib (@
  `xpdb_ex_pk %>% filter(ITERATION == 0, .source = "ext") %>% prm_vs_iteration()` threw an error with unexpected message.
  Expected match: "No parameters varying across ITERATION were found"
  Actual message: "Bad input to the argument `xpdb`"
  
  ── 16. Failure: have proper error check for distribution_function eta_distrib (@
  `xpdb_ex_pk %>% mutate(ETA1 = 0, ETA2 = 0, ETA3 = 0) %>% eta_qq(drop_fixed = TRUE)` threw an error with unexpected message.
  Expected match: "No non-fixed variables available for plotting"
  Actual message: "Bad input to the argument `xpdb`"
  
  ── 17. Error: have proper error check for distribution_function eta_distrib  ───
  Bad input to the argument `xpdb`
  1: quasi_label(enquo(object), label)
  2: eval_bare(get_expr(quo), get_env(quo))
  3: is.xpose.plot(xpdb_ex_pk %>% mutate(ETA1 = 0, ETA2 = 0, ETA3 = 0) %>% eta_qq(drop_fixed = FALSE))
  4: xpdb_ex_pk %>% mutate(ETA1 = 0, ETA2 = 0, ETA3 = 0) %>% eta_qq(drop_fixed = FALSE)
  5: withVisible(eval(quote(`_fseq`(`_lhs`)), env, env))
  6: eval(quote(`_fseq`(`_lhs`)), env, env)
  7: eval(quote(`_fseq`(`_lhs`)), env, env)
  8: `_fseq`(`_lhs`)
  9: freduce(value, `_function_list`)
  10: withVisible(function_list[[k]](value))
  11: function_list[[k]](value)
  12: eta_qq(., drop_fixed = FALSE)
  13: check_xpdb(xpdb, check = "data")
  14: stop("Bad input to the argument `xpdb`", call. = FALSE)
  
  ── 18. Failure: have proper error check for distribution_function eta_qq (@test-
  `xpdb_ex_pk %>% filter(ITERATION == 0, .source = "ext") %>% prm_vs_iteration()` threw an error with unexpected message.
  Expected match: "No parameters varying across ITERATION were found"
  Actual message: "Bad input to the argument `xpdb`"
  
  ── 19. Failure: have proper error check for distribution_function eta_qq (@test-
  `xpdb_ex_pk %>% mutate(ETA1 = 0, ETA2 = 0, ETA3 = 0) %>% eta_qq(drop_fixed = TRUE)` threw an error with unexpected message.
  Expected match: "No non-fixed variables available for plotting"
  Actual message: "Bad input to the argument `xpdb`"
  
  ── 20. Error: have proper error check for distribution_function eta_qq  ────────
  Bad input to the argument `xpdb`
  1: quasi_label(enquo(object), label)
  2: eval_bare(get_expr(quo), get_env(quo))
  3: is.xpose.plot(xpdb_ex_pk %>% mutate(ETA1 = 0, ETA2 = 0, ETA3 = 0) %>% eta_qq(drop_fixed = FALSE))
  4: xpdb_ex_pk %>% mutate(ETA1 = 0, ETA2 = 0, ETA3 = 0) %>% eta_qq(drop_fixed = FALSE)
  5: withVisible(eval(quote(`_fseq`(`_lhs`)), env, env))
  6: eval(quote(`_fseq`(`_lhs`)), env, env)
  7: eval(quote(`_fseq`(`_lhs`)), env, env)
  8: `_fseq`(`_lhs`)
  9: freduce(value, `_function_list`)
  10: withVisible(function_list[[k]](value))
  11: function_list[[k]](value)
  12: eta_qq(., drop_fixed = FALSE)
  13: check_xpdb(xpdb, check = "data")
  14: stop("Bad input to the argument `xpdb`", call. = FALSE)
  
  ── 21. Failure: have proper error check for distribution_function cov_distrib (@
  `xpdb_ex_pk %>% filter(ITERATION == 0, .source = "ext") %>% prm_vs_iteration()` threw an error with unexpected message.
  Expected match: "No parameters varying across ITERATION were found"
  Actual message: "Bad input to the argument `xpdb`"
  
  ── 22. Failure: have proper error check for distribution_function cov_distrib (@
  `xpdb_ex_pk %>% mutate(ETA1 = 0, ETA2 = 0, ETA3 = 0) %>% eta_qq(drop_fixed = TRUE)` threw an error with unexpected message.
  Expected match: "No non-fixed variables available for plotting"
  Actual message: "Bad input to the argument `xpdb`"
  
  ── 23. Error: have proper error check for distribution_function cov_distrib  ───
  Bad input to the argument `xpdb`
  1: quasi_label(enquo(object), label)
  2: eval_bare(get_expr(quo), get_env(quo))
  3: is.xpose.plot(xpdb_ex_pk %>% mutate(ETA1 = 0, ETA2 = 0, ETA3 = 0) %>% eta_qq(drop_fixed = FALSE))
  4: xpdb_ex_pk %>% mutate(ETA1 = 0, ETA2 = 0, ETA3 = 0) %>% eta_qq(drop_fixed = FALSE)
  5: withVisible(eval(quote(`_fseq`(`_lhs`)), env, env))
  6: eval(quote(`_fseq`(`_lhs`)), env, env)
  7: eval(quote(`_fseq`(`_lhs`)), env, env)
  8: `_fseq`(`_lhs`)
  9: freduce(value, `_function_list`)
  10: withVisible(function_list[[k]](value))
  11: function_list[[k]](value)
  12: eta_qq(., drop_fixed = FALSE)
  13: check_xpdb(xpdb, check = "data")
  14: stop("Bad input to the argument `xpdb`", call. = FALSE)
  
  ── 24. Failure: have proper error check for distribution_function cov_qq (@test-
  `xpdb_ex_pk %>% filter(ITERATION == 0, .source = "ext") %>% prm_vs_iteration()` threw an error with unexpected message.
  Expected match: "No parameters varying across ITERATION were found"
  Actual message: "Bad input to the argument `xpdb`"
  
  ── 25. Failure: have proper error check for distribution_function cov_qq (@test-
  `xpdb_ex_pk %>% mutate(ETA1 = 0, ETA2 = 0, ETA3 = 0) %>% eta_qq(drop_fixed = TRUE)` threw an error with unexpected message.
  Expected match: "No non-fixed variables available for plotting"
  Actual message: "Bad input to the argument `xpdb`"
  
  ── 26. Error: have proper error check for distribution_function cov_qq  ────────
  Bad input to the argument `xpdb`
  1: quasi_label(enquo(object), label)
  2: eval_bare(get_expr(quo), get_env(quo))
  3: is.xpose.plot(xpdb_ex_pk %>% mutate(ETA1 = 0, ETA2 = 0, ETA3 = 0) %>% eta_qq(drop_fixed = FALSE))
  4: xpdb_ex_pk %>% mutate(ETA1 = 0, ETA2 = 0, ETA3 = 0) %>% eta_qq(drop_fixed = FALSE)
  5: withVisible(eval(quote(`_fseq`(`_lhs`)), env, env))
  6: eval(quote(`_fseq`(`_lhs`)), env, env)
  7: eval(quote(`_fseq`(`_lhs`)), env, env)
  8: `_fseq`(`_lhs`)
  9: freduce(value, `_function_list`)
  10: withVisible(function_list[[k]](value))
  11: function_list[[k]](value)
  12: eta_qq(., drop_fixed = FALSE)
  13: check_xpdb(xpdb, check = "data")
  14: stop("Bad input to the argument `xpdb`", call. = FALSE)
  
  ── 27. Failure: set_vars_type works properly (@test-set_vars.R#15)  ────────────
  is.xpdb(xpdb_2) isn't true.
  
  ── 28. Failure: set_vars_units and set_vars_label works properly (@test-set_vars
  is.xpdb(xpdb_3) isn't true.
  
  ── 29. Error: (unknown) (@test-vpc.R#17)  ──────────────────────────────────────
  Bad input to the argument `xpdb`
  1: xpdb_ex_pk %>% vpc_data(opt = vpc_opt(n_bins = 3, lloq = 0.1), quiet = TRUE) %>% 
         vpc_data(vpc_type = "cens", opt = vpc_opt(n_bins = 3, lloq = 0.4), quiet = TRUE) at testthat/test-vpc.R:17
  2: withVisible(eval(quote(`_fseq`(`_lhs`)), env, env))
  3: eval(quote(`_fseq`(`_lhs`)), env, env)
  4: eval(quote(`_fseq`(`_lhs`)), env, env)
  5: `_fseq`(`_lhs`)
  6: freduce(value, `_function_list`)
  7: withVisible(function_list[[k]](value))
  8: function_list[[k]](value)
  9: vpc_data(., vpc_type = "cens", opt = vpc_opt(n_bins = 3, lloq = 0.4), quiet = TRUE)
  10: check_xpdb(xpdb, check = ifelse(is.null(psn_folder), "data", FALSE))
  11: stop("Bad input to the argument `xpdb`", call. = FALSE)
  
  ── 30. Error: (unknown) (@test-xpdb_access.R#4)  ───────────────────────────────
  Bad input to the argument `xpdb`
  1: xpdb_ex_pk %>% vpc_data(quiet = TRUE) %>% vpc_data(vpc_type = "censored", opt = vpc_opt(lloq = 0.4), 
         quiet = TRUE) at testthat/test-xpdb_access.R:4
  2: withVisible(eval(quote(`_fseq`(`_lhs`)), env, env))
  3: eval(quote(`_fseq`(`_lhs`)), env, env)
  4: eval(quote(`_fseq`(`_lhs`)), env, env)
  5: `_fseq`(`_lhs`)
  6: freduce(value, `_function_list`)
  7: withVisible(function_list[[k]](value))
  8: function_list[[k]](value)
  9: vpc_data(., vpc_type = "censored", opt = vpc_opt(lloq = 0.4), quiet = TRUE)
  10: check_xpdb(xpdb, check = ifelse(is.null(psn_folder), "data", FALSE))
  11: stop("Bad input to the argument `xpdb`", call. = FALSE)
  
  ── 31. Failure: Check check_xpdb (@test-xplot_helpers.R#84)  ───────────────────
  `check_xpdb(xpdb_NULL, check = "data")` threw an error with unexpected message.
  Expected match: "No `data` slot could be found in this xpdb"
  Actual message: "Bad input to the argument `xpdb`"
  
  ── 32. Error: Check check_xpdb (@test-xplot_helpers.R#85)  ─────────────────────
  Bad input to the argument `xpdb`
  1: expect_null(check_xpdb(xpdb_NULL, check = FALSE)) at testthat/test-xplot_helpers.R:85
  2: quasi_label(enquo(object), label)
  3: eval_bare(get_expr(quo), get_env(quo))
  4: check_xpdb(xpdb_NULL, check = FALSE)
  5: stop("Bad input to the argument `xpdb`", call. = FALSE)
  
  ── 33. Failure: faceting works properly (@test-xpose-default-plots.R#100)  ─────
  as.character(p3$facet$params$cols[[1]]) not equal to "SEX".
  Lengths differ: 2 is not 1
  
  ── 34. Error: faceting works properly (@test-xpose-default-plots.R#101)  ───────
  subscript out of bounds
  1: expect_equal(as.character(p3$facet$params$rows[[1]]), "OCC") at testthat/test-xpose-default-plots.R:101
  2: quasi_label(enquo(object), label)
  3: eval_bare(get_expr(quo), get_env(quo))
  
  ── 35. Error: properly handles errors in summary (@test-xpose_data.R#78)  ──────
  Argument `xp_theme` must be a full xpose theme. To modify a theme use update_themes() instead.
  1: expect_warning(xpdb_4 <- xpose_data(runno = "001", ext = ".lst", dir = "data", ignore = c("data", 
         "files"), quiet = TRUE, xp_theme = broken_theme), regexp = "Failed to create run summary") at testthat/test-xpose_data.R:78
  2: quasi_capture(enquo(object), capture_warnings, label = label)
  3: capture(act$val <- eval_bare(get_expr(quo), get_env(quo)))
  4: withCallingHandlers(code, warning = function(condition) {
         out$push(condition)
         invokeRestart("muffleWarning")
     })
  5: eval_bare(get_expr(quo), get_env(quo))
  6: xpose_data(runno = "001", ext = ".lst", dir = "data", ignore = c("data", "files"), 
         quiet = TRUE, xp_theme = broken_theme)
  7: stop("Argument `xp_theme` must be a full xpose theme. To modify a theme use update_themes() instead.", 
         call. = FALSE)
  
  ══ testthat results  ═══════════════════════════════════════════════════════════
  OK: 398 SKIPPED: 6 FAILED: 35
  1. Error: (unknown) (@test-console_outputs.R#4) 
  2. Error: (unknown) (@test-edits.R#4) 
  3. Failure: have proper error check for distribution_function res_distrib (@test-plots.R#72) 
  4. Failure: have proper error check for distribution_function res_distrib (@test-plots.R#74) 
  5. Error: have proper error check for distribution_function res_distrib 
  6. Failure: have proper error check for distribution_function res_qq (@test-plots.R#72) 
  7. Failure: have proper error check for distribution_function res_qq (@test-plots.R#74) 
  8. Error: have proper error check for distribution_function res_qq 
  9. Failure: have proper error check for distribution_function prm_distrib (@test-plots.R#72) 
  1. ...
  
  Error: testthat unit tests failed
  Execution halted