Running ‘testthat.R’ [26s/44s]
Running the tests in ‘tests/testthat.R’ failed.
Complete output:
  > # This file is part of the standard setup for testthat.
  > # It is recommended that you do not modify it.
  > #
  > # Where should you do additional test configuration?
  > # Learn more about the roles of various files in:
  > # * https://r-pkgs.org/tests.html
  > # * https://testthat.r-lib.org/reference/test_package.html#special-files
  > 
  > library(testthat)
  > library(tidyfit)
  > 
  > test_check("tidyfit")
  
  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
  
  [ FAIL 2 | WARN 0 | SKIP 0 | PASS 132 ]
  
  ══ Failed tests ════════════════════════════════════════════════════════════════
  ── Error ('test-bayes.R:7:3'): bayes regression works ──────────────────────────
  <purrr_error_indexed/rlang_error/error/condition>
  Error in `purrr::map(mods$model_object, function(mod) mod$fit(data))`: i In index: 1.
  Caused by error in `loadNamespace()`:
  ! there is no package called 'arm'
  Backtrace:
       ▆
    1. ├─tidyfit::m("bayes", medv ~ ., df_reg) at test-bayes.R:7:2
    2. │ └─purrr::map(mods$model_object, function(mod) mod$fit(data))
    3. │   └─purrr:::map_("list", .x, .f, ..., .progress = .progress)
    4. │     ├─purrr:::with_indexed_errors(...)
    5. │     │ └─base::withCallingHandlers(...)
    6. │     ├─purrr:::call_with_cleanup(...)
    7. │     └─tidyfit (local) .f(.x[[i]], ...)
    8. │       └─mod$fit(data)
    9. │         ├─tidyfit:::.fit(self, ...)
   10. │         └─tidyfit:::.fit.bayes(self, ...)
   11. │           ├─names(self$args) %in% methods::formalArgs(arm::bayesglm)
   12. │           └─methods::formalArgs(arm::bayesglm)
   13. │             └─base::formals(def, envir = parent.frame())
   14. ├─base::loadNamespace(x)
   15. │ ├─base::withRestarts(stop(cond), retry_loadNamespace = function() NULL)
   16. │ │ └─base (local) withOneRestart(expr, restarts[[1L]])
   17. │ │   └─base (local) doWithOneRestart(return(expr), restart)
   18. │ └─base::stop(cond)
   19. └─purrr (local) `<fn>`(`<pckgNtFE>`)
   20.   └─cli::cli_abort(...)
   21.     └─rlang::abort(...)
  ── Error ('test-bayes.R:21:3'): bayes classification works ─────────────────────
  <purrr_error_indexed/rlang_error/error/condition>
  Error in `map(.x, .f, ...)`: i In index: 1.
  Caused by error in `loadNamespace()`:
  ! there is no package called 'arm'
  Backtrace:
       ▆
    1. ├─tidyfit::classify(df_cls2, Species ~ ., m("bayes")) at test-bayes.R:21:2
    2. │ └─eval_df %>% purrr::transpose() %>% ...
    3. ├─purrr::map_dfr(., function(row) fit_progress(row))
    4. │ └─purrr::map(.x, .f, ...)
    5. │   └─purrr:::map_("list", .x, .f, ..., .progress = .progress)
    6. │     ├─purrr:::with_indexed_errors(...)
    7. │     │ └─base::withCallingHandlers(...)
    8. │     ├─purrr:::call_with_cleanup(...)
    9. │     └─tidyfit (local) .f(.x[[i]], ...)
   10. │       └─tidyfit (local) fit_progress(row)
   11. │         └─tidyfit:::.fit_groups(row, ...)
   12. │           └─dplyr::tibble(model = row$model, grid_id = row$grid_id, model_object = list(mod$set_args(weights = wts)$fit(data)))
   13. │             └─tibble:::tibble_quos(xs, .rows, .name_repair)
   14. │               └─rlang::eval_tidy(xs[[j]], mask)
   15. ├─mod$set_args(weights = wts)$fit(data)
   16. │ ├─tidyfit:::.fit(self, ...)
   17. │ └─tidyfit:::.fit.bayes(self, ...)
   18. │   ├─names(self$args) %in% methods::formalArgs(arm::bayesglm)
   19. │   └─methods::formalArgs(arm::bayesglm)
   20. │     └─base::formals(def, envir = parent.frame())
   21. ├─base::loadNamespace(x)
   22. │ ├─base::withRestarts(stop(cond), retry_loadNamespace = function() NULL)
   23. │ │ └─base (local) withOneRestart(expr, restarts[[1L]])
   24. │ │   └─base (local) doWithOneRestart(return(expr), restart)
   25. │ └─base::stop(cond)
   26. └─purrr (local) `<fn>`(`<pckgNtFE>`)
   27.   └─cli::cli_abort(...)
   28.     └─rlang::abort(...)
  
  [ FAIL 2 | WARN 0 | SKIP 0 | PASS 132 ]
  Error: Test failures
  Execution halted