mirror of
https://github.com/GSA/notifications-api.git
synced 2026-02-04 18:31:13 -05:00
Ensure rate limit is in serialised service
Once we start using the serialised service to power the `POST` notifications endpoint it needs to include rate limit to do the rate limit checks.
This commit is contained in:
@@ -249,7 +249,6 @@ class ServiceSchema(BaseSchema):
|
||||
'inbound_number',
|
||||
'inbound_sms',
|
||||
'letter_logo_filename',
|
||||
'rate_limit',
|
||||
'returned_letters',
|
||||
'users',
|
||||
'version',
|
||||
|
||||
@@ -233,8 +233,34 @@ def test_get_service_by_id(admin_request, sample_service):
|
||||
assert json_resp['data']['id'] == str(sample_service.id)
|
||||
assert not json_resp['data']['research_mode']
|
||||
assert json_resp['data']['email_branding'] is None
|
||||
assert 'branding' not in json_resp['data']
|
||||
assert json_resp['data']['prefix_sms'] is True
|
||||
assert json_resp['data'].keys() == {
|
||||
'active',
|
||||
'consent_to_research',
|
||||
'contact_link',
|
||||
'count_as_live',
|
||||
'created_by',
|
||||
'email_branding',
|
||||
'email_from',
|
||||
'go_live_at',
|
||||
'go_live_user',
|
||||
'id',
|
||||
'inbound_api',
|
||||
'letter_branding',
|
||||
'message_limit',
|
||||
'name',
|
||||
'organisation',
|
||||
'organisation_type',
|
||||
'permissions',
|
||||
'prefix_sms',
|
||||
'rate_limit',
|
||||
'research_mode',
|
||||
'restricted',
|
||||
'service_callback_api',
|
||||
'volume_email',
|
||||
'volume_letter',
|
||||
'volume_sms',
|
||||
}
|
||||
|
||||
|
||||
@pytest.mark.parametrize('detailed', [True, False])
|
||||
|
||||
Reference in New Issue
Block a user