Checked fixtures run once for each unit test in a test case, and so they should not be used for expensive setup. On the other hand, since unchecked fixtures may take down the entire test program, they should only be used if they are known to be safe. Recall that unchecked fixtures run once per test case, as opposed to once per unit test.
Additionally, checked and unchecked fixtures may behave differently in
CK_NOFORK mode:
CK_FORK mode, unit tests may abuse the objects
created in an unchecked fixture with impunity, without affecting other
unit tests in the same test case, because the fork creates a separate
address space.
CK_NOFORK mode, all tests live in the same address
space, and side effects in one test will affect the unchecked fixture
for the other tests.
A checked fixture will generally not be affected by unit test side
effects, since the setup() is run before each unit test. There
is an exception for side effects to the total environment in which the
test program lives: for example, if the setup() function
initializes a file that a unit test then changes, the combination of
the teardown() function and setup fuction must be able
to restore the environment for the next unit test.
If the setup function in a fixture fails, in either checked or
unchecked fixtures, the unit tests for the test case, and the teardown
function for the fixture will not be run. A fixture error will be
created and reported to the SRunner.