Skip to content

Commit

Permalink
try/except when looking for an access token to avoid 500
Browse files Browse the repository at this point in the history
  • Loading branch information
discobeta authored and dopry committed Oct 19, 2023
1 parent b327ea9 commit eddbfae
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions tests/test_authorization_code.py
Original file line number Diff line number Diff line change
Expand Up @@ -851,9 +851,9 @@ def test_refresh_invalidates_old_tokens(self):
self.assertIsNotNone(refresh_token.revoked)
self.assertFalse(AccessToken.objects.filter(token=at).exists())

def test_refresh_twice_with_same_token_returns_401(self):
def test_refresh_twice_with_same_token_returns_400(self):
"""
Ensure that using a refresh token twice returns 401
Ensure that using a refresh token twice returns 400
"""
self.client.login(username="test_user", password="123456")
authorization_code = self.get_auth()
Expand Down

0 comments on commit eddbfae

Please sign in to comment.