Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[5.6] Keep same string format and avoid potential test failure (#23056)
* Keep same style and avoid potential test failure `ProcessUtils::escapeArgument` will return a string wrapped by single quote `'string'`, but `artisan` is not wrapped. This PR make them in a same style. Previous code could lead some potential test issue when running the test specifically in phpstorm targeting on one function `testMakeProcessCorrectlyFormatsCommandLine` in `tests/Queue/QueuePoolTest.php`. Attached output dump ``` /usr/local/Cellar/php71/7.1.8_20/bin/php /Users/project/path/framework/vendor/bin/phpunit --configuration /Users/project/path/framework/phpunit.xml.dist --filter "/::testMakeProcessCorrectlyFormatsCommandLine( .*)?$/" Illuminate\Tests\Queue\QueueListenerTest /Users/project/path/framework/tests/Queue/QueueListenerTest.php --teamcity PHPUnit 6.5.5 by Sebastian Bergmann and contributors. Runtime: PHP 7.1.8 with Xdebug 2.5.5 Configuration: /Users/project/path/framework/phpunit.xml.dist Failed asserting that two strings are equal. Expected :''/usr/local/Cellar/php71/7.1.8_20/bin/php' 'artisan' queue:work 'connection' --once --queue='queue' --delay=1 --memory=2 --sleep=3 --tries=0' Actual :''/usr/local/Cellar/php71/7.1.8_20/bin/php' artisan queue:work 'connection' --once --queue='queue' --delay=1 --memory=2 --sleep=3 --tries=0' <Click to see difference> /Users/project/path/framework/tests/Queue/QueueListenerTest.php:49 Time: 211 ms, Memory: 6.00MB ``` * Update to use utility to avoid different OS issue
- Loading branch information