mirror of
https://github.com/GSA/notifications-api.git
synced 2026-02-03 01:41:05 -05:00
Refactor to use query string rather than path params
This commit is contained in:
@@ -6,6 +6,7 @@ from app.v2.inbound_sms.inbound_sms_schemas import get_inbound_sms_response, get
|
||||
from app.schema_validation import validate
|
||||
|
||||
from tests import create_authorization_header
|
||||
from tests.app.db import create_inbound_sms
|
||||
|
||||
|
||||
valid_inbound_sms = {
|
||||
@@ -44,7 +45,7 @@ invalid_inbound_sms_list = {
|
||||
|
||||
def test_get_inbound_sms_contract(client, sample_inbound_sms):
|
||||
auth_header = create_authorization_header(service_id=sample_inbound_sms.service_id)
|
||||
response = client.get('/v2/received-text-messages/{}'.format(sample_inbound_sms.user_number), headers=[auth_header])
|
||||
response = client.get('/v2/received-text-messages', headers=[auth_header])
|
||||
response_json = json.loads(response.get_data(as_text=True))
|
||||
|
||||
assert validate(response_json, get_inbound_sms_response)['received_text_messages'][0] \
|
||||
|
||||
Reference in New Issue
Block a user