mirror of
https://github.com/GSA/notifications-admin.git
synced 2026-07-28 11:49:13 -04:00
Merge pull request #264 from alphagov/fix-sign-in-tests
Fix to sign in test and user model
This commit is contained in:
@@ -58,18 +58,6 @@ def test_should_return_locked_out_true_when_user_is_locked(app_,
|
||||
assert 'Username or password is incorrect' in resp.get_data(as_text=True)
|
||||
|
||||
|
||||
def test_should_return_active_user_is_false_if_user_is_inactive(app_, mock_get_user_by_email_inactive):
|
||||
|
||||
with app_.test_request_context():
|
||||
response = app_.test_client().post(
|
||||
url_for('main.sign_in'), data={
|
||||
'email_address': 'inactive_user@example.gov.uk',
|
||||
'password': 'val1dPassw0rd!'})
|
||||
|
||||
assert response.status_code == 200
|
||||
assert 'Username or password is incorrect' in response.get_data(as_text=True)
|
||||
|
||||
|
||||
def test_should_return_200_when_user_does_not_exist(app_, mock_get_user_by_email_not_found):
|
||||
with app_.test_request_context():
|
||||
response = app_.test_client().post(
|
||||
|
||||
Reference in New Issue
Block a user