Skip to content

Commit

Permalink
Fix account test
Browse files Browse the repository at this point in the history
  • Loading branch information
danharrin committed Mar 2, 2021
1 parent 9414a1a commit 26bdb95
Showing 1 changed file with 7 additions and 7 deletions.
14 changes: 7 additions & 7 deletions tests/Feature/EditAccount.php
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ public function can_update_account_information()
->set('newPasswordConfirmation', $newPassword)
->set('record.email', $newUserDetails->email)
->set('record.name', $newUserDetails->name)
->call('submit')
->call('save')
// ->assertSet('newAvatar', null)
->assertSet('newPassword', null)
->assertSet('newPasswordConfirmation', null)
Expand All @@ -72,7 +72,7 @@ public function can_update_account_information()
//
// $component = Livewire::test(EditAccount::class)
// ->set('newAvatar', $newAvatar)
// ->call('submit');
// ->call('save');
//
// $user->refresh();
//
Expand Down Expand Up @@ -111,7 +111,7 @@ public function new_password_contains_minimum_8_characters()

Livewire::test(EditAccount::class)
->set('newPassword', 'pass')
->call('submit')
->call('save')
->assertHasErrors(['newPassword' => 'min']);
}

Expand All @@ -125,7 +125,7 @@ public function new_password_is_confirmed()
Livewire::test(EditAccount::class)
->set('newPassword', 'password')
->set('newPasswordConfirmation', 'different-password')
->call('submit')
->call('save')
->assertHasErrors(['newPasswordConfirmation' => 'same']);
}

Expand All @@ -138,7 +138,7 @@ public function record_email_is_required()

Livewire::test(EditAccount::class)
->set('record.email', null)
->call('submit')
->call('save')
->assertHasErrors(['record.email' => 'required']);
}

Expand All @@ -151,7 +151,7 @@ public function record_email_is_valid_email()

Livewire::test(EditAccount::class)
->set('record.email', 'invalid-email')
->call('submit')
->call('save')
->assertHasErrors(['record.email' => 'email']);
}

Expand All @@ -164,7 +164,7 @@ public function record_name_is_required()

Livewire::test(EditAccount::class)
->set('record.name', null)
->call('submit')
->call('save')
->assertHasErrors(['record.name' => 'required']);
}
}

0 comments on commit 26bdb95

Please sign in to comment.