Passed
Push — feature/upgrade-to-phpunit-10 ( 94e9d2 )
by Sebastian
04:55
created
tests/unit/Console/Command/AddTest.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -62,7 +62,7 @@
 block discarded – undo
62 62
         $invokedCount = $this->atLeast(2);
63 63
         $io->expects($invokedCount)
64 64
            ->method('ask')
65
-           ->willReturnCallback(function ($parameters) use ($invokedCount) {
65
+           ->willReturnCallback(function($parameters) use ($invokedCount) {
66 66
                $results = ['\\Foo\\Bar', 'n'];
67 67
                return $results[$invokedCount->numberOfInvocations() - 1] ?? '';
68 68
            });
Please login to merge, or discard this patch.
tests/unit/Console/Command/UninstallTest.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -41,7 +41,7 @@
 block discarded – undo
41 41
 
42 42
     public function testUninstallPreCommitHook(): void
43 43
     {
44
-        $repo   = new DummyRepo([
44
+        $repo = new DummyRepo([
45 45
             'config' => '# fake git config',
46 46
             'hooks'  => [
47 47
                 'pre-commit' => '# fake pre-commit hook file',
Please login to merge, or discard this patch.
tests/unit/Console/IOUtilTest.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -48,7 +48,7 @@
 block discarded – undo
48 48
 
49 49
     public function testFormatHeadlineShort(): void
50 50
     {
51
-        $text     = str_repeat('x', 70) ;
51
+        $text     = str_repeat('x', 70);
52 52
         $expected = '==== ' . $text . ' ====';
53 53
         $headline = IOUtil::formatHeadline($text, 80);
54 54
 
Please login to merge, or discard this patch.
tests/unit/Runner/Config/EditorTest.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -126,7 +126,7 @@
 block discarded – undo
126 126
         $config->method('getHookConfig')->willReturn($this->createHookConfigMock());
127 127
         $io->expects($invocations)
128 128
            ->method('ask')
129
-           ->willReturnCallback(function ($parameters) use ($invocations) {
129
+           ->willReturnCallback(function($parameters) use ($invocations) {
130 130
                $results = ['y', 'y', '\\Foo\\Bar', 'y', 'foo:bar', 'n', 'n', 'n', 'n', 'n', 'n', 'n', 'n', 'n', 'n'];
131 131
                return $results[$invocations->numberOfInvocations() - 1] ?? '';
132 132
            });
Please login to merge, or discard this patch.
tests/unit/Runner/Config/Setup/ExpressTest.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -30,12 +30,12 @@
 block discarded – undo
30 30
         $config->expects($this->exactly(2))->method('getHookConfig')->willReturn($this->createHookConfigMock());
31 31
         $io->expects($invokedCount)
32 32
            ->method('ask')
33
-           ->willReturnCallback(function ($parameters) use ($invokedCount) {
33
+           ->willReturnCallback(function($parameters) use ($invokedCount) {
34 34
                $results = ['y', 'y', 'y', 'phpunit', 'y', 'phpcs'];
35 35
                return $results[$invokedCount->numberOfInvocations() - 1] ?? '';
36 36
            });
37 37
 
38
-        $setup  = new Express($io);
38
+        $setup = new Express($io);
39 39
         $setup->configureHooks($config);
40 40
     }
41 41
 }
Please login to merge, or discard this patch.
tests/unit/Runner/Config/Setup/AdvancedTest.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -30,12 +30,12 @@  discard block
 block discarded – undo
30 30
         $config->expects($this->exactly(9))->method('getHookConfig')->willReturn($this->createHookConfigMock());
31 31
         $io->expects($invocations)
32 32
            ->method('ask')
33
-           ->willReturnCallback(function ($parameters) use ($invocations) {
33
+           ->willReturnCallback(function($parameters) use ($invocations) {
34 34
                $results = ['y', 'y', 'echo \'foo\'', 'n', 'n', 'n', 'n', 'n', 'n', 'n', 'n', 'n', 'n'];
35 35
                return $results[$invocations->numberOfInvocations() - 1] ?? '';
36 36
            });
37 37
 
38
-        $setup  = new Advanced($io);
38
+        $setup = new Advanced($io);
39 39
         $setup->configureHooks($config);
40 40
     }
41 41
 
@@ -47,14 +47,14 @@  discard block
 block discarded – undo
47 47
         $config->method('getHookConfig')->willReturn($this->createHookConfigMock());
48 48
         $io->expects($invocations)
49 49
            ->method('ask')
50
-           ->willReturnCallback(function ($parameters) use ($invocations) {
50
+           ->willReturnCallback(function($parameters) use ($invocations) {
51 51
                $results = ['y', 'y', '\\Foo\\Bar', 'y', 'foo:bar', 'n', 'n', 'n', 'n', 'n', 'n', 'n', 'n', 'n', 'n'];
52 52
                return $results[$invocations->numberOfInvocations() - 1] ?? '';
53 53
            });
54 54
 
55 55
         $io->expects($this->once())->method('askAndValidate')->willReturn('foo:bar');
56 56
 
57
-        $setup  = new Advanced($io);
57
+        $setup = new Advanced($io);
58 58
         $setup->configureHooks($config);
59 59
     }
60 60
 }
Please login to merge, or discard this patch.
tests/unit/Runner/Config/CreatorTest.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -34,7 +34,7 @@  discard block
 block discarded – undo
34 34
         $io          = $this->createIOMock();
35 35
         $io->expects($invocations)
36 36
            ->method('ask')
37
-           ->willReturnCallback(function ($parameters) use ($invocations) {
37
+           ->willReturnCallback(function($parameters) use ($invocations) {
38 38
                $results = ['y', 'y', '\\Foo\\Bar', 'y', 'foo:bar', 'n', 'n', 'n', 'n', 'n', 'n', 'n', 'n', 'n', 'n'];
39 39
                return $results[$invocations->numberOfInvocations() - 1] ?? '';
40 40
            });
@@ -62,7 +62,7 @@  discard block
 block discarded – undo
62 62
         $io = $this->createIOMock();
63 63
         $io->expects($invocations)
64 64
            ->method('ask')
65
-           ->willReturnCallback(function ($parameters) use ($invocations) {
65
+           ->willReturnCallback(function($parameters) use ($invocations) {
66 66
                $results = ['y', 'y', '\\Foo\\Bar', 'y', 'foo:bar', 'n', 'n', 'n', 'n', 'n', 'n', 'n', 'n', 'n', 'n'];
67 67
                return $results[$invocations->numberOfInvocations() - 1] ?? '';
68 68
            });
Please login to merge, or discard this patch.
tests/unit/Plugin/Hook/PreserveWorkingTreeTest.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -201,7 +201,7 @@  discard block
 block discarded – undo
201 201
         $this->statusOperator
202 202
             ->expects($this->once())
203 203
             ->method('restoreWorkingTree')
204
-            ->willReturnCallback(function (): bool {
204
+            ->willReturnCallback(function(): bool {
205 205
                 if (getenv(PreserveWorkingTree::SKIP_POST_CHECKOUT_VAR) != '1') {
206 206
                     $this->fail(PreserveWorkingTree::SKIP_POST_CHECKOUT_VAR . ' did not have the correct value');
207 207
                 }
@@ -211,7 +211,7 @@  discard block
 block discarded – undo
211 211
         $this->diffOperator
212 212
             ->expects($this->once())
213 213
             ->method('applyPatches')
214
-            ->with($this->callback(function ($value) use ($patchFileConstraint): bool {
214
+            ->with($this->callback(function($value) use ($patchFileConstraint): bool {
215 215
                 $result = true;
216 216
                 foreach ($value as $item) {
217 217
                     $result = $result && $patchFileConstraint->evaluate($item, '', true);
@@ -266,7 +266,7 @@  discard block
 block discarded – undo
266 266
         $this->diffOperator
267 267
             ->expects($this->exactly(3))
268 268
             ->method('applyPatches')
269
-            ->with($this->callback(function ($value) use ($patchFileConstraint): bool {
269
+            ->with($this->callback(function($value) use ($patchFileConstraint): bool {
270 270
                 $result = true;
271 271
                 foreach ($value as $item) {
272 272
                     $result = $result && $patchFileConstraint->evaluate($item, '', true);
Please login to merge, or discard this patch.