From c2c3cf9c69a641da3860309ca384103fff5f5a1c Mon Sep 17 00:00:00 2001 From: "John Paul E. Balandan, CPA" Date: Sat, 11 Apr 2026 22:10:51 +0800 Subject: [PATCH] test: refactor tests on `BaseCommand` and `Commands` --- system/CLI/Commands.php | 25 +-- tests/_support/Commands/AppInfo.php | 25 ++- tests/_support/Commands/ParamsReveal.php | 30 --- tests/_support/_command/ListCommands.php | 16 +- tests/system/CLI/BaseCommandTest.php | 104 ++++++++++ tests/system/CLI/CommandsTest.php | 176 ++++++++++++++++ tests/system/Commands/BaseCommandTest.php | 62 ------ tests/system/Commands/CommandOverrideTest.php | 64 ------ tests/system/Commands/CommandTest.php | 192 ------------------ tests/system/Commands/ListCommandsTest.php | 55 +++++ utils/phpstan-baseline/loader.neon | 2 +- .../missingType.iterableValue.neon | 7 +- 12 files changed, 369 insertions(+), 389 deletions(-) delete mode 100644 tests/_support/Commands/ParamsReveal.php create mode 100644 tests/system/CLI/BaseCommandTest.php create mode 100644 tests/system/CLI/CommandsTest.php delete mode 100644 tests/system/Commands/BaseCommandTest.php delete mode 100644 tests/system/Commands/CommandOverrideTest.php delete mode 100644 tests/system/Commands/CommandTest.php create mode 100644 tests/system/Commands/ListCommandsTest.php diff --git a/system/CLI/Commands.php b/system/CLI/Commands.php index 5630ee0f7b69..8f623d509c0a 100644 --- a/system/CLI/Commands.php +++ b/system/CLI/Commands.php @@ -64,8 +64,6 @@ public function run(string $command, array $params) return EXIT_ERROR; } - // The file would have already been loaded during the - // createCommandList function... $className = $this->commands[$command]['class']; $class = new $className($this->logger, $this); @@ -104,14 +102,10 @@ public function discoverCommands() $locator = service('locator'); $files = $locator->listFiles('Commands/'); - // If no matching command files were found, bail - // This should never happen in unit testing. if ($files === []) { - return; // @codeCoverageIgnore + return; } - // Loop over each file checking to see if a command with that - // alias exists in the class. foreach ($files as $file) { /** @var class-string|false */ $className = $locator->findQualifiedNameFromPath($file); @@ -159,21 +153,20 @@ public function verifyCommand(string $command, array $commands): bool return true; } - $message = lang('CLI.commandNotFound', [$command]); + $message = lang('CLI.commandNotFound', [$command]); + $alternatives = $this->getCommandAlternatives($command, $commands); if ($alternatives !== []) { - if (count($alternatives) === 1) { - $message .= "\n\n" . lang('CLI.altCommandSingular') . "\n "; - } else { - $message .= "\n\n" . lang('CLI.altCommandPlural') . "\n "; - } - - $message .= implode("\n ", $alternatives); + $message = sprintf( + "%s\n\n%s\n %s", + $message, + count($alternatives) === 1 ? lang('CLI.altCommandSingular') : lang('CLI.altCommandPlural'), + implode("\n ", $alternatives), + ); } CLI::error($message); - CLI::newLine(); return false; } diff --git a/tests/_support/Commands/AppInfo.php b/tests/_support/Commands/AppInfo.php index 767523071466..94502e0706f5 100644 --- a/tests/_support/Commands/AppInfo.php +++ b/tests/_support/Commands/AppInfo.php @@ -18,29 +18,40 @@ use CodeIgniter\CodeIgniter; use CodeIgniter\Exceptions\RuntimeException; -class AppInfo extends BaseCommand +/** + * @internal + */ +final class AppInfo extends BaseCommand { protected $group = 'demo'; protected $name = 'app:info'; protected $arguments = ['draft' => 'unused']; protected $description = 'Displays basic application information.'; - public function run(array $params): void + public function run(array $params): int { - CLI::write('CI Version: ' . CLI::color(CodeIgniter::CI_VERSION, 'red')); + CLI::write(sprintf('CodeIgniter Version: %s', CodeIgniter::CI_VERSION)); + + return 0; } - public function bomb(): void + public function bomb(): int { try { CLI::color('test', 'white', 'Background'); - } catch (RuntimeException $oops) { - $this->showError($oops); + } catch (RuntimeException $e) { + $this->showError($e); + + return 1; } + + return 0; } - public function helpme(): void + public function helpMe(): int { $this->call('help'); + + return 0; } } diff --git a/tests/_support/Commands/ParamsReveal.php b/tests/_support/Commands/ParamsReveal.php deleted file mode 100644 index 2feb04de29aa..000000000000 --- a/tests/_support/Commands/ParamsReveal.php +++ /dev/null @@ -1,30 +0,0 @@ - - * - * For the full copyright and license information, please view - * the LICENSE file that was distributed with this source code. - */ - -namespace Tests\Support\Commands; - -use CodeIgniter\CLI\BaseCommand; - -class ParamsReveal extends BaseCommand -{ - protected $group = 'demo'; - protected $name = 'reveal'; - protected $usage = 'reveal [options] [arguments]'; - protected $description = 'Reveal params'; - public static $args; - - public function run(array $params): void - { - static::$args = $params; - } -} diff --git a/tests/_support/_command/ListCommands.php b/tests/_support/_command/ListCommands.php index fe1c9611a222..5b73548d89de 100644 --- a/tests/_support/_command/ListCommands.php +++ b/tests/_support/_command/ListCommands.php @@ -13,36 +13,30 @@ namespace App\Commands; +use CodeIgniter\CLI\BaseCommand; use CodeIgniter\CLI\CLI; -use CodeIgniter\Commands\ListCommands as BaseListCommands; -class ListCommands extends BaseListCommands +/** + * @internal + */ +final class ListCommands extends BaseCommand { /** - * The group the command is lumped under - * when listing commands. - * * @var string */ protected $group = 'App'; /** - * The Command's name - * * @var string */ protected $name = 'list'; /** - * the Command's short description - * * @var string */ protected $description = 'This is testing to override `list` command.'; /** - * the Command's usage - * * @var string */ protected $usage = 'list'; diff --git a/tests/system/CLI/BaseCommandTest.php b/tests/system/CLI/BaseCommandTest.php new file mode 100644 index 000000000000..143851dee9ce --- /dev/null +++ b/tests/system/CLI/BaseCommandTest.php @@ -0,0 +1,104 @@ + + * + * For the full copyright and license information, please view + * the LICENSE file that was distributed with this source code. + */ + +namespace CodeIgniter\CLI; + +use CodeIgniter\CLI\Exceptions\CLIException; +use CodeIgniter\CodeIgniter; +use CodeIgniter\Log\Logger; +use CodeIgniter\Test\CIUnitTestCase; +use CodeIgniter\Test\StreamFilterTrait; +use PHPUnit\Framework\Attributes\After; +use PHPUnit\Framework\Attributes\Before; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\Group; +use Tests\Support\Commands\AppInfo; + +/** + * @internal + */ +#[CoversClass(BaseCommand::class)] +#[CoversClass(CLIException::class)] +#[Group('Others')] +final class BaseCommandTest extends CIUnitTestCase +{ + use StreamFilterTrait; + + #[After] + #[Before] + protected function resetCli(): void + { + CLI::reset(); + } + + public function testRunCommand(): void + { + $command = new AppInfo(single_service('logger'), single_service('commands')); + + $this->assertSame(0, $command->run([])); + $this->assertSame( + sprintf("\nCodeIgniter Version: %s\n", CodeIgniter::CI_VERSION), + preg_replace('/\e\[[^m]+m/', '', $this->getStreamFilterBuffer()), + ); + } + + public function testCallingOtherCommands(): void + { + $command = new AppInfo(single_service('logger'), single_service('commands')); + + $this->assertSame(0, $command->helpMe()); + $this->assertStringContainsString('Displays basic usage information.', $this->getStreamFilterBuffer()); + } + + public function testShowError(): void + { + $command = new AppInfo(single_service('logger'), single_service('commands')); + + $this->assertSame(1, $command->bomb()); + $this->assertStringContainsString('[CodeIgniter\CLI\Exceptions\CLIException]', $this->getStreamFilterBuffer()); + $this->assertStringContainsString('Invalid "background" color: "Background".', $this->getStreamFilterBuffer()); + } + + public function testShowHelp(): void + { + $command = new AppInfo(single_service('logger'), single_service('commands')); + $command->showHelp(); + + $this->assertSame( + <<<'EOT' + + Usage: + app:info [arguments] + + Description: + Displays basic application information. + + Arguments: + draft unused + + EOT, + preg_replace('/\e\[[^m]+m/', '', $this->getStreamFilterBuffer()), + ); + } + + public function testMagicGetAndIsset(): void + { + $command = new AppInfo(single_service('logger'), single_service('commands')); + + $this->assertInstanceOf(Logger::class, $command->logger); + $this->assertInstanceOf(Commands::class, $command->commands); + $this->assertSame('demo', $command->group); + $this->assertSame('app:info', $command->name); + $this->assertNull($command->foo); // @phpstan-ignore property.notFound + } +} diff --git a/tests/system/CLI/CommandsTest.php b/tests/system/CLI/CommandsTest.php new file mode 100644 index 000000000000..f6a9dc1c0ff5 --- /dev/null +++ b/tests/system/CLI/CommandsTest.php @@ -0,0 +1,176 @@ + + * + * For the full copyright and license information, please view + * the LICENSE file that was distributed with this source code. + */ + +namespace CodeIgniter\CLI; + +use CodeIgniter\Autoloader\FileLocatorInterface; +use CodeIgniter\Test\CIUnitTestCase; +use CodeIgniter\Test\StreamFilterTrait; +use Config\Services; +use PHPUnit\Framework\Attributes\After; +use PHPUnit\Framework\Attributes\Before; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\Group; +use RuntimeException; +use Tests\Support\Commands\AppInfo; + +/** + * @internal + */ +#[CoversClass(Commands::class)] +#[Group('Others')] +final class CommandsTest extends CIUnitTestCase +{ + use StreamFilterTrait; + + #[After] + #[Before] + protected function resetAll(): void + { + $this->resetServices(); + + CLI::reset(); + } + + private function copyAppListCommands(): void + { + if (! is_dir(APPPATH . 'Commands')) { + mkdir(APPPATH . 'Commands'); + } + + copy(SUPPORTPATH . '_command/ListCommands.php', APPPATH . 'Commands/ListCommands.php'); + } + + private function deleteAppListCommands(): void + { + if (is_file(APPPATH . 'Commands/ListCommands.php')) { + unlink(APPPATH . 'Commands/ListCommands.php'); + } + } + + public function testRunOnUnknownCommand(): void + { + $commands = new Commands(); + + $this->assertSame(EXIT_ERROR, $commands->run('app:unknown', [])); + $this->assertArrayNotHasKey('app:unknown', $commands->getCommands()); + $this->assertStringContainsString('Command "app:unknown" not found', $this->getStreamFilterBuffer()); + } + + public function testRunOnUnknownCommandButWithOneAlternative(): void + { + $commands = new Commands(); + + $this->assertSame(EXIT_ERROR, $commands->run('app:inf', [])); + $this->assertSame( + <<<'EOT' + Command "app:inf" not found. + + Did you mean this? + app:info + + EOT, + preg_replace('/\e\[[^m]+m/', '', $this->getStreamFilterBuffer()), + ); + } + + public function testRunOnUnknownCommandButWithMultipleAlternatives(): void + { + $commands = new Commands(); + + $this->assertSame(EXIT_ERROR, $commands->run('app:', [])); + $this->assertSame( + <<<'EOT' + Command "app:" not found. + + Did you mean one of these? + app:destructive + app:info + + EOT, + preg_replace('/\e\[[^m]+m/', '', $this->getStreamFilterBuffer()), + ); + } + + public function testRunOnAbstractCommandCannotBeRun(): void + { + $commands = new Commands(); + + $this->assertSame(EXIT_ERROR, $commands->run('app:pablo', [])); + $this->assertArrayNotHasKey('app:pablo', $commands->getCommands()); + $this->assertStringContainsString('Command "app:pablo" not found', $this->getStreamFilterBuffer()); + } + + public function testRunOnKnownCommand(): void + { + $commands = new Commands(); + + $this->assertSame(EXIT_SUCCESS, $commands->run('app:info', [])); + $this->assertArrayHasKey('app:info', $commands->getCommands()); + $this->assertStringContainsString('CodeIgniter Version', $this->getStreamFilterBuffer()); + } + + public function testDestructiveCommandIsNotRisky(): void + { + $this->expectException(RuntimeException::class); + + command('app:destructive'); + } + + public function testDiscoverCommandsDoNotRunTwice(): void + { + $locator = $this->createMock(FileLocatorInterface::class); + $locator + ->expects($this->once()) + ->method('listFiles') + ->with('Commands/') + ->willReturn([SUPPORTPATH . 'Commands/AppInfo.php']); + $locator + ->expects($this->once()) + ->method('findQualifiedNameFromPath') + ->with(SUPPORTPATH . 'Commands/AppInfo.php') + ->willReturn(AppInfo::class); + Services::injectMock('locator', $locator); + + $commands = new Commands(); // discoverCommands will be called in the constructor + $commands->discoverCommands(); + } + + public function testDiscoverCommandsWithNoFiles(): void + { + $locator = $this->createMock(FileLocatorInterface::class); + $locator + ->expects($this->once()) + ->method('listFiles') + ->with('Commands/') + ->willReturn([]); + $locator + ->expects($this->never()) + ->method('findQualifiedNameFromPath'); + Services::injectMock('locator', $locator); + + new Commands(); + } + + public function testDiscoveredCommandsCanBeOverridden(): void + { + $this->copyAppListCommands(); + + command('list'); + + $this->assertStringContainsString('This is App\Commands\ListCommands', $this->getStreamFilterBuffer()); + $this->assertStringNotContainsString('Displays basic usage information.', $this->getStreamFilterBuffer()); + + $this->deleteAppListCommands(); + } +} diff --git a/tests/system/Commands/BaseCommandTest.php b/tests/system/Commands/BaseCommandTest.php deleted file mode 100644 index 47ca2a6f6a1b..000000000000 --- a/tests/system/Commands/BaseCommandTest.php +++ /dev/null @@ -1,62 +0,0 @@ - - * - * For the full copyright and license information, please view - * the LICENSE file that was distributed with this source code. - */ - -namespace CodeIgniter\Commands; - -use CodeIgniter\Log\Logger; -use CodeIgniter\Test\CIUnitTestCase; -use PHPUnit\Framework\Attributes\Group; -use Tests\Support\Commands\AppInfo; - -/** - * @internal - */ -#[Group('Others')] -final class BaseCommandTest extends CIUnitTestCase -{ - private Logger $logger; - - protected function setUp(): void - { - parent::setUp(); - $this->logger = service('logger'); - } - - public function testMagicIssetTrue(): void - { - $command = new AppInfo($this->logger, service('commands')); - - $this->assertSame($command->group !== null, isset($command->group)); // @phpstan-ignore isset.property - } - - public function testMagicIssetFalse(): void - { - $command = new AppInfo($this->logger, service('commands')); - - $this->assertFalse(isset($command->foobar)); // @phpstan-ignore property.notFound - } - - public function testMagicGet(): void - { - $command = new AppInfo($this->logger, service('commands')); - - $this->assertSame('demo', $command->group); - } - - public function testMagicGetMissing(): void - { - $command = new AppInfo($this->logger, service('commands')); - - $this->assertNull($command->foobar); // @phpstan-ignore property.notFound - } -} diff --git a/tests/system/Commands/CommandOverrideTest.php b/tests/system/Commands/CommandOverrideTest.php deleted file mode 100644 index b21b7e0c6faa..000000000000 --- a/tests/system/Commands/CommandOverrideTest.php +++ /dev/null @@ -1,64 +0,0 @@ - - * - * For the full copyright and license information, please view - * the LICENSE file that was distributed with this source code. - */ - -namespace CodeIgniter\Commands; - -use CodeIgniter\Test\CIUnitTestCase; -use CodeIgniter\Test\StreamFilterTrait; -use PHPUnit\Framework\Attributes\Group; - -/** - * @internal - */ -#[Group('Others')] -final class CommandOverrideTest extends CIUnitTestCase -{ - use StreamFilterTrait; - - protected function setUp(): void - { - $this->resetServices(); - - parent::setUp(); - } - - protected function getBuffer(): string - { - return $this->getStreamFilterBuffer(); - } - - public function testOverrideListCommands(): void - { - $this->copyListCommands(); - - command('list'); - - $this->assertStringContainsString('This is App\Commands\ListCommands', $this->getBuffer()); - $this->assertStringNotContainsString('Displays basic usage information.', $this->getBuffer()); - - $this->deleteListCommands(); - } - - private function copyListCommands(): void - { - if (! is_dir(APPPATH . 'Commands')) { - mkdir(APPPATH . 'Commands'); - } - copy(SUPPORTPATH . '_command/ListCommands.php', APPPATH . 'Commands/ListCommands.php'); - } - - private function deleteListCommands(): void - { - unlink(APPPATH . 'Commands/ListCommands.php'); - } -} diff --git a/tests/system/Commands/CommandTest.php b/tests/system/Commands/CommandTest.php deleted file mode 100644 index 6b668d2640c5..000000000000 --- a/tests/system/Commands/CommandTest.php +++ /dev/null @@ -1,192 +0,0 @@ - - * - * For the full copyright and license information, please view - * the LICENSE file that was distributed with this source code. - */ - -namespace CodeIgniter\Commands; - -use CodeIgniter\CLI\Commands; -use CodeIgniter\Log\Logger; -use CodeIgniter\Test\CIUnitTestCase; -use CodeIgniter\Test\StreamFilterTrait; -use PHPUnit\Framework\Attributes\DataProvider; -use PHPUnit\Framework\Attributes\Group; -use RuntimeException; -use Tests\Support\Commands\AppInfo; -use Tests\Support\Commands\ParamsReveal; - -/** - * @internal - */ -#[Group('Others')] -final class CommandTest extends CIUnitTestCase -{ - use StreamFilterTrait; - - private Logger $logger; - private Commands $commands; - - protected function setUp(): void - { - $this->resetServices(); - - parent::setUp(); - - $this->logger = service('logger'); - $this->commands = service('commands'); - } - - protected function getBuffer(): string - { - return $this->getStreamFilterBuffer(); - } - - public function testListCommands(): void - { - command('list'); - - // make sure the result looks like a command list - $this->assertStringContainsString('Lists the available commands.', $this->getBuffer()); - $this->assertStringContainsString('Displays basic usage information.', $this->getBuffer()); - } - - public function testListCommandsSimple(): void - { - command('list --simple'); - - $this->assertStringContainsString('db:seed', $this->getBuffer()); - $this->assertStringNotContainsString('Lists the available commands.', $this->getBuffer()); - } - - public function testCustomCommand(): void - { - command('app:info'); - $this->assertStringContainsString('CI Version:', $this->getBuffer()); - } - - public function testShowError(): void - { - command('app:info'); - $commands = $this->commands->getCommands(); - - /** @var AppInfo */ - $command = new $commands['app:info']['class']($this->logger, $this->commands); - - $command->helpme(); - - $this->assertStringContainsString('Displays basic usage information.', $this->getBuffer()); - } - - public function testCommandCall(): void - { - command('app:info'); - $commands = $this->commands->getCommands(); - - /** @var AppInfo */ - $command = new $commands['app:info']['class']($this->logger, $this->commands); - - $command->bomb(); - - $this->assertStringContainsString('Invalid "background" color:', $this->getBuffer()); - } - - public function testAbstractCommand(): void - { - command('app:pablo'); - $this->assertStringContainsString('not found', $this->getBuffer()); - } - - public function testNamespacesCommand(): void - { - command('namespaces'); - - $this->assertStringContainsString('| Namespace', $this->getBuffer()); - $this->assertStringContainsString('| Config', $this->getBuffer()); - $this->assertStringContainsString('| Yes', $this->getBuffer()); - } - - public function testInexistentCommandWithNoAlternatives(): void - { - command('app:oops'); - $this->assertStringContainsString('Command "app:oops" not found', $this->getBuffer()); - } - - public function testInexistentCommandsButWithOneAlternative(): void - { - command('namespace'); - - $this->assertStringContainsString('Command "namespace" not found.', $this->getBuffer()); - $this->assertStringContainsString('Did you mean this?', $this->getBuffer()); - $this->assertStringContainsString('namespaces', $this->getBuffer()); - } - - public function testInexistentCommandsButWithManyAlternatives(): void - { - command('clear'); - - $this->assertStringContainsString('Command "clear" not found.', $this->getBuffer()); - $this->assertStringContainsString('Did you mean one of these?', $this->getBuffer()); - $this->assertStringContainsString(':clear', $this->getBuffer()); - } - - public function testDestructiveCommandIsNotRisky(): void - { - $this->expectException(RuntimeException::class); - - command('app:destructive'); - } - - /** - * @param list $expected - */ - #[DataProvider('provideCommandParsesArgsCorrectly')] - public function testCommandParsesArgsCorrectly(string $input, array $expected): void - { - ParamsReveal::$args = null; - command($input); - - $this->assertSame($expected, ParamsReveal::$args); - } - - public static function provideCommandParsesArgsCorrectly(): iterable - { - return [ - [ - 'reveal as df', - ['as', 'df'], - ], - [ - 'reveal', - [], - ], - [ - 'reveal seg1 seg2 -opt1 -opt2', - ['seg1', 'seg2', 'opt1' => null, 'opt2' => null], - ], - [ - 'reveal seg1 seg2 -opt1 val1 seg3', - ['seg1', 'seg2', 'opt1' => 'val1', 'seg3'], - ], - [ - 'reveal as df -gh -jk -qw 12 zx cv', - ['as', 'df', 'gh' => null, 'jk' => null, 'qw' => '12', 'zx', 'cv'], - ], - [ - 'reveal as -df "some stuff" -jk 12 -sd "Some longer stuff" -fg \'using single quotes\'', - ['as', 'df' => 'some stuff', 'jk' => '12', 'sd' => 'Some longer stuff', 'fg' => 'using single quotes'], - ], - [ - 'reveal as -df "using mixed \'quotes\'\" here\""', - ['as', 'df' => 'using mixed \'quotes\'" here"'], - ], - ]; - } -} diff --git a/tests/system/Commands/ListCommandsTest.php b/tests/system/Commands/ListCommandsTest.php new file mode 100644 index 000000000000..9d86b1e0dd39 --- /dev/null +++ b/tests/system/Commands/ListCommandsTest.php @@ -0,0 +1,55 @@ + + * + * For the full copyright and license information, please view + * the LICENSE file that was distributed with this source code. + */ + +namespace CodeIgniter\Commands; + +use CodeIgniter\CLI\CLI; +use CodeIgniter\Test\CIUnitTestCase; +use CodeIgniter\Test\StreamFilterTrait; +use PHPUnit\Framework\Attributes\After; +use PHPUnit\Framework\Attributes\Before; +use PHPUnit\Framework\Attributes\CoversClass; +use PHPUnit\Framework\Attributes\Group; + +/** + * @internal + */ +#[CoversClass(ListCommands::class)] +#[Group('Others')] +final class ListCommandsTest extends CIUnitTestCase +{ + use StreamFilterTrait; + + #[After] + #[Before] + protected function resetCli(): void + { + CLI::reset(); + } + + public function testRunCommand(): void + { + command('list'); + + $this->assertStringContainsString('cache:clear', $this->getStreamFilterBuffer()); + $this->assertStringContainsString('Clears the current system caches.', $this->getStreamFilterBuffer()); + } + + public function testRunCommandWithSimpleOption(): void + { + command('list --simple'); + + $this->assertStringContainsString('cache:clear', $this->getStreamFilterBuffer()); + $this->assertStringNotContainsString('Clears the current system caches.', $this->getStreamFilterBuffer()); + } +} diff --git a/utils/phpstan-baseline/loader.neon b/utils/phpstan-baseline/loader.neon index 65e70e528efd..bcdfa61b4264 100644 --- a/utils/phpstan-baseline/loader.neon +++ b/utils/phpstan-baseline/loader.neon @@ -1,4 +1,4 @@ -# total 2060 errors +# total 2059 errors includes: - argument.type.neon diff --git a/utils/phpstan-baseline/missingType.iterableValue.neon b/utils/phpstan-baseline/missingType.iterableValue.neon index 94f900209bdd..fb692f3ac52f 100644 --- a/utils/phpstan-baseline/missingType.iterableValue.neon +++ b/utils/phpstan-baseline/missingType.iterableValue.neon @@ -1,4 +1,4 @@ -# total 1259 errors +# total 1258 errors parameters: ignoreErrors: @@ -4827,11 +4827,6 @@ parameters: count: 1 path: ../../tests/system/CodeIgniterTest.php - - - message: '#^Method CodeIgniter\\Commands\\CommandTest\:\:provideCommandParsesArgsCorrectly\(\) return type has no value type specified in iterable type iterable\.$#' - count: 1 - path: ../../tests/system/Commands/CommandTest.php - - message: '#^Method CodeIgniter\\Commands\\Translation\\LocalizationFinderTest\:\:getActualTranslationFourKeys\(\) return type has no value type specified in iterable type array\.$#' count: 1