|
1 | 1 | # testthat (development version) |
2 | 2 |
|
3 | | - |
4 | 3 | * `local_mock()` and `with_mock()` have been deprecated because they are no longer permitted in R 4.5. |
5 | 4 |
|
6 | | -* `with_mock()` and `local_mock()` have been unconditionally deprecated as they will no longer work in future versions of R (#1999). |
7 | | -* `expect_condition()` and friends now include the `class` of the expected condition in the failure mesage, if used (#1987). |
8 | | -* `LANGUAGE` is now set to `"C"` in reprocucible environments (i.e. |
9 | | - `test_that()` blocks) to disable translations. This fixes warnings |
10 | | - about being unable to set the language to `"en"` (#1925). |
| 5 | +* Fixed an issue where `expect_no_error(1)` was failing (#2037). |
| 6 | + |
| 7 | +* Fixed an issue where calling `skip()` outside of an active test could |
| 8 | + cause an unexpected error (@kevinushey, #2039). |
| 9 | + |
| 10 | +# testthat 3.2.2 |
| 11 | + |
| 12 | +## New expectations |
| 13 | + |
| 14 | +* `expect_s7_class()` tests if an object is an S7 class (#1580). |
| 15 | + |
| 16 | +* `expect_no_failure()`, `expect_no_success()` and `expect_snapshot_failure()` |
| 17 | + provide more options for testing expectations. |
| 18 | + |
| 19 | +## Bug fixes and minor improvements |
| 20 | + |
| 21 | +* testthat now requires waldo 0.6.0 or later to access the latest features |
| 22 | + (#1955). |
| 23 | + |
| 24 | +* `expect_condition()` and related functions now include the `class` of the |
| 25 | + expected condition in the failure message, if provided (#1987). |
| 26 | + |
| 27 | +* `expect_error()` and friends now error if you supply `...` but not `pattern` |
| 28 | + (#1932). They no longer give an uninformative error if they fail inside |
| 29 | + a magrittr pipe (#1994). |
| 30 | + |
| 31 | +* `expect_no_*()` expectations no longer incorrectly emit a passing test result |
| 32 | + if they in fact fail (#1997). |
| 33 | + |
| 34 | +* `expect_setequal()` correctly identifies what is missing where (#1962). |
| 35 | + |
| 36 | +* `expect_snapshot()` now strips line breaks in test descriptions |
| 37 | + (@LDSamson, #1900), and errors when called from a `test_that()` that has an |
| 38 | + empty description (@kevinushey, #1980). |
| 39 | + |
| 40 | +* `expect_true()` and `expect_false()` give better errors if `actual` isn't a |
| 41 | + vector (#1996). |
| 42 | + |
| 43 | +* `expect_visible()` and `expect_invisible()` have clearer failure messages |
| 44 | + (#1966). |
| 45 | +* `local_reproducible_output()` (used in `test_that()` blocks) now sets |
| 46 | + `LANGUAGE` to `"C"` instead of `"en"` to disable translations, |
| 47 | + avoiding warnings on some platforms (#1925). |
| 48 | + |
| 49 | +* `skip_if_not_installed()` generates a clearer message that sorts better |
| 50 | + (@MichaelChirico, #1959). |
| 51 | + |
| 52 | +* `with_mock()` and `local_mock()` have been unconditionally deprecated as |
| 53 | + they will no longer work in future versions of R (#1999). |
11 | 54 |
|
12 | 55 | # testthat 3.2.1 |
13 | 56 |
|
|
0 commit comments