• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

tempestphp / tempest-framework / 14161923512

30 Mar 2025 01:41PM UTC coverage: 80.964% (+0.2%) from 80.716%
14161923512

push

github

web-flow
ci: prevent coveralls failures from failing tests (#1104)

11058 of 13658 relevant lines covered (80.96%)

100.68 hits per line

Source File
Press 'n' to go to next uncovered line, 'b' for previous

15.38
/src/Tempest/Console/src/Exceptions/InvalidCommandException.php
1
<?php
2

3
declare(strict_types=1);
4

5
namespace Tempest\Console\Exceptions;
6

7
use Tempest\Console\Actions\RenderConsoleCommand;
8
use Tempest\Console\Console;
9
use Tempest\Console\ConsoleCommand;
10
use Tempest\Console\Input\ConsoleArgumentDefinition;
11

12
final class InvalidCommandException extends ConsoleException
13
{
14
    public function __construct(
4✔
15
        public readonly ConsoleCommand $consoleCommand,
16

17
        /** @var \Tempest\Console\Input\ConsoleArgumentDefinition[] $invalidArguments */
18
        public readonly array $invalidArguments,
19
    ) {}
4✔
20

21
    public function render(Console $console): void
×
22
    {
23
        $missingArguments = implode(', ', array_map(
×
24
            fn (ConsoleArgumentDefinition $argumentDefinition) => $argumentDefinition->name,
×
25
            $this->invalidArguments,
×
26
        ));
×
27

28
        if ($missingArguments) {
×
29
            $console->writeln();
×
30
            $console->error("Missing arguments: {$missingArguments}");
×
31
        } else {
32
            $console->writeln();
×
33
            $console->error('Invalid command usage.');
×
34
        }
35

36
        $console->info('Run again with --help for more information.');
×
37
    }
38
}
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2025 Coveralls, Inc