|
1 | 1 | # testthat (development version) |
2 | 2 |
|
3 | | -* `set_state_inspector()` allows to to register a function that's called |
4 | | - before and after every test, reporting on any differences. This |
5 | | - is very useful for detecting if any of your tests have made changes to |
6 | | - global state (like options, env vars, or connections) (#1674). This |
7 | | - function was inspired by renv's testing infrastructure. |
8 | | - |
9 | | -* Only report test files that take longer than a second (#1806). |
10 | | - |
11 | 3 | * New `expect_contains()` and `expect_in()` that works similarly to |
12 | 4 | `expect_true(all(expected %in% object))` or |
13 | 5 | `expect_true(all(object %in% expected))` but give more informative failure |
14 | 6 | messages (#1346). |
15 | 7 |
|
16 | | -* Skips are now only shown at the end of reporter summaries, not as tests are |
17 | | - run. This makes them less intrusive in interactive tests while still allowing |
18 | | - you to verify that the correct tests are skipped (#1801). |
19 | | - |
20 | | -* `ProgressReporter` only reports the run time of test files that take longer |
21 | | - than 1s, rather than 0.1s. (#1806) and re-displays all failures at the end |
22 | | - of the results. |
23 | | - |
24 | 8 | * New `is_snapshot()` returns `TRUE` if code is running inside a snapshot test |
25 | 9 | (#1796) and `is_checking()` returns `TRUE` if test is running inside of |
26 | 10 | `R CMD check` (#1795) |
27 | 11 |
|
28 | | -* All packages, regardless of whether or not they use rlang, now |
29 | | - use the new snapshot display for errors, warnings, and messages. |
| 12 | +* `ProgressReporter` only reports the run time of test files that take longer |
| 13 | + than 1s, rather than 0.1s. (#1806) and re-displays all failures at the end |
| 14 | + of the results. Skips are now only shown at the end of reporter summaries, |
| 15 | + not as tests are run. This makes them less intrusive in interactive tests |
| 16 | + while still allowing you to verify that the correct tests are skipped (#1801). |
| 17 | + When using parallel tests, links to failed tests (#1787) and links to |
| 18 | + accept/review snapshot (#1802) now work. |
| 19 | + |
| 20 | +* `set_state_inspector()` allows to to register a function that's called |
| 21 | + before and after every test, reporting on any differences. This |
| 22 | + is very useful for detecting if any of your tests have made changes to |
| 23 | + global state (like options, env vars, or connections) (#1674). This |
| 24 | + function was inspired by renv's testing infrastructure. |
30 | 25 |
|
31 | 26 | * `skip_on_cran()` no longer skips (errors) when run interactively. |
32 | 27 |
|
33 | | -* `testthat::teardown_env()` works in more cases. |
| 28 | +* `teardown_env()` works in more cases. |
34 | 29 |
|
35 | | -* When using parallel tests, links to failed tests (#1787) and |
36 | | - running links for snapshot hints (#1802) now works. |
| 30 | +* All packages, regardless of whether or not they use rlang, now |
| 31 | + use the new snapshot display for errors, warnings, and messages. |
37 | 32 |
|
38 | 33 | * testthat no longer truncates tracebacks and uses rlang's default tree |
39 | 34 | display. |
|
0 commit comments