Passed
Pull Request — master (#49)
by Marco
02:55
created
src/Git/GitCheckoutRevisionToTemporaryPath.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -16,7 +16,7 @@
 block discarded – undo
16 16
      */
17 17
     public function checkout(CheckedOutRepository $sourceRepository, Revision $revision) : CheckedOutRepository
18 18
     {
19
-        $checkoutDirectory = sys_get_temp_dir() . '/api-compare-' . (string) $revision;
19
+        $checkoutDirectory = sys_get_temp_dir().'/api-compare-'.(string) $revision;
20 20
 
21 21
         (new Process(['git', 'clone', (string) $sourceRepository, $checkoutDirectory]))->mustRun();
22 22
         (new Process(['git', 'checkout', (string) $revision]))->setWorkingDirectory($checkoutDirectory)->mustRun();
Please login to merge, or discard this patch.
src/Git/GetVersionCollectionFromGitRepository.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -31,7 +31,7 @@
 block discarded – undo
31 31
         // @todo handle invalid versions more gracefully (drop them)
32 32
         return VersionsCollection::fromArray(array_filter(
33 33
             explode("\n", $output),
34
-            function (string $maybeVersion) {
34
+            function(string $maybeVersion) {
35 35
                 return trim($maybeVersion) !== '';
36 36
             }
37 37
         ));
Please login to merge, or discard this patch.
src/Git/CheckedOutRepository.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -18,7 +18,7 @@
 block discarded – undo
18 18
     public static function fromPath(string $path) : self
19 19
     {
20 20
         Assert::that($path)->directory();
21
-        Assert::that($path . '/.git')->directory();
21
+        Assert::that($path.'/.git')->directory();
22 22
         $instance       = new self();
23 23
         $instance->path = $path;
24 24
         return $instance;
Please login to merge, or discard this patch.
src/LocateDependencies/LocateDependenciesViaComposer.php 2 patches
Indentation   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -76,9 +76,9 @@  discard block
 block discarded – undo
76 76
         $classMap = $classMapProperty->getDefaultValue();
77 77
 
78 78
         Assert::that($classMap)
79
-              ->isArray()
80
-              ->all()
81
-              ->file();
79
+                ->isArray()
80
+                ->all()
81
+                ->file();
82 82
 
83 83
         return new StaticClassMapSourceLocator($classMap, $this->astLocator);
84 84
     }
@@ -92,9 +92,9 @@  discard block
 block discarded – undo
92 92
         $filesMap = $filesMapProperty->getDefaultValue();
93 93
 
94 94
         Assert::that($filesMap)
95
-              ->isArray()
96
-              ->all()
97
-              ->file();
95
+                ->isArray()
96
+                ->all()
97
+                ->file();
98 98
 
99 99
         return new AggregateSourceLocator(array_values(array_map(
100 100
             function (string $path) : SourceLocator {
Please login to merge, or discard this patch.
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -43,9 +43,9 @@  discard block
 block discarded – undo
43 43
     public function __invoke(string $installationPath) : SourceLocator
44 44
     {
45 45
         Assert::that($installationPath)->directory();
46
-        Assert::that($installationPath . '/composer.json')->file();
46
+        Assert::that($installationPath.'/composer.json')->file();
47 47
 
48
-        $this->runInDirectory(function () use ($installationPath) : void {
48
+        $this->runInDirectory(function() use ($installationPath) : void {
49 49
             $installer = ($this->makeComposerInstaller)($installationPath);
50 50
 
51 51
             Assert::that($installer)->isInstanceOf(Installer::class);
@@ -62,7 +62,7 @@  discard block
 block discarded – undo
62 62
             $installer->run();
63 63
         }, $installationPath);
64 64
 
65
-        $autoloadStatic = $installationPath . '/vendor/composer/autoload_static.php';
65
+        $autoloadStatic = $installationPath.'/vendor/composer/autoload_static.php';
66 66
 
67 67
         Assert::that($autoloadStatic)->file();
68 68
 
@@ -104,7 +104,7 @@  discard block
 block discarded – undo
104 104
     {
105 105
         $filesMapProperty = $autoloadStatic->getProperty('files');
106 106
 
107
-        if (! $filesMapProperty) {
107
+        if (!$filesMapProperty) {
108 108
             return new AggregateSourceLocator();
109 109
         }
110 110
 
@@ -119,7 +119,7 @@  discard block
 block discarded – undo
119 119
               ->file();
120 120
 
121 121
         return new AggregateSourceLocator(array_values(array_map(
122
-            function (string $path) : SourceLocator {
122
+            function(string $path) : SourceLocator {
123 123
                 return new SingleFileSourceLocator(
124 124
                     realpath($path),
125 125
                     $this->astLocator
Please login to merge, or discard this patch.
src/Comparator/BackwardsCompatibility/ClassBased/ConstantRemoved.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -21,7 +21,7 @@  discard block
 block discarded – undo
21 21
             $this->accessibleConstants($toClass)
22 22
         );
23 23
 
24
-        return Changes::fromArray(array_values(array_map(function (ReflectionClassConstant $constant) use ($fromClass) : Change {
24
+        return Changes::fromArray(array_values(array_map(function(ReflectionClassConstant $constant) use ($fromClass) : Change {
25 25
             return Change::removed(
26 26
                 sprintf('Constant %s::%s was removed', $fromClass->getName(), $constant->getName()),
27 27
                 true
@@ -32,7 +32,7 @@  discard block
 block discarded – undo
32 32
     /** @return ReflectionClassConstant[] */
33 33
     private function accessibleConstants(ReflectionClass $class) : array
34 34
     {
35
-        return array_filter($class->getReflectionConstants(), function (ReflectionClassConstant $constant) : bool {
35
+        return array_filter($class->getReflectionConstants(), function(ReflectionClassConstant $constant) : bool {
36 36
             return $constant->isPublic() || $constant->isProtected();
37 37
         });
38 38
     }
Please login to merge, or discard this patch.
src/SourceLocator/StaticClassMapSourceLocator.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -34,7 +34,7 @@
 block discarded – undo
34 34
      */
35 35
     protected function createLocatedSource(Identifier $identifier) : ?LocatedSource
36 36
     {
37
-        if (! $identifier->isClass()) {
37
+        if (!$identifier->isClass()) {
38 38
             return null;
39 39
         }
40 40
 
Please login to merge, or discard this patch.
test/unit/ChangeTest.php 1 patch
Spacing   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -17,7 +17,7 @@  discard block
 block discarded – undo
17 17
     {
18 18
         $changeText = uniqid('changeText', true);
19 19
         $change     = Change::added($changeText, false);
20
-        self::assertSame('     ADDED: ' . $changeText, (string) $change);
20
+        self::assertSame('     ADDED: '.$changeText, (string) $change);
21 21
         self::assertTrue($change->isAdded());
22 22
         self::assertFalse($change->isChanged());
23 23
         self::assertFalse($change->isRemoved());
@@ -27,7 +27,7 @@  discard block
 block discarded – undo
27 27
     {
28 28
         $changeText = uniqid('changeText', true);
29 29
         $change     = Change::added($changeText, true);
30
-        self::assertSame('[BC] ADDED: ' . $changeText, (string) $change);
30
+        self::assertSame('[BC] ADDED: '.$changeText, (string) $change);
31 31
         self::assertTrue($change->isAdded());
32 32
         self::assertFalse($change->isChanged());
33 33
         self::assertFalse($change->isRemoved());
@@ -37,7 +37,7 @@  discard block
 block discarded – undo
37 37
     {
38 38
         $changeText = uniqid('changeText', true);
39 39
         $change     = Change::changed($changeText, false);
40
-        self::assertSame('     CHANGED: ' . $changeText, (string) $change);
40
+        self::assertSame('     CHANGED: '.$changeText, (string) $change);
41 41
         self::assertFalse($change->isAdded());
42 42
         self::assertTrue($change->isChanged());
43 43
         self::assertFalse($change->isRemoved());
@@ -47,7 +47,7 @@  discard block
 block discarded – undo
47 47
     {
48 48
         $changeText = uniqid('changeText', true);
49 49
         $change     = Change::changed($changeText, true);
50
-        self::assertSame('[BC] CHANGED: ' . $changeText, (string) $change);
50
+        self::assertSame('[BC] CHANGED: '.$changeText, (string) $change);
51 51
         self::assertFalse($change->isAdded());
52 52
         self::assertTrue($change->isChanged());
53 53
         self::assertFalse($change->isRemoved());
@@ -57,7 +57,7 @@  discard block
 block discarded – undo
57 57
     {
58 58
         $changeText = uniqid('changeText', true);
59 59
         $change     = Change::removed($changeText, false);
60
-        self::assertSame('     REMOVED: ' . $changeText, (string) $change);
60
+        self::assertSame('     REMOVED: '.$changeText, (string) $change);
61 61
         self::assertFalse($change->isAdded());
62 62
         self::assertFalse($change->isChanged());
63 63
         self::assertTrue($change->isRemoved());
@@ -67,7 +67,7 @@  discard block
 block discarded – undo
67 67
     {
68 68
         $changeText = uniqid('changeText', true);
69 69
         $change     = Change::removed($changeText, true);
70
-        self::assertSame('[BC] REMOVED: ' . $changeText, (string) $change);
70
+        self::assertSame('[BC] REMOVED: '.$changeText, (string) $change);
71 71
         self::assertFalse($change->isAdded());
72 72
         self::assertFalse($change->isChanged());
73 73
         self::assertTrue($change->isRemoved());
Please login to merge, or discard this patch.
test/unit/Comparator/Variance/TypeIsCovariantTest.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -235,7 +235,7 @@  discard block
 block discarded – undo
235 235
         return array_merge(
236 236
             [[null]],
237 237
             array_merge(...array_map(
238
-                function (string $type) use ($reflector) : array {
238
+                function(string $type) use ($reflector) : array {
239 239
                     return [
240 240
                         [ReflectionType::createFromTypeAndReflector($type, false, $reflector)],
241 241
                         [ReflectionType::createFromTypeAndReflector($type, true, $reflector)],
@@ -259,7 +259,7 @@  discard block
 block discarded – undo
259 259
     /** @dataProvider existingNullableTypeStrings */
260 260
     public function testCovarianceConsidersNullability(string $type) : void
261 261
     {
262
-        $reflector   = new ClassReflector(new StringSourceLocator(
262
+        $reflector = new ClassReflector(new StringSourceLocator(
263 263
             <<<'PHP'
264 264
 <?php
265 265
 
Please login to merge, or discard this patch.
test/unit/Comparator/Variance/TypeIsContravariantTest.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -224,7 +224,7 @@  discard block
 block discarded – undo
224 224
         return array_merge(
225 225
             [[null]],
226 226
             array_merge(...array_map(
227
-                function (string $type) use ($reflector) : array {
227
+                function(string $type) use ($reflector) : array {
228 228
                     return [
229 229
                         [ReflectionType::createFromTypeAndReflector($type, false, $reflector)],
230 230
                         [ReflectionType::createFromTypeAndReflector($type, true, $reflector)],
@@ -248,7 +248,7 @@  discard block
 block discarded – undo
248 248
     /** @dataProvider existingNullableTypeStrings */
249 249
     public function testContravarianceConsidersNullability(string $type) : void
250 250
     {
251
-        $reflector   = new ClassReflector(new StringSourceLocator(
251
+        $reflector = new ClassReflector(new StringSourceLocator(
252 252
             <<<'PHP'
253 253
 <?php
254 254
 
Please login to merge, or discard this patch.