feat!: upgrade pyjwt to version 2.1.0
This commit is contained in:
committed by
Awais Qureshi
parent
a35fa080b3
commit
56d12bf230
@@ -46,8 +46,10 @@ class AccessTokenMixin:
|
||||
algorithms=[settings.JWT_AUTH['JWT_ALGORITHM']],
|
||||
audience=audience,
|
||||
issuer=issuer,
|
||||
verify_expiration=verify_expiration,
|
||||
options={'verify_signature': False},
|
||||
options={
|
||||
'verify_signature': False,
|
||||
"verify_exp": verify_expiration
|
||||
},
|
||||
)
|
||||
|
||||
# Note that if we expect the claims to have expired
|
||||
|
||||
@@ -46,7 +46,7 @@ class TestCourseUserDiscount(ModuleStoreTestCase):
|
||||
assert expected_payload['discount_applicable'] == response.data['discount_applicable']
|
||||
|
||||
# make sure that the response matches the expected response
|
||||
response_payload = jwt.decode(response.data['jwt'], verify=False)
|
||||
response_payload = jwt.decode(response.data['jwt'], options={"verify_signature": False})
|
||||
assert all(item in list(response_payload.items()) for item in expected_payload.items())
|
||||
|
||||
def test_course_user_discount_no_user(self):
|
||||
|
||||
Reference in New Issue
Block a user