]> BookStack Code Mirror - bookstack/blobdiff - tests/Commands/AddAdminCommandTest.php
Started work on details/summary blocks
[bookstack] / tests / Commands / AddAdminCommandTest.php
index 6b03c86f92e46a68f4eac2b107bf0c7793ceaa3b..0f144246c80fa1e21899bdd51964cf5ec99540c7 100644 (file)
@@ -1,4 +1,6 @@
-<?php namespace Tests\Commands;
+<?php
+
+namespace Tests\Commands;
 
 use BookStack\Auth\User;
 use Tests\TestCase;
@@ -8,18 +10,18 @@ class AddAdminCommandTest extends TestCase
     public function test_add_admin_command()
     {
         $exitCode = \Artisan::call('bookstack:create-admin', [
-            '--email' => '[email protected]',
-            '--name' => 'Admin Test',
+            '--email'    => '[email protected]',
+            '--name'     => 'Admin Test',
             '--password' => 'testing-4',
         ]);
         $this->assertTrue($exitCode === 0, 'Command executed successfully');
 
         $this->assertDatabaseHas('users', [
             'email' => '[email protected]',
-            'name' => 'Admin Test'
+            'name'  => 'Admin Test',
         ]);
 
         $this->assertTrue(User::query()->where('email', '=', '[email protected]')->first()->hasSystemRole('admin'), 'User has admin role as expected');
         $this->assertTrue(\Auth::attempt(['email' => '[email protected]', 'password' => 'testing-4']), 'Password stored as expected');
     }
-}
\ No newline at end of file
+}