-
Notifications
You must be signed in to change notification settings - Fork 340
Closed
Labels
bugan unexpected problem or unintended behavioran unexpected problem or unintended behaviortests 📘
Milestone
Description
I had a lot of tests that started not passing on a Docker container. They continue to work on my local machine. When I print the traceback, it's complaining about some environment variable.
If lr is a ListReporter, then I'm printing lr$results$as_list()[[1]]$results
I assume this is the result of some update. How can I cirumvent this behavior and go back to the old behavior?
<expectation_warning/expectation/condition>
Changing language has no effect when envvar LC_ALL='C.UTF-8'
Backtrace:
â–†
1. └─global calcGradesForGradescope("hw1.R", "hw1_test.R")
2. └─testthat::test_file(test_file, reporter = lr, env = scriptResults)
3. └─testthat:::test_files(...)
4. └─testthat:::test_files_serial(...)
5. ├─testthat::with_reporter(...)
6. │ └─base::tryCatch(...)
7. │ └─base (local) tryCatchList(expr, classes, parentenv, handlers)
8. │ └─base (local) tryCatchOne(expr, names, parentenv, handlers[[1L]])
9. │ └─base (local) doTryCatch(return(expr), name, parentenv, handler)
10. └─base::lapply(...)
11. └─testthat (local) FUN(X[[i]], ...)
12. └─testthat::source_file(path, env = env(env), desc = desc, error_call = error_call)
13. └─testthat:::test_code(test = NULL, code = exprs, env = env, default_reporter = StopReporter$new())
14. ├─base::tryCatch(...)
15. │ └─base (local) tryCatchList(expr, classes, parentenv, handlers)
16. │ ├─base (local) tryCatchOne(...)
17. │ │ └─base (local) doTryCatch(return(expr), name, parentenv, handler)
18. │ └─base (local) tryCatchList(expr, names[-nh], parentenv, handlers[-nh])
19. │ └─base (local) tryCatchOne(expr, names, parentenv, handlers[[1L]])
20. │ └─base (local) doTryCatch(return(expr), name, parentenv, handler)
21. ├─base::withCallingHandlers(...)
22. └─base::eval(code, test_env)
23. └─base::eval(code, test_env)
24. └─testthat::test_that(...) at hw1_test.R:117:1
25. └─testthat:::test_code(desc, code, env = parent.frame(), default_reporter = local_interactive_reporter())
26. └─testthat:::testthat_state_condition(before, after, call = sys.call(-1))
27. └─testthat:::waldo_compare(before, after, x_arg = "before", y_arg = "after")
28. └─testthat:::local_reporter_output()
29. └─reporter$local_user_output(.env)
30. └─testthat::local_reproducible_output(...)
31. └─withr::local_language(lang, .local_envir = .env)
32. └─withr:::check_language_envvar("LC_ALL")
Metadata
Metadata
Assignees
Labels
bugan unexpected problem or unintended behavioran unexpected problem or unintended behaviortests 📘