To enable testing of signal handling, there is a function tcase_add_test_raise_signal()
which is used instead of tcase_add_test()
. This function takes an additional signal argument, specifying a signal that the test expects to receive. If no signal is received this is logged as a failure. If a different signal is received this is logged as an error.
The signal handling functionality only works in CK_FORK mode.