@@ -7,7 +7,7 @@ |
||
7 | 7 | public function method() |
8 | 8 | { |
9 | 9 | $o = new class { public function foo() {} }; |
10 | - $o = new class{public function foo(){}}; |
|
10 | + $o = new class{public function foo() {}}; |
|
11 | 11 | $o = new class extends stdClass {}; |
12 | 12 | $o = new class extends stdClass {}; |
13 | 13 | $o = new class implements foo {}; |
@@ -1,7 +1,7 @@ |
||
1 | 1 | <?php |
2 | 2 | $function1 = function($foo, $bar) use ($var) {}; |
3 | 3 | $function2 = function(Foo $foo, $bar) use ($var) {}; |
4 | -$function3 = function ($foo, $bar, $baz) {}; |
|
5 | -$function4 = function (Foo $foo, $bar, $baz) {}; |
|
6 | -$function5 = function () {}; |
|
4 | +$function3 = function($foo, $bar, $baz) {}; |
|
5 | +$function4 = function(Foo $foo, $bar, $baz) {}; |
|
6 | +$function5 = function() {}; |
|
7 | 7 | $function6 = function() {}; |
@@ -2,7 +2,7 @@ |
||
2 | 2 | /** |
3 | 3 | * Some comment |
4 | 4 | */ |
5 | -class Foo{function foo(){} |
|
5 | +class Foo {function foo() {} |
|
6 | 6 | |
7 | 7 | /** |
8 | 8 | * @param Baz $baz |
@@ -151,7 +151,7 @@ discard block |
||
151 | 151 | |
152 | 152 | if (is_array($type)) { |
153 | 153 | $type = array_unique(array_map( |
154 | - function ($type) { |
|
154 | + function($type) { |
|
155 | 155 | if ($type === 'Traversable' || |
156 | 156 | $type === '\\Traversable' || |
157 | 157 | $type === '\\Iterator') { |
@@ -555,7 +555,7 @@ discard block |
||
555 | 555 | $name = substr($method, $nameStart, $nameEnd - $nameStart); |
556 | 556 | |
557 | 557 | if (empty($methods) || in_array($name, $methods)) { |
558 | - $args = explode( |
|
558 | + $args = explode( |
|
559 | 559 | ',', |
560 | 560 | substr( |
561 | 561 | $method, |
@@ -386,8 +386,8 @@ discard block |
||
386 | 386 | array('\Traversable'), |
387 | 387 | array('TraversableMockTestInterface'), |
388 | 388 | array(array('Traversable')), |
389 | - array(array('Iterator','Traversable')), |
|
390 | - array(array('\Iterator','\Traversable')) |
|
389 | + array(array('Iterator', 'Traversable')), |
|
390 | + array(array('\Iterator', '\Traversable')) |
|
391 | 391 | ); |
392 | 392 | } |
393 | 393 | |
@@ -475,7 +475,7 @@ discard block |
||
475 | 475 | |
476 | 476 | $mock->expects($this->any()) |
477 | 477 | ->method('doSomethingElse') |
478 | - ->will($this->returnCallback(function () use (&$actualArguments) { |
|
478 | + ->will($this->returnCallback(function() use (&$actualArguments) { |
|
479 | 479 | $actualArguments = func_get_args(); |
480 | 480 | })); |
481 | 481 | |
@@ -499,7 +499,7 @@ discard block |
||
499 | 499 | |
500 | 500 | $mock->expects($this->any()) |
501 | 501 | ->method('doSomethingElse') |
502 | - ->will($this->returnCallback(function () use (&$actualArguments) { |
|
502 | + ->will($this->returnCallback(function() use (&$actualArguments) { |
|
503 | 503 | $actualArguments = func_get_args(); |
504 | 504 | })); |
505 | 505 | |
@@ -707,7 +707,7 @@ discard block |
||
707 | 707 | $foo->expects($this->any()) |
708 | 708 | ->method('bar') |
709 | 709 | ->will($this->returnCallback( |
710 | - function (&$a, &$b, $c) { |
|
710 | + function(&$a, &$b, $c) { |
|
711 | 711 | $b = 1; |
712 | 712 | } |
713 | 713 | )); |
@@ -652,11 +652,11 @@ |
||
652 | 652 | $iniSettings = ''; |
653 | 653 | } |
654 | 654 | |
655 | - $coverage = $result->getCollectCodeCoverageInformation() ? 'true' : 'false'; |
|
655 | + $coverage = $result->getCollectCodeCoverageInformation() ? 'true' : 'false'; |
|
656 | 656 | $isStrictAboutTestsThatDoNotTestAnything = $result->isStrictAboutTestsThatDoNotTestAnything() ? 'true' : 'false'; |
657 | - $isStrictAboutOutputDuringTests = $result->isStrictAboutOutputDuringTests() ? 'true' : 'false'; |
|
658 | - $isStrictAboutTestSize = $result->isStrictAboutTestSize() ? 'true' : 'false'; |
|
659 | - $isStrictAboutTodoAnnotatedTests = $result->isStrictAboutTodoAnnotatedTests() ? 'true' : 'false'; |
|
657 | + $isStrictAboutOutputDuringTests = $result->isStrictAboutOutputDuringTests() ? 'true' : 'false'; |
|
658 | + $isStrictAboutTestSize = $result->isStrictAboutTestSize() ? 'true' : 'false'; |
|
659 | + $isStrictAboutTodoAnnotatedTests = $result->isStrictAboutTodoAnnotatedTests() ? 'true' : 'false'; |
|
660 | 660 | |
661 | 661 | if (defined('PHPUNIT_COMPOSER_INSTALL')) { |
662 | 662 | $composerAutoload = var_export(PHPUNIT_COMPOSER_INSTALL, true); |
@@ -907,7 +907,7 @@ |
||
907 | 907 | // @test on TestCase::testMethod() |
908 | 908 | $doc_comment = $method->getDocComment(); |
909 | 909 | |
910 | - return strpos($doc_comment, '@test') !== false || |
|
910 | + return strpos($doc_comment, '@test') !== false || |
|
911 | 911 | strpos($doc_comment, '@scenario') !== false; |
912 | 912 | } |
913 | 913 |
@@ -30,7 +30,7 @@ |
||
30 | 30 | foreach ($suite->getGroupDetails() as $group => $tests) { |
31 | 31 | if (in_array($group, $groups)) { |
32 | 32 | $testHashes = array_map( |
33 | - function ($test) { |
|
33 | + function($test) { |
|
34 | 34 | return spl_object_hash($test); |
35 | 35 | }, |
36 | 36 | $tests |
@@ -601,11 +601,11 @@ |
||
601 | 601 | /* |
602 | 602 | * Issue #657 |
603 | 603 | */ |
604 | - if (isset($phpunit['stderr']) && ! isset($this->arguments['stderr'])) { |
|
604 | + if (isset($phpunit['stderr']) && !isset($this->arguments['stderr'])) { |
|
605 | 605 | $this->arguments['stderr'] = $phpunit['stderr']; |
606 | 606 | } |
607 | 607 | |
608 | - if (isset($phpunit['columns']) && ! isset($this->arguments['columns'])) { |
|
608 | + if (isset($phpunit['columns']) && !isset($this->arguments['columns'])) { |
|
609 | 609 | $this->arguments['columns'] = $phpunit['columns']; |
610 | 610 | } |
611 | 611 |