chore: fixes tests

This commit is contained in:
Nuno Maduro
2024-06-11 23:11:38 +01:00
parent 85d91d5652
commit c07513c6a0
4 changed files with 10 additions and 9 deletions

View File

@ -23,7 +23,7 @@
"nunomaduro/termwind": "^2.0.1", "nunomaduro/termwind": "^2.0.1",
"pestphp/pest-plugin": "^3.0.0", "pestphp/pest-plugin": "^3.0.0",
"pestphp/pest-plugin-arch": "^3.0.0", "pestphp/pest-plugin-arch": "^3.0.0",
"phpunit/phpunit": "^11.2.0" "phpunit/phpunit": "^11.2.1"
}, },
"conflict": { "conflict": {
"sebastian/exporter": "<6.0.0", "sebastian/exporter": "<6.0.0",

View File

@ -30,19 +30,19 @@ final class Laravel extends AbstractPreset
$this->expectations[] = expect('App\Http\Requests') $this->expectations[] = expect('App\Http\Requests')
->toHaveSuffix('Request') ->toHaveSuffix('Request')
->toExtend('Illuminate\Foundation\Http\FormRequest') ->toExtend('Illuminate\Foundation\Http\FormRequest') // @phpstan-ignore-line
->toHaveMethod('rules'); ->toHaveMethod('rules');
$this->expectations[] = expect('App\Console\Commands') $this->expectations[] = expect('App\Console\Commands')
->toHaveSuffix('Command') ->toHaveSuffix('Command')
->toExtend('Illuminate\Console\Command') ->toExtend('Illuminate\Console\Command') // @phpstan-ignore-line
->toHaveMethod('handle'); ->toHaveMethod('handle');
$this->expectations[] = expect('App\Exceptions') $this->expectations[] = expect('App\Exceptions')
->toImplement('Throwable'); ->toImplement('Throwable');
$this->expectations[] = expect('App\Mail') $this->expectations[] = expect('App\Mail')
->toExtend('Illuminate\Mail\Mailable'); ->toExtend('Illuminate\Mail\Mailable'); // @phpstan-ignore-line
$this->expectations[] = expect('App\Jobs') $this->expectations[] = expect('App\Jobs')
->toHaveMethod('handle'); ->toHaveMethod('handle');
@ -51,11 +51,11 @@ final class Laravel extends AbstractPreset
->toHaveMethod('handle'); ->toHaveMethod('handle');
$this->expectations[] = expect('App\Notifications') $this->expectations[] = expect('App\Notifications')
->toExtend('Illuminate\Notifications\Notification'); ->toExtend('Illuminate\Notifications\Notification'); // @phpstan-ignore-line
$this->expectations[] = expect('App\Providers') $this->expectations[] = expect('App\Providers') // @phpstan-ignore-line
->toHaveSuffix('ServiceProvider') ->toHaveSuffix('ServiceProvider')
->toExtend('Illuminate\Support\ServiceProvider') ->toExtend('Illuminate\Support\ServiceProvider') // @phpstan-ignore-line
->not->toBeUsed(); ->not->toBeUsed();
} }
} }

View File

@ -2,6 +2,7 @@
PASS Tests\Arch PASS Tests\Arch
✓ arch "base" preset ✓ arch "base" preset
✓ arch "strict" preset ✓ arch "strict" preset
✓ arch "security" preset
✓ globals ✓ globals
✓ dependencies ✓ dependencies
✓ contracts ✓ contracts
@ -1469,4 +1470,4 @@
WARN Tests\Visual\Version WARN Tests\Visual\Version
- visual snapshot of help command output - visual snapshot of help command output
Tests: 2 deprecated, 4 warnings, 5 incomplete, 2 notices, 13 todos, 24 skipped, 1046 passed (2573 assertions) Tests: 2 deprecated, 4 warnings, 5 incomplete, 2 notices, 13 todos, 24 skipped, 1049 passed (2577 assertions)

View File

@ -16,7 +16,7 @@ $run = function () {
test('parallel', function () use ($run) { test('parallel', function () use ($run) {
expect($run('--exclude-group=integration')) expect($run('--exclude-group=integration'))
->toContain('Tests: 2 deprecated, 4 warnings, 5 incomplete, 2 notices, 13 todos, 19 skipped, 1032 passed (2541 assertions)') ->toContain('Tests: 2 deprecated, 4 warnings, 5 incomplete, 2 notices, 13 todos, 19 skipped, 1035 passed (2545 assertions)')
->toContain('Parallel: 3 processes'); ->toContain('Parallel: 3 processes');
})->skipOnWindows(); })->skipOnWindows();