This library contains functions to perform unit testing. There are five basic functions, assertâtoScreen, assertâreturn, assertânilâtoScreen, assertânilâreturn and assertâerr. These functions will execute their right argument (the test) and compare its results to the left argument.
There are two functions for the environment, assertâsetup and assertâcleanup.
Execute a list of commands to setup for testing
Execute a list of commands to clean up after testing
Prints a message to the screen indicating whether the test succeeded or failed.
returns a Boolean value indicating whether the test succeeded or failed.
Function to test a function without a return value. Such a function must have some side effects as it has no actual effect. One must write a function to test for the side effects and return True or False. Supply the name of that function as a character string.
Like assertânilâtoScreen, returns true or false rather than cluttering up your screen.
A simple (minded) function to display a message
A Function to test that an error has occurred. Right now this is empty function. When I get a bright idea on how to do it I will.
A helper function to recursively evaluate nested test results. Navigates through the complexity of nested array to define what equals actually means.