Re-add attributes to OAuthScopeProblem

This commit is contained in:
Robbe Sneyders
2023-02-23 00:00:45 +01:00
parent 61f2aee1f7
commit ec5dd278d0
4 changed files with 27 additions and 12 deletions

View File

@@ -105,9 +105,8 @@ def test_security(oauth_requests, secure_endpoint_app):
assert get_bye_wrong_scope.status_code == 403
assert get_bye_wrong_scope.headers.get("content-type") == "application/problem+json"
get_bye_wrong_scope_reponse = get_bye_wrong_scope.json()
assert (
get_bye_wrong_scope_reponse["detail"]
== "Provided token doesn't have the required scope"
assert get_bye_wrong_scope_reponse["detail"].startswith(
"Provided token does not have the required scope"
)
headers = {"Authorization": "Bearer 300"}