mirror of
https://github.com/usetrmnl/byos_laravel.git
synced 2026-01-13 23:18:10 +00:00
This commit is contained in:
parent
4f251bf37e
commit
42b515e322
21 changed files with 2212 additions and 32 deletions
29
tests/Feature/Console/FirmwareCheckCommandTest.php
Normal file
29
tests/Feature/Console/FirmwareCheckCommandTest.php
Normal file
|
|
@ -0,0 +1,29 @@
|
|||
<?php
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
use Illuminate\Foundation\Testing\RefreshDatabase;
|
||||
|
||||
uses(RefreshDatabase::class);
|
||||
|
||||
test('firmware check command has correct signature', function () {
|
||||
$command = $this->app->make(App\Console\Commands\FirmwareCheckCommand::class);
|
||||
|
||||
expect($command->getName())->toBe('trmnl:firmware:check');
|
||||
expect($command->getDescription())->toBe('Checks for the latest firmware and downloads it if flag --download is passed.');
|
||||
});
|
||||
|
||||
test('firmware check command runs without errors', function () {
|
||||
$this->artisan('trmnl:firmware:check')
|
||||
->assertExitCode(0);
|
||||
});
|
||||
|
||||
test('firmware check command runs with download flag', function () {
|
||||
$this->artisan('trmnl:firmware:check', ['--download' => true])
|
||||
->assertExitCode(0);
|
||||
});
|
||||
|
||||
test('firmware check command can run successfully', function () {
|
||||
$this->artisan('trmnl:firmware:check')
|
||||
->assertExitCode(0);
|
||||
});
|
||||
Loading…
Add table
Add a link
Reference in a new issue