mirror of
https://github.com/GSA/notifications-api.git
synced 2026-02-04 02:11:11 -05:00
refactor tests
re-order notification dao delete notifications test to move "fixtures" to the top of the file changed create_service_data_retention to take an ORM object, not an id. brings it in line with other db.py test functions
This commit is contained in:
@@ -141,8 +141,8 @@ def test_update_service_data_retention_does_not_update_row_if_data_retention_is_
|
||||
('letter', 'sms')]
|
||||
)
|
||||
def test_fetch_service_data_retention_by_notification_type(sample_service, notification_type, alternate):
|
||||
data_retention = create_service_data_retention(service_id=sample_service.id, notification_type=notification_type)
|
||||
create_service_data_retention(service_id=sample_service.id, notification_type=alternate)
|
||||
data_retention = create_service_data_retention(service=sample_service, notification_type=notification_type)
|
||||
create_service_data_retention(service=sample_service, notification_type=alternate)
|
||||
result = fetch_service_data_retention_by_notification_type(sample_service.id, notification_type)
|
||||
assert result == data_retention
|
||||
|
||||
|
||||
Reference in New Issue
Block a user