Running ‘testthat.R’ [6s/10s]
Running the tests in ‘tests/testthat.R’ failed.
Complete output:
  > library(testthat)
  > library(janitor)
  
  Attaching package: 'janitor'
  
  The following objects are masked from 'package:stats':
  
      chisq.test, fisher.test
  
  > 
  > test_check("janitor")
  ── 1. Error: (unknown) (@test-add-totals.R#13)  ────────────────────────────────
  'where' must be an environment
  Backtrace:
    9. janitor::tabyl(., a, b)
   11. janitor:::tabyl_2way(...)
   13. tidyr:::complete.data.frame(tabl, !!var1, !!var2)
   14. tidyr::replace_na(full, replace = fill)
   15. ellipsis::check_dots_used()
   17. ellipsis:::exit_handler(action)
   18. base::bquote(...)
  
  ── 2. Error: (unknown) (@test-adorn-ns.R#8)  ───────────────────────────────────
  'where' must be an environment
  Backtrace:
    1. tibble::tibble(...)
    9. janitor::tabyl(., x, y)
   11. janitor:::tabyl_2way(...)
   13. tidyr:::complete.data.frame(tabl, !!var1, !!var2)
   14. tidyr::replace_na(full, replace = fill)
   15. ellipsis::check_dots_used()
   17. ellipsis:::exit_handler(action)
   18. base::bquote(...)
  
  ── 3. Error: (unknown) (@test-adorn-pct-formatting.R#8)  ───────────────────────
  'where' must be an environment
  Backtrace:
    8. janitor::tabyl(., cyl, am)
   10. janitor:::tabyl_2way(...)
   12. tidyr:::complete.data.frame(tabl, !!var1, !!var2)
   13. tidyr::replace_na(full, replace = fill)
   14. ellipsis::check_dots_used()
   16. ellipsis:::exit_handler(action)
   17. base::bquote(...)
  
  ── 4. Error: (unknown) (@test-adorn-percentages.R#8)  ──────────────────────────
  'where' must be an environment
  Backtrace:
    9. janitor::tabyl(., cyl, am)
   11. janitor:::tabyl_2way(...)
   13. tidyr:::complete.data.frame(tabl, !!var1, !!var2)
   14. tidyr::replace_na(full, replace = fill)
   15. ellipsis::check_dots_used()
   17. ellipsis:::exit_handler(action)
   18. base::bquote(...)
  
  ── 5. Error: (unknown) (@test-adorn-rounding.R#15)  ────────────────────────────
  'where' must be an environment
  Backtrace:
    8. janitor::tabyl(., a, b)
   10. janitor:::tabyl_2way(...)
   12. tidyr:::complete.data.frame(tabl, !!var1, !!var2)
   13. tidyr::replace_na(full, replace = fill)
   14. ellipsis::check_dots_used()
   16. ellipsis:::exit_handler(action)
   17. base::bquote(...)
  
  ── 6. Error: (unknown) (@test-adorn-title.R#8)  ────────────────────────────────
  'where' must be an environment
  Backtrace:
    9. janitor::tabyl(., gear, cyl)
   11. janitor:::tabyl_2way(...)
   13. tidyr:::complete.data.frame(tabl, !!var1, !!var2)
   14. tidyr::replace_na(full, replace = fill)
   15. ellipsis::check_dots_used()
   17. ellipsis:::exit_handler(action)
   18. base::bquote(...)
  
  Reading layer `nc' from data source `/home/hornik/tmp/R.check/r-devel-gcc/Work/build/Packages/sf/shape/nc.shp' using driver `ESRI Shapefile'
  Simple feature collection with 100 features and 14 fields
  geometry type:  MULTIPOLYGON
  dimension:      XY
  bbox:           xmin: -84.32385 ymin: 33.88199 xmax: -75.45698 ymax: 36.58965
  geographic CRS: NAD27
  ── 9. Error: (unknown) (@test-clean-names.R#414)  ──────────────────────────────
  Internal error: Trace data is not square.
  Backtrace:
    1. testthat::test_check("janitor")
    2. testthat:::test_package_dir(...)
    3. testthat::test_dir(...)
    4. testthat:::test_files(...)
   10. base::lapply(...)
   11. testthat:::FUN(X[[i]], ...)
   17. testthat::source_file(...)
   18. testthat:::test_code(NULL, exprs, env)
   27. [ base::eval(...) ] with 1 more call
   29. testthat::test_that(...)
       ...
   40. testthat:::o_apply(...)
   41. base::lapply(objects, function(x) x[[method]](...))
   42. testthat:::FUN(X[[i]], ...)
   43. x[[method]](...)
   47. testthat:::failure_summary(result, self$n_fail)
   50. testthat:::format.expectation(x)
   51. testthat:::format_with_trace(x)
   53. rlang:::format.rlang_trace(...)
   54. rlang:::trace_format_branch(x, max_frames, dir, srcrefs)
   55. rlang:::branch_uncollapse_pipe(trace)
  
  ── 10. Error: (unknown) (@test-tabyl-classifiers.R#7)  ─────────────────────────
  'where' must be an environment
  Backtrace:
    9. janitor::tabyl(., cyl, carb)
   11. janitor:::tabyl_2way(...)
   13. tidyr:::complete.data.frame(tabl, !!var1, !!var2)
   14. tidyr::replace_na(full, replace = fill)
   15. ellipsis::check_dots_used()
   17. ellipsis:::exit_handler(action)
   18. base::bquote(...)
  
  ── 11. Error: (unknown) (@test-tabyl.R#7)  ─────────────────────────────────────
  'where' must be an environment
  Backtrace:
   1. janitor::tabyl(mtcars$cyl)
   2. janitor:::tabyl.default(mtcars$cyl)
   3. tidyr::replace_na(result, replace = list(n = 0, percent = 0))
   4. ellipsis::check_dots_used()
   6. ellipsis:::exit_handler(action)
   7. base::bquote(...)
  
  ── 12. Error: (unknown) (@test-tests.R#9)  ─────────────────────────────────────
  'where' must be an environment
  Backtrace:
    1. janitor::tabyl(mtcars3, am, cyl)
    2. janitor:::tabyl.data.frame(mtcars3, am, cyl)
    3. janitor:::tabyl_2way(...)
    5. tidyr:::complete.data.frame(tabl, !!var1, !!var2)
    6. tidyr::replace_na(full, replace = fill)
    7. ellipsis::check_dots_used()
    9. ellipsis:::exit_handler(action)
   10. base::bquote(...)
  
  ── 13. Error: values are correct (@test-top-levels.R#12)  ──────────────────────
  'where' must be an environment
  Backtrace:
    1. testthat::expect_equal(top_levels(fac)[[3]], c(3/7, 2/7, 2/7))
    4. janitor::top_levels(fac)
    6. janitor:::tabyl.default(new_vec, show_na = show_na)
    7. tidyr::replace_na(result, replace = list(n = 0, percent = 0))
    8. ellipsis::check_dots_used()
   10. ellipsis:::exit_handler(action)
   11. base::bquote(...)
  
  ── 14. Error: missing levels are represented (@test-top-levels.R#24)  ──────────
  'where' must be an environment
  Backtrace:
    1. testthat::expect_equal(...)
    4. janitor::top_levels(x)
    6. janitor:::tabyl.default(new_vec, show_na = show_na)
    7. tidyr::replace_na(result, replace = list(n = 0, percent = 0))
    8. ellipsis::check_dots_used()
   10. ellipsis:::exit_handler(action)
   11. base::bquote(...)
  
  ── 15. Error: NA results are treated appropriately (@test-top-levels.R#34)  ────
  'where' must be an environment
  Backtrace:
    1. testthat::expect_equal(top_levels(fac_na)[[2]], rep(2, 3))
    4. janitor::top_levels(fac_na)
    6. janitor:::tabyl.default(new_vec, show_na = show_na)
    7. tidyr::replace_na(result, replace = list(n = 0, percent = 0))
    8. ellipsis::check_dots_used()
   10. ellipsis:::exit_handler(action)
   11. base::bquote(...)
  
  ── 16. Error: default n parameter works (@test-top-levels.R#41)  ───────────────
  'where' must be an environment
  Backtrace:
    1. testthat::expect_equal(top_levels(fac), top_levels(fac, 2))
    4. janitor::top_levels(fac)
    6. janitor:::tabyl.default(new_vec, show_na = show_na)
    7. tidyr::replace_na(result, replace = list(n = 0, percent = 0))
    8. ellipsis::check_dots_used()
   10. ellipsis:::exit_handler(action)
   11. base::bquote(...)
  
  ── 17. Error: missing levels are treated appropriately (@test-top-levels.R#47)  
  'where' must be an environment
  Backtrace:
    1. testthat::expect_equal(...)
    4. janitor::top_levels(fac_missing_lvl)
    6. janitor:::tabyl.default(new_vec, show_na = show_na)
    7. tidyr::replace_na(result, replace = list(n = 0, percent = 0))
    8. ellipsis::check_dots_used()
   10. ellipsis:::exit_handler(action)
   11. base::bquote(...)
  
  ── 18. Error: correct variable name assigned to first column of result (@test-to
  'where' must be an environment
  Backtrace:
    1. testthat::expect_equal(names(top_levels(fac))[1], "fac")
    4. janitor::top_levels(fac)
    6. janitor:::tabyl.default(new_vec, show_na = show_na)
    7. tidyr::replace_na(result, replace = list(n = 0, percent = 0))
    8. ellipsis::check_dots_used()
   10. ellipsis:::exit_handler(action)
   11. base::bquote(...)
  
  ══ testthat results  ═══════════════════════════════════════════════════════════
  [ OK: 297 | SKIPPED: 0 | WARNINGS: 0 | FAILED: 18 ]
  1. Error: (unknown) (@test-add-totals.R#13) 
  2. Error: (unknown) (@test-adorn-ns.R#8) 
  3. Error: (unknown) (@test-adorn-pct-formatting.R#8) 
  4. Error: (unknown) (@test-adorn-percentages.R#8) 
  5. Error: (unknown) (@test-adorn-rounding.R#15) 
  6. Error: (unknown) (@test-adorn-title.R#8) 
  7. Error: tbl_graph/tidygraph (@test-clean-names.R#417) 
  8. Error: tbl_graph/tidygraph (@test-clean-names.R#414) 
  9. Error: (unknown) (@test-clean-names.R#414) 
  1. ...
  
  Error: testthat unit tests failed
  Execution halted