Skip to content

Commit ca90656

Browse files
committed
Merge branch '2.1' into 2.2
* 2.1: [HttpFoundation] Fixed copy pasted comment from FlashBag in AttributeBag [FrameworkBundle] fixed the discovery of the PHPUnit configuration file when using aggregate options like in -vc app/ (closes #7562) [WebProfilerBundle] removed next pointer class in a template
2 parents e342172 + d56d01e commit ca90656

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

Test/WebTestCase.php

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -84,19 +84,19 @@ protected static function getPhpUnitXmlDir()
8484
}
8585

8686
/**
87-
* Finds the value of configuration flag from cli
87+
* Finds the value of the CLI configuration option.
8888
*
8989
* PHPUnit will use the last configuration argument on the command line, so this only returns
90-
* the last configuration argument
90+
* the last configuration argument.
9191
*
92-
* @return string The value of the phpunit cli configuration option
92+
* @return string The value of the PHPUnit cli configuration option
9393
*/
9494
private static function getPhpUnitCliConfigArgument()
9595
{
9696
$dir = null;
9797
$reversedArgs = array_reverse($_SERVER['argv']);
9898
foreach ($reversedArgs as $argIndex => $testArg) {
99-
if ($testArg === '-c' || $testArg === '--configuration') {
99+
if (preg_match('/^-[^ \-]*c$/', $testArg) || $testArg === '--configuration') {
100100
$dir = realpath($reversedArgs[$argIndex - 1]);
101101
break;
102102
} elseif (strpos($testArg, '--configuration=') === 0) {

0 commit comments

Comments
 (0)