remove service letter contact model

This commit is contained in:
stvnrlly
2023-02-17 22:56:54 -05:00
parent 007741fe44
commit c34b24014a
16 changed files with 57 additions and 469 deletions

View File

@@ -10,8 +10,6 @@ def test_get_service_data_retention(client, sample_service):
sms_data_retention = create_service_data_retention(service=sample_service)
email_data_retention = create_service_data_retention(service=sample_service, notification_type='email',
days_of_retention=10)
letter_data_retention = create_service_data_retention(service=sample_service, notification_type='letter',
days_of_retention=30)
response = client.get(
'/service/{}/data-retention'.format(str(sample_service.id)),
@@ -20,10 +18,9 @@ def test_get_service_data_retention(client, sample_service):
assert response.status_code == 200
json_response = json.loads(response.get_data(as_text=True))
assert len(json_response) == 3
assert len(json_response) == 2
assert json_response[0] == email_data_retention.serialize()
assert json_response[1] == sms_data_retention.serialize()
assert json_response[2] == letter_data_retention.serialize()
def test_get_service_data_retention_returns_empty_list(client, sample_service):
@@ -99,7 +96,7 @@ def test_create_service_data_retention_returns_400_when_notification_type_is_inv
json_resp = json.loads(response.get_data(as_text=True))
assert response.status_code == 400
assert json_resp['errors'][0]['error'] == 'ValidationError'
assert json_resp['errors'][0]['message'] == 'notification_type unknown is not one of [sms, letter, email]'
assert json_resp['errors'][0]['message'] == 'notification_type unknown is not one of [sms, email]'
def test_create_service_data_retention_returns_400_when_data_retention_for_notification_type_already_exists(