post('api/v1/account/invite/registration', [ 'company_id' => 1, 'name' => 'Test User', 'email' => 'test@example.com', 'phone' => '899990989', 'wechat_id' => '5666', 'company_name' => 'test company co', 'password' => 'password', 'password_confirmation' => 'password', 'contact_email' => "contact@email.com", ]); $response->assertStatus(404); } public function test_new_users_can_register() { $response = $this->post('/api/v1/account/registration', [ 'type' => 1, 'name' => 'Test User', 'email' => 'test@example.com', 'phone' => '899990989', 'wechat_id' => '5666', 'company_name' => 'test company co', 'password' => 'password', 'password_confirmation' => 'password', 'contact_email' => "contact@email.com", ]); $this->assertDatabaseHas('users', [ 'id' => 1, 'email' => 'test@example.com', 'name' => 'Test User', ]); //todo an error experienced on line $inviter = $this->fetchesCompanyModule->execute(['reference'=>'CIEF']); //todo 1. assert a user was logged in 2. assert a user was redirected 3. assert user has a token } */ }