TestReport
TestReport["file"]
runs tests from a file, returning an analysis of the completed test run.
TestReport[{test1,test2,…}]
gives a report of the results of the tests testi.
TestReport[{report1,report2,…}]
gives a unified report by merging all test reports reporti.
Details and Options

- TestReport returns a TestReportObject.
- TestReport handles both plain text Wolfram Language files and notebooks that use the Testing Notebook framework.
- CreateNotebook["Testing"] opens a blank notebook set up to use the Testing Notebook framework.
- TestReport has the following options, which are applied to each VerificationTest it runs:
-
MemoryConstraint Infinity memory (in bytes) each test is allowed to use SameTest SameQ function to compare actual and expected outputs TimeConstraint Infinity time (in seconds) each test is allowed to use - TestReport[File["file"]] is also supported.
- TestReport sets $TestFileName to the name of the file from which a test is being run.
Examples
open allclose allBasic Examples (2)
Run a list of VerificationTest:
Extract information on tests that failed and present in a TabView:
Merge the existing TestReportObject with a new one:
Scope (1)
Basic Uses (1)
Properties of the TestReportObject:
Association of individual test results:
Compare the expected and actual outputs of tests where those differed:
Expected and actual messages where a message failure occurred:
Options (6)
MemoryConstraint (2)
Apply memory constraint to all given VerificationTest:
The individual options for the VerificationTest override the option set at the TestReport level:
SameTest (2)
Apply SameTest to all given VerificationTest:
The individual options for the VerificationTest override the option set at the TestReport level:
TimeConstraint (2)
Apply time constraint to all given VerificationTest:
The individual options for the VerificationTest override the option set at the TestReport level:
Applications (1)
Run a list of VerificationTest and test files at the same time:
Use TestReport again to merge an existing TestReportObject into a new one:
When merging multiple TestReportObject instances using TestReport, duplicated tests will be automatically deleted from the report:
You can now use GroupBy to group together tests that have been run in the same file:
Possible Issues (1)
TestReport is automatically deleting duplicated tests:
Text
Wolfram Research (2014), TestReport, Wolfram Language function, https://reference.wolfram.com/language/ref/TestReport.html (updated 2019).
CMS
Wolfram Language. 2014. "TestReport." Wolfram Language & System Documentation Center. Wolfram Research. Last Modified 2019. https://reference.wolfram.com/language/ref/TestReport.html.
APA
Wolfram Language. (2014). TestReport. Wolfram Language & System Documentation Center. Retrieved from https://reference.wolfram.com/language/ref/TestReport.html