3 namespace Tests\Feature\Auth;
5 use App\Providers\RouteServiceProvider;
6 use Illuminate\Foundation\Testing\RefreshDatabase;
9 class RegistrationTest extends TestCase
13 public function test_registration_screen_can_be_rendered()
15 $response = $this->get('/register');
17 $response->assertStatus(200);
20 public function test_new_users_can_register()
22 $response = $this->post('/register', [
23 'name' => 'Test User',
24 'email' => 'test@example.com',
25 'password' => 'password',
26 'password_confirmation' => 'password',
29 $this->assertAuthenticated();
30 $response->assertRedirect(RouteServiceProvider::HOME);