TestEvaluate [test]
runs a TestObject .
TestEvaluate [assoc]
runs a test specified by assoc.
TestEvaluate [{test1,test2,…}]
runs the list of tests testi.
TestEvaluate
TestEvaluate [test]
runs a TestObject .
TestEvaluate [assoc]
runs a test specified by assoc.
TestEvaluate [{test1,test2,…}]
runs the list of tests testi.
Details
- TestEvaluate returns a TestObject .
- In TestEvaluate [assoc], elements of assoc can include:
-
"Input" True test input"ExpectedOutput" True evaluated expected output"ExpectedMessages" {} messages passed to the test"SameTest" SameQ function to compare actual and expected output"TestID" None unique identifier for the test"MemoryConstraint" Infinity memory (in bytes) the test is allowed to use"TimeConstraint" Infinity
- time (in seconds) the test is allowed to use
"MetaInformation" <||> extra information associated with the test - TestEvaluate evaluates tests without issuing messages.
Examples
open all close allBasic Examples (1)
Create a test using TestCreate :
Run the test using TestEvaluate :
TestEvaluate will always run a TestObject , even if it is already evaluated:
Evaluate a test by specifying an Association :
Possible Issues (2)
TestEvaluate will always use a set of defaults if all keys are not specified:
An empty association will still be considered a valid test:
When using an Association , certain properties will be automatically wrapped with HoldForm :
See Also
Tech Notes
Related Guides
History
Text
Wolfram Research (2023), TestEvaluate, Wolfram Language function, https://reference.wolfram.com/language/ref/TestEvaluate.html.
CMS
Wolfram Language. 2023. "TestEvaluate." Wolfram Language & System Documentation Center. Wolfram Research. https://reference.wolfram.com/language/ref/TestEvaluate.html.
APA
Wolfram Language. (2023). TestEvaluate. Wolfram Language & System Documentation Center. Retrieved from https://reference.wolfram.com/language/ref/TestEvaluate.html
BibTeX
@misc{reference.wolfram_2025_testevaluate, author="Wolfram Research", title="{TestEvaluate}", year="2023", howpublished="\url{https://reference.wolfram.com/language/ref/TestEvaluate.html}", note=[Accessed: 18-November-2025]}
BibLaTeX
@online{reference.wolfram_2025_testevaluate, organization={Wolfram Research}, title={TestEvaluate}, year={2023}, url={https://reference.wolfram.com/language/ref/TestEvaluate.html}, note=[Accessed: 18-November-2025]}