From 766d97fc7fdde8564e399c2b2859db147d0cfc22 Mon Sep 17 00:00:00 2001 From: Nuno Maduro Date: Wed, 3 Jan 2024 16:44:39 +0000 Subject: [PATCH 1/2] Uses CreatesApplication if exists --- src/Console/InstallCommand.php | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/src/Console/InstallCommand.php b/src/Console/InstallCommand.php index 01ca940a4..9b46a01ae 100644 --- a/src/Console/InstallCommand.php +++ b/src/Console/InstallCommand.php @@ -62,6 +62,20 @@ public function handle() } } + $baseTestCase = file_get_contents(base_path('tests/DuskTestCase.php')); + + if (! trait_exists(\Tests\CreatesApplication::class)) { + file_put_contents(base_path('tests/DuskTestCase.php'), str_replace(<<info('Dusk scaffolding installed successfully.'); $this->comment('Downloading ChromeDriver binaries...'); From 1cceccbbdeb8a7abb99e3277454bcc79195b630b Mon Sep 17 00:00:00 2001 From: StyleCI Bot Date: Wed, 3 Jan 2024 16:45:09 +0000 Subject: [PATCH 2/2] Apply fixes from StyleCI --- src/Console/InstallCommand.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/Console/InstallCommand.php b/src/Console/InstallCommand.php index 9b46a01ae..62d7597ed 100644 --- a/src/Console/InstallCommand.php +++ b/src/Console/InstallCommand.php @@ -65,11 +65,11 @@ public function handle() $baseTestCase = file_get_contents(base_path('tests/DuskTestCase.php')); if (! trait_exists(\Tests\CreatesApplication::class)) { - file_put_contents(base_path('tests/DuskTestCase.php'), str_replace(<<