mirror of
https://github.com/GSA/notifications-api.git
synced 2026-07-29 20:48:21 -04:00
Add fields to record a service’s estimated volumes
When a service go live we ask people for their estimated sending volumes. At the moment we only put this in the ticket, and store it in a spreadsheet. This means that a service can - say they want to go live - say they are sending 100,000 emails per year - not have created any email templates - still see ‘create templates’ as ‘completed’ in the go live checklist If we store this data against the service we can collect it earlier, and then use it to determine automatically what kind of templates the user needs to create before their go live checklist can be considered complete.
This commit is contained in:
@@ -615,6 +615,32 @@ def test_update_service_sets_crown(client, sample_service, org_type, expected):
|
||||
assert result['data']['crown'] is expected
|
||||
|
||||
|
||||
@pytest.mark.parametrize('field', (
|
||||
'volume_email',
|
||||
'volume_sms',
|
||||
'volume_letter',
|
||||
))
|
||||
@pytest.mark.parametrize('value', (
|
||||
'ABC123',
|
||||
None,
|
||||
))
|
||||
def test_update_service_sets_volumes(
|
||||
admin_request,
|
||||
sample_service,
|
||||
field,
|
||||
value,
|
||||
):
|
||||
admin_request.post(
|
||||
'service.update_service',
|
||||
service_id=sample_service.id,
|
||||
_data={
|
||||
field: value,
|
||||
},
|
||||
_expected_status=200,
|
||||
)
|
||||
assert getattr(sample_service, field) == value
|
||||
|
||||
|
||||
@pytest.fixture(scope='function')
|
||||
def service_with_no_permissions(notify_db, notify_db_session):
|
||||
return create_service(service_permissions=[])
|
||||
|
||||
Reference in New Issue
Block a user