forked from r-lib/testthat
-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathNEWS
51 lines (36 loc) · 2.06 KB
/
NEWS
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
Changes in version 0.3 -----------------------------------------------------------------
* all expectations now have a shortcut form, so instead of
expect_that(a, is_identical_to(b))
you can do
expect_identical(a, b)
* new shows_message and gives_warning expectations to test warnings and
messages
* expect_that, equals, is_identical_to and is_equivalent to now have
additional label argument which allows you to control the appearance of the
text used for the expected object (for expect_that) and actual object (for
all other functions) in failure messages. This is useful when you have loops
that run tests as otherwise all the variable names are identical, and it's
difficult to tell which iteration caused the failure.
* executing bare tests gives nicer output
* all expectations now give more information on failure to make it easier to
track down the problem.
* test_file and test_dir now run in code in separate environment to avoid
pollution of global environment. They also temporary change the working
directory so tests can use relative paths.
* test_package makes it easier to run all tests in an installed package. Code
run in this manner has access to non-exported functions and objects. If any
errors or failures occur, test_package will throw an error, making it
suitable for use with R CMD check.
Changes in version 0.2 -----------------------------------------------------------------
* colourise also works in screen terminal
* equals expectation provides more information about failure
* expect_that has extra info argument to allow you to pass in any extra
information you'd like included in the message - this is very helpful if
you're using a loop to run tests
* is_equivalent_to: new expectation that tests for equality ignoring
attributes
* library_if_available now works! (thanks to report and fix from Felix
Andrews)
* specify larger width and join pieces back together whenever deparse used
(thanks to report and fix from Felix Andrews)
* test_dir now looks for any files starting with test (not test- as before)