Skip to content

Commit f17cf9e

Browse files
committed
CommandHelper::begin() parameters made required
1 parent 4b6ac9c commit f17cf9e

File tree

6 files changed

+12
-2
lines changed

6 files changed

+12
-2
lines changed

src/Command/AnalyseCommand.php

+1
Original file line numberDiff line numberDiff line change
@@ -171,6 +171,7 @@ protected function execute(InputInterface $input, OutputInterface $output): int
171171
$level,
172172
$allowXdebug,
173173
$debugEnabled,
174+
true,
174175
);
175176
} catch (InceptionNotSuccessfulException $e) {
176177
return 1;

src/Command/ClearResultCacheCommand.php

+1
Original file line numberDiff line numberDiff line change
@@ -81,6 +81,7 @@ protected function execute(InputInterface $input, OutputInterface $output): int
8181
'0',
8282
$allowXdebug,
8383
$debugEnabled,
84+
true,
8485
);
8586
} catch (InceptionNotSuccessfulException) {
8687
return 1;

src/Command/CommandHelper.php

+2-2
Original file line numberDiff line numberDiff line change
@@ -89,8 +89,8 @@ public static function begin(
8989
?string $generateBaselineFile,
9090
?string $level,
9191
bool $allowXdebug,
92-
bool $debugEnabled = false,
93-
bool $cleanupContainerCache = true,
92+
bool $debugEnabled,
93+
bool $cleanupContainerCache,
9494
): InceptionResult
9595
{
9696
$stdOutput = new SymfonyOutput($output, new SymfonyStyle(new ErrorsConsoleStyle($input, $output)));

src/Command/DiagnoseCommand.php

+2
Original file line numberDiff line numberDiff line change
@@ -79,6 +79,8 @@ protected function execute(InputInterface $input, OutputInterface $output): int
7979
null,
8080
$level,
8181
false,
82+
false,
83+
false,
8284
);
8385
} catch (InceptionNotSuccessfulException) {
8486
return 1;

src/Command/DumpParametersCommand.php

+2
Original file line numberDiff line numberDiff line change
@@ -81,6 +81,8 @@ protected function execute(InputInterface $input, OutputInterface $output): int
8181
null,
8282
$level,
8383
false,
84+
false,
85+
false,
8486
);
8587
} catch (InceptionNotSuccessfulException) {
8688
return 1;

tests/PHPStan/Command/CommandHelperTest.php

+4
Original file line numberDiff line numberDiff line change
@@ -124,6 +124,8 @@ public function testBegin(
124124
null,
125125
$level,
126126
false,
127+
false,
128+
false,
127129
);
128130
if ($expectException) {
129131
$this->fail();
@@ -307,6 +309,8 @@ public function testResolveParameters(
307309
null,
308310
'0',
309311
false,
312+
false,
313+
false,
310314
);
311315
$parameters = $result->getContainer()->getParameters();
312316
foreach ($expectedParameters as $name => $expectedValue) {

0 commit comments

Comments
 (0)