unittest::fail_or_die - Execute a code block and exit with exit code 3 if it does not raise an error.
{ code } fail_or_die -> -
{ code } string fail_or_die -> -
/unittest (7391) require
/unittest using
{ 1 0 div } fail_or_die
{ 0 << /resolution 0 >> SetStatus} fail_or_die
endusing
This procedure is provided to test that certain errors are raised, e.g., when
illegal values are set.
This function will quit nest if the code does NOT raise an error
(exit code 3). It will print an error message to cerr, too.
SLI-2.0
H. E. Plesser
07/02/2008
/var/www/debian/nest/nest-simulator-2.20.0/lib/sli/unittest.sli