-
Notifications
You must be signed in to change notification settings - Fork 318
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Parallel testing fails when warnings are treated as errors #1912
Comments
This was referenced Dec 1, 2023
I think my advice would be "don't do that". Is it possible to scope the change to use |
Thanks. I reduced the scope to file-level and this works with parallel testing: pkgload::load_all()
test_script_paths <- testthat::find_test_scripts("tests/testthat")
test_with_warning_as_error <- function(path) {
withr::local_options(list(warn = 2L))
testthat::test_file(path, stop_on_failure = TRUE)
}
purrr::walk(test_script_paths, test_with_warning_as_error) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uncovered while working on r-lib/lintr#2297.
Minimal reprex
Created on 2023-12-01 with reprex v2.0.2
Standard output and standard error
Session info
The text was updated successfully, but these errors were encountered: