Split generating authorization headers by type

In response to [1].

[1]: https://github.com/alphagov/notifications-api/pull/3300#discussion_r681653248
This commit is contained in:
Ben Thorner
2021-08-04 15:12:09 +01:00
parent 5a1636e41f
commit 0312e2a528
33 changed files with 526 additions and 512 deletions

View File

@@ -1,6 +1,6 @@
from flask import json
from tests import create_authorization_header
from tests import create_service_authorization_header
from . import return_json_from_response, validate_v0
@@ -11,7 +11,7 @@ def _post_notification(client, template, url, to):
'template': str(template.id)
}
auth_header = create_authorization_header(service_id=template.service_id)
auth_header = create_service_authorization_header(service_id=template.service_id)
return client.post(
path=url,