From ef251be816dc17ce95bec3554faf0023ac64f188 Mon Sep 17 00:00:00 2001 From: brarcher Date: Sun, 22 Sep 2013 17:22:59 +0000 Subject: [PATCH] skip test_setup without fork This test is run 3 times, and each run attempts to change some global memory. If using fork, each test has the same global memory. However, without fork subsequent tests observe the changed global memory from previous tests. Disabling all but the first run if there is no fork(), and the test is invalid without fork. git-svn-id: svn+ssh://svn.code.sf.net/p/check/code/trunk@769 64e312b2-a51f-0410-8e61-82d0ca0eb02a --- tests/check_check_master.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/tests/check_check_master.c b/tests/check_check_master.c index d175b59..42d3137 100644 --- a/tests/check_check_master.c +++ b/tests/check_check_master.c @@ -419,8 +419,11 @@ Suite *make_master_suite (void) preservation of fixture values across tests, regardless of the order in which tests are added to the test case */ tcase_add_test (tc_fixture, test_setup); +#ifdef HAVE_FORK + /* The remaining test runs only work if fork() is available. */ tcase_add_test (tc_fixture, test_setup); tcase_add_test (tc_fixture, test_setup); +#endif /* HAVE_FORK */ suite_add_tcase (s, tc_fixture); tc_post_teardown = tcase_create ("Fixture Teardown Tests"); tcase_add_test (tc_post_teardown, test_teardown); -- 2.40.0