thunderbird_accounts.authentication.tests.test_middleware
Classes
|
|
|
|
|
- class thunderbird_accounts.authentication.tests.test_middleware.RefreshUserAccessTokenTestCase(methodName='runTest')[source]
Bases:
TestCase
- class thunderbird_accounts.authentication.tests.test_middleware.OIDCRefreshSessionTestCase(methodName='runTest')[source]
Bases:
TestCase- test_introspect_does_not_happen_without_feature_flag(mock_post: MagicMock)
This should hit the ‘not expired’ check and do nothing.
- test_introspect_does_happen_if_feature_flag_is_set(mock_post: MagicMock)
This should hit a request.post, and our expected result for this test is the token is active.
- test_introspect_if_access_token_is_inactive(mock_post: MagicMock)
This should hit a request.post fail due to token being inactive, and refresh successfully.
- class thunderbird_accounts.authentication.tests.test_middleware.AccountsOIDCBackendTestCase(methodName='runTest')[source]
Bases:
TestCase- test_update_user_dont_reset_services_admin_permissions()[source]
Testing update_user to make sure not including is_services_admin in claim will leave is_staff, and is_superuser fields alone.