Passed
Pull Request — master (#253)
by Marco
04:04
created
src/DetectChanges/BCBreak/FunctionBased/ParameterDefaultValueChanged.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -66,7 +66,7 @@
 block discarded – undo
66 66
     {
67 67
         return array_filter(
68 68
             $function->getParameters(),
69
-            static function (ReflectionParameter $parameter) : bool {
69
+            static function(ReflectionParameter $parameter) : bool {
70 70
                 return $parameter->isDefaultValueAvailable();
71 71
             }
72 72
         );
Please login to merge, or discard this patch.
test/unit/Git/RevisionTest.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -27,7 +27,7 @@  discard block
 block discarded – undo
27 27
     {
28 28
         $sha1 = sha1(uniqid('sha1', true));
29 29
 
30
-        self::assertSame($sha1, (string) Revision::fromSha1($sha1 . "\n"));
30
+        self::assertSame($sha1, (string) Revision::fromSha1($sha1."\n"));
31 31
     }
32 32
 
33 33
     /**
@@ -40,8 +40,8 @@  discard block
 block discarded – undo
40 40
             ['a'],
41 41
             [str_repeat('a', 39)],
42 42
             [str_repeat('a', 41)],
43
-            [' ' . str_repeat('a', 42)],
44
-            [str_repeat('a', 42) . ' '],
43
+            [' '.str_repeat('a', 42)],
44
+            [str_repeat('a', 42).' '],
45 45
         ];
46 46
     }
47 47
 
Please login to merge, or discard this patch.
test/unit/SourceLocator/StaticClassMapSourceLocatorTest.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -77,7 +77,7 @@  discard block
 block discarded – undo
77 77
             ->astLocator
78 78
             ->expects(self::once())
79 79
             ->method('findReflection')
80
-            ->with($this->reflector, self::callback(static function (LocatedSource $source) : bool {
80
+            ->with($this->reflector, self::callback(static function(LocatedSource $source) : bool {
81 81
                 self::assertSame(file_get_contents(__FILE__), $source->getSource());
82 82
                 self::assertSame(__FILE__, $source->getFileName());
83 83
                 self::assertNull($source->getExtensionName());
@@ -97,7 +97,7 @@  discard block
 block discarded – undo
97 97
     {
98 98
         return [
99 99
             [__FILE__],
100
-            [__DIR__ . '/../SourceLocator/StaticClassMapSourceLocatorTest.php'],
100
+            [__DIR__.'/../SourceLocator/StaticClassMapSourceLocatorTest.php'],
101 101
         ];
102 102
     }
103 103
 
Please login to merge, or discard this patch.
test/unit/DetectChanges/BCBreak/ClassBased/ClassBecameInternalTest.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -31,7 +31,7 @@  discard block
 block discarded – undo
31 31
 
32 32
         self::assertSame(
33 33
             $expectedMessages,
34
-            array_map(static function (Change $change) : string {
34
+            array_map(static function(Change $change) : string {
35 35
                 return $change->__toString();
36 36
             }, iterator_to_array($changes))
37 37
         );
@@ -53,7 +53,7 @@  discard block
 block discarded – undo
53 53
             ,
54 54
             $locator
55 55
         ));
56
-        $toReflector   = new ClassReflector(new StringSourceLocator(
56
+        $toReflector = new ClassReflector(new StringSourceLocator(
57 57
             <<<'PHP'
58 58
 <?php
59 59
 
Please login to merge, or discard this patch.
unit/DetectChanges/BCBreak/FunctionBased/ExcludeInternalFunctionTest.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -19,7 +19,7 @@  discard block
 block discarded – undo
19 19
 {
20 20
     public function testNormalFunctionsAreNotExcluded() : void
21 21
     {
22
-        $source   = new StringSourceLocator(
22
+        $source = new StringSourceLocator(
23 23
             <<<'PHP'
24 24
 <?php
25 25
 
@@ -46,7 +46,7 @@  discard block
 block discarded – undo
46 46
 
47 47
     public function testInternalFunctionsAreExcluded() : void
48 48
     {
49
-        $source   = new StringSourceLocator(
49
+        $source = new StringSourceLocator(
50 50
             <<<'PHP'
51 51
 <?php
52 52
 
Please login to merge, or discard this patch.
src/CompareClasses.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -46,13 +46,13 @@
 block discarded – undo
46 46
         ClassReflector $newSourcesWithDependencies
47 47
     ) : Changes {
48 48
         $definedApiClassNames = array_map(
49
-            static function (ReflectionClass $class) : string {
49
+            static function(ReflectionClass $class) : string {
50 50
                 return $class->getName();
51 51
             },
52 52
             array_filter(
53 53
                 $definedSymbols->getAllClasses(),
54
-                function (ReflectionClass $class) : bool {
55
-                    return ! ($class->isAnonymous() || $this->isInternalDocComment($class->getDocComment()));
54
+                function(ReflectionClass $class) : bool {
55
+                    return !($class->isAnonymous() || $this->isInternalDocComment($class->getDocComment()));
56 56
                 }
57 57
             )
58 58
         );
Please login to merge, or discard this patch.
src/DetectChanges/BCBreak/ClassBased/MethodRemoved.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -36,7 +36,7 @@  discard block
 block discarded – undo
36 36
             array_change_key_case($this->accessibleMethods($toClass), CASE_UPPER)
37 37
         );
38 38
 
39
-        return Changes::fromList(...array_values(array_map(function (ReflectionMethod $method) : Change {
39
+        return Changes::fromList(...array_values(array_map(function(ReflectionMethod $method) : Change {
40 40
             return Change::removed(
41 41
                 sprintf('Method %s was removed', $this->formatFunction->__invoke($method)),
42 42
                 true
@@ -47,14 +47,14 @@  discard block
 block discarded – undo
47 47
     /** @return ReflectionMethod[] */
48 48
     private function accessibleMethods(ReflectionClass $class) : array
49 49
     {
50
-        $methods = array_filter($class->getMethods(), function (ReflectionMethod $method) : bool {
50
+        $methods = array_filter($class->getMethods(), function(ReflectionMethod $method) : bool {
51 51
             return ($method->isPublic()
52 52
                 || $method->isProtected())
53
-                && ! $this->isInternalDocComment($method->getDocComment());
53
+                && !$this->isInternalDocComment($method->getDocComment());
54 54
         });
55 55
 
56 56
         return array_combine(
57
-            array_map(static function (ReflectionMethod $method) : string {
57
+            array_map(static function(ReflectionMethod $method) : string {
58 58
                 return $method->getName();
59 59
             }, $methods),
60 60
             $methods
Please login to merge, or discard this patch.
src/DetectChanges/BCBreak/ClassBased/ClassBecameInternal.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -17,7 +17,7 @@
 block discarded – undo
17 17
 {
18 18
     public function __invoke(ReflectionClass $fromClass, ReflectionClass $toClass) : Changes
19 19
     {
20
-        if (! $this->isInternalDocComment($fromClass->getDocComment())
20
+        if (!$this->isInternalDocComment($fromClass->getDocComment())
21 21
             && $this->isInternalDocComment($toClass->getDocComment())
22 22
         ) {
23 23
             return Changes::fromList(Change::changed(
Please login to merge, or discard this patch.
src/DetectChanges/BCBreak/InterfaceBased/InterfaceBecameClass.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -17,7 +17,7 @@  discard block
 block discarded – undo
17 17
 {
18 18
     public function __invoke(ReflectionClass $fromInterface, ReflectionClass $toInterface) : Changes
19 19
     {
20
-        if (! $this->isClass($toInterface) || ! $fromInterface->isInterface()) {
20
+        if (!$this->isClass($toInterface) || !$fromInterface->isInterface()) {
21 21
             // checking whether a class became an interface is done in `ClassBecameInterface`
22 22
             return Changes::empty();
23 23
         }
@@ -33,6 +33,6 @@  discard block
 block discarded – undo
33 33
      */
34 34
     private function isClass(ReflectionClass $class) : bool
35 35
     {
36
-        return ! ($class->isTrait() || $class->isInterface());
36
+        return !($class->isTrait() || $class->isInterface());
37 37
     }
38 38
 }
Please login to merge, or discard this patch.