Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

v0.5.6.3 #188

Merged
merged 5 commits into from
Mar 1, 2024
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Django Compatibility Update
Tests Updates
  • Loading branch information
elarroba committed Mar 1, 2024
commit ea9930c532a26eb0c2257610a53f38c9b7b1160f
12 changes: 5 additions & 7 deletions django_ledger/tests/test_auth.py
Original file line number Diff line number Diff line change
Expand Up @@ -31,9 +31,8 @@ def test_user_with_wrong_credentials(self):
'password': self.PASSWORD + '1',
}, follow=False)
self.assertContains(response, text='Login', status_code=200)
self.assertFormError(response,
field=None,
form='form',
self.assertFormError(field=None,
form=response.context_data['form'],
errors=[
'Please enter a correct username and password. Note that both fields may be case-sensitive.'
])
Expand All @@ -43,9 +42,8 @@ def test_user_with_wrong_credentials(self):
'password': self.PASSWORD,
}, follow=False)
self.assertContains(response, text='Login', status_code=200)
self.assertFormError(response,
field=None,
form='form',
self.assertFormError(field=None,
form=response.context_data['form'],
errors=[
'Please enter a correct username and password. Note that both fields may be case-sensitive.'
])
Expand All @@ -71,5 +69,5 @@ def test_user_can_logout(self):
# logout button is present...
self.assertContains(response, text='id="djl-el=logout-button-nav"')

response = self.client.get(logout_url)
response = self.client.post(logout_url)
self.assertRedirects(response, expected_url=login_url)