Cleaning up.
Some checks failed
ci/woodpecker/push/woodpecker Pipeline failed

This commit is contained in:
2023-08-15 11:43:12 +00:00
parent 31891f3e53
commit 188a6ad9fa
6 changed files with 40 additions and 32 deletions

View File

@ -40,6 +40,20 @@ final class CommandBackupTest extends \PHPUnit\Framework\TestCase
$this->assertStringContainsString('[ERROR] Configuration error:File "bad_file" does not exist.', $output);
}
public function testNoCommand(): void
{
$applicationd = new Application('backup', "1.1.1");
$applicationd->add(new CommandBackup());
$command = $applicationd->find('backup');
$commandTester = new CommandTester($command);
$this->expectException(\Exception::class);
$commandTester->execute([]);
$this->fail('Exception was not thrown');
}
public function testGoodConfig(): void
{
$applicationd = new Application('backup', "1.1.1");