From: Martin Willi Date: Tue, 14 Oct 2014 09:55:36 +0000 (+0200) Subject: process: Don't use absolute path names for true/false/cat in unit tests X-Git-Tag: 5.2.1~18 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=b16ea3415f2f3f4f2fe48750e1db4a76946534c0;p=thirdparty%2Fstrongswan.git process: Don't use absolute path names for true/false/cat in unit tests But use the (builtin) shell commands instead, as on OS X true/false are under /usr/bin. --- diff --git a/src/libstrongswan/tests/suites/test_process.c b/src/libstrongswan/tests/suites/test_process.c index c22c47294e..f4013136ba 100644 --- a/src/libstrongswan/tests/suites/test_process.c +++ b/src/libstrongswan/tests/suites/test_process.c @@ -28,7 +28,9 @@ START_TEST(test_retval_true) "/C", "exit 0", #else - "/bin/true", + "/bin/sh", + "-c", + "true", #endif NULL }; @@ -50,7 +52,9 @@ START_TEST(test_retval_false) "/C", "exit 1", #else - "/bin/false", + "/bin/sh", + "-c", + "false", #endif NULL }; @@ -84,7 +88,9 @@ START_TEST(test_echo) #ifdef WIN32 "C:\\Windows\\system32\\more.com", #else - "/bin/cat", + "/bin/sh", + "-c", + "cat", #endif NULL }; @@ -117,7 +123,7 @@ START_TEST(test_echo_err) #else "/bin/sh", "-c", - "1>&2 /bin/cat", + "1>&2 cat", #endif NULL };