mirror of
https://github.com/pestphp/pest.git
synced 2026-12-03 22:45:06 +01:00
dc73ec009e
Co-authored-by: Punyapal Shah <mrpunyapal@gmail.com>
28 lines
590 B
PHP
28 lines
590 B
PHP
<?php
|
|
|
|
declare(strict_types=1);
|
|
|
|
namespace Pest\Plugins\Tia\WatchDefaults;
|
|
|
|
use Pest\Plugins\Tia\Contracts\WatchDefault;
|
|
use Pest\Support\InstalledPackages;
|
|
|
|
/**
|
|
* @internal
|
|
*/
|
|
final readonly class Inertia implements WatchDefault
|
|
{
|
|
public function applicable(): bool
|
|
{
|
|
return InstalledPackages::has('inertiajs/inertia-laravel')
|
|
|| InstalledPackages::has('rompetomp/inertia-bundle');
|
|
}
|
|
|
|
public function defaults(string $projectRoot, string $testPath): array
|
|
{
|
|
return [
|
|
'resources/js/** !*.php' => [$testPath],
|
|
];
|
|
}
|
|
}
|