From: Fletcher T. Penney Date: Tue, 21 Nov 2017 22:13:00 +0000 (-0500) Subject: FIXED: All test build on path with spaces X-Git-Tag: 6.3.0^2~22 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=7fb654d25af0a9b631e03ea50553ddf190e0fa28;p=multimarkdown FIXED: All test build on path with spaces --- diff --git a/test/make-tests.sh b/test/make-tests.sh index 90aa014..87e2f20 100644 --- a/test/make-tests.sh +++ b/test/make-tests.sh @@ -7,8 +7,9 @@ # Date: 01/08/2003 # # Modified by Fletcher T. Penney for proper error codes +# Modified by Fletcher T. Penney to handle spaces in path names -if test $# -eq 0 ; then FILES=*.c ; else FILES=$* ; fi +if test $# -eq 0 ; then FILES=("*.c") ; else FILES=("$@") ; fi echo ' @@ -20,7 +21,7 @@ echo ' ' -cat $FILES | grep '^void Test' | +cat "${FILES[@]}" | grep '^void Test' | sed -e 's/(.*$//' \ -e 's/$/(CuTest*);/' \ -e 's/^/extern /' @@ -35,7 +36,7 @@ void RunAllTests(void) int failCount = 0; ' -cat $FILES | grep '^void Test' | +cat "${FILES[@]}" | grep '^void Test' | sed -e 's/^void //' \ -e 's/(.*$//' \ -e 's/^/ SUITE_ADD_TEST(suite, /' \