Browse Source

Using escapeshellarg instead of putting backshlashes in front of spaces

Signed-off-by: Luca Degasperi <dega.luca@gmail.com>
Luca Degasperi 12 years ago
parent
commit
79a5dc1931
1 changed files with 2 additions and 1 deletions
  1. 2 1
      laravel/cli/tasks/test/runner.php

+ 2 - 1
laravel/cli/tasks/test/runner.php

@@ -82,7 +82,8 @@ class Runner extends Task {
 		$path = path('base').'phpunit.xml';
 		
 		// fix the spaced directories problem when using the command line
-		$path = str_replace(" ", "\\ ", $path);
+		// strings with spaces inside should be wrapped in quotes.
+		$path = escapeshellarg($path)
 
 		passthru('phpunit --configuration '.$path);