diff --git a/tests/PhpSyntaxTest.php b/tests/PhpSyntaxTest.php index 8128799aa..b21a59cf4 100644 --- a/tests/PhpSyntaxTest.php +++ b/tests/PhpSyntaxTest.php @@ -33,7 +33,11 @@ class PhpSyntaxTest extends SapphireTest { function getAllFiles($ext = 'php') { // TODO: Unix only - $CLI_regexp = escapeshellarg("\.$ext\$"); - return explode("\n", trim(`find .. | grep $CLI_regexp`)); + $cmd = sprintf( + 'find %s | grep %s', + BASE_PATH, + escapeshellarg("\.$ext\$") + ); + return explode("\n", trim(`$cmd`)); } } \ No newline at end of file