Skip to content

Commit

Permalink
wip
Browse files Browse the repository at this point in the history
Signed-off-by: Mior Muhammad Zaki <[email protected]>
  • Loading branch information
crynobone committed Dec 9, 2024
1 parent 4775221 commit d7ca635
Show file tree
Hide file tree
Showing 2 changed files with 22 additions and 5 deletions.
10 changes: 8 additions & 2 deletions tests/Console/DevToolCommandTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,10 @@ public function it_can_run_devtool_command_with_installation(?string $answer, bo
'.env',
'.env.example',
'.env.dist',
])->assertSuccessful();
])
->expectsConfirmation('Generate `workbench/bootstrap/app.php` file?', answer: 'no')
->expectsConfirmation('Generate `workbench/bootstrap/providers.php` file?', answer: 'no')
->assertSuccessful();

$this->assertCommandExecutedWithDevTool();
$this->assertCommandExecutedWithInstall();
Expand All @@ -34,7 +37,10 @@ public function it_can_run_devtool_command_with_basic_installation(?string $answ
'.env',
'.env.example',
'.env.dist',
])->assertSuccessful();
])
->expectsConfirmation('Generate `workbench/bootstrap/app.php` file?', answer: 'no')
->expectsConfirmation('Generate `workbench/bootstrap/providers.php` file?', answer: 'no')
->assertSuccessful();

$this->assertCommandExecutedWithDevTool();
$this->assertCommandExecutedWithBasicInstall();
Expand Down
17 changes: 14 additions & 3 deletions tests/Console/InstallCommandTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,10 @@ public function it_can_run_installation_command_with_devtool(?string $answer, bo
'.env',
'.env.example',
'.env.dist',
])->assertSuccessful();
])
->expectsConfirmation('Generate `workbench/bootstrap/app.php` file?', answer: 'no')
->expectsConfirmation('Generate `workbench/bootstrap/providers.php` file?', answer: 'no')
->assertSuccessful();

$this->assertCommandExecutedWithInstall();
$this->assertCommandExecutedWithDevTool();
Expand All @@ -38,7 +41,10 @@ public function it_can_run_installation_command_without_devtool(?string $answer,
'.env',
'.env.example',
'.env.dist',
])->assertSuccessful();
])
->expectsConfirmation('Generate `workbench/bootstrap/app.php` file?', answer: 'no')
->expectsConfirmation('Generate `workbench/bootstrap/providers.php` file?', answer: 'no')
->assertSuccessful();

$this->assertCommandExecutedWithInstall();
$this->assertCommandExecutedWithoutDevTool();
Expand All @@ -55,7 +61,10 @@ public function it_can_run_basic_installation_command_without_devtool(?string $a
'.env',
'.env.example',
'.env.dist',
])->assertSuccessful();
])
->expectsConfirmation('Generate `workbench/bootstrap/app.php` file?', answer: 'no')
->expectsConfirmation('Generate `workbench/bootstrap/providers.php` file?', answer: 'no')
->assertSuccessful();

$this->assertCommandExecutedWithBasicInstall();
$this->assertCommandExecutedWithoutDevTool();
Expand All @@ -77,6 +86,8 @@ public function it_can_ignore_generating_environment_file_if_it_already_exists()

$this->artisan('workbench:install', ['--basic' => true, '--no-devtool' => true])
->expectsOutputToContain('File [.env] already exists')
->expectsConfirmation('Generate `workbench/bootstrap/app.php` file?', answer: 'no')
->expectsConfirmation('Generate `workbench/bootstrap/providers.php` file?', answer: 'no')
->assertSuccessful();

$environmentFiles->each(function ($env) use ($workingPath) {
Expand Down

0 comments on commit d7ca635

Please sign in to comment.