1
0
mirror of https://github.com/BookStackApp/BookStack.git synced 2025-10-26 17:31:27 +03:00

Commands: Updated create admin skip return

Return status for skipped --initial creation will now return 2, so that
it can be identified seperate from a creation and from an error.
This commit is contained in:
Dan Brown
2025-08-07 13:16:49 +01:00
parent 2eefbd21c1
commit f36e6fb929
2 changed files with 8 additions and 8 deletions

View File

@@ -109,7 +109,7 @@ class CreateAdminCommandTest extends TestCase
'--password' => 'testing-7',
'--initial' => true,
])->expectsOutput('Non-default admin user already exists. Skipping creation of new admin user.')
->assertExitCode(0);
->assertExitCode(2);
$defaultAdmin->refresh();
@@ -156,7 +156,7 @@ class CreateAdminCommandTest extends TestCase
'--password' => 'testing-7',
'--initial' => true,
])->expectsOutput("Non-default admin user already exists. Skipping creation of new admin user.")
->assertExitCode(0);
->assertExitCode(2);
}
public function test_initial_option_creation_errors_if_email_already_exists()