tests: Rename APPLE_JWK to a generic name for re-use in other tests.

This can be re-used for the JWK in OIDC implementation in the follow-up
commits.
This commit is contained in:
Mateusz Mandera 2021-05-21 16:26:33 +02:00 committed by Tim Abbott
parent 116e41f1da
commit cd88a6e6fb
3 changed files with 3 additions and 3 deletions

View File

@ -2533,7 +2533,7 @@ class AppleIdAuthBackendTest(AppleAuthMixin, SocialAuthBase):
requests_mock.GET,
self.BACKEND_CLASS.JWK_URL,
status=200,
json=json.loads(settings.APPLE_JWK),
json=json.loads(settings.EXAMPLE_JWK),
)
def generate_access_url_payload(self, account_data_dict: Dict[str, str]) -> str:
@ -2732,7 +2732,7 @@ class AppleAuthBackendNativeFlowTest(AppleAuthMixin, SocialAuthBase):
requests_mock.GET,
self.BACKEND_CLASS.JWK_URL,
status=200,
json=json.loads(settings.APPLE_JWK),
json=json.loads(settings.EXAMPLE_JWK),
)
yield

View File

@ -188,7 +188,7 @@ SOCIAL_AUTH_APPLE_KEY = "KEYISKEY"
SOCIAL_AUTH_APPLE_TEAM = "TEAMSTRING"
SOCIAL_AUTH_APPLE_SECRET = get_from_file_if_exists("zerver/tests/fixtures/apple/private_key.pem")
APPLE_JWK = get_from_file_if_exists("zerver/tests/fixtures/apple/jwk")
EXAMPLE_JWK = get_from_file_if_exists("zerver/tests/fixtures/example_jwk")
APPLE_ID_TOKEN_GENERATION_KEY = get_from_file_if_exists(
"zerver/tests/fixtures/apple/token_gen_private_key"
)