diff --git a/app/dao/services_dao.py b/app/dao/services_dao.py index 8a24502bd..da8b80b42 100644 --- a/app/dao/services_dao.py +++ b/app/dao/services_dao.py @@ -29,7 +29,6 @@ from app.models import ( TemplateRedacted, User, VerifyCode, - EDIT_FOLDERS, EMAIL_TYPE, INTERNATIONAL_SMS_TYPE, KEY_TYPE_TEST, @@ -43,7 +42,6 @@ DEFAULT_SERVICE_PERMISSIONS = [ EMAIL_TYPE, LETTER_TYPE, INTERNATIONAL_SMS_TYPE, - EDIT_FOLDERS, ] diff --git a/tests/app/dao/test_services_dao.py b/tests/app/dao/test_services_dao.py index d25ba0c0e..6d134d616 100644 --- a/tests/app/dao/test_services_dao.py +++ b/tests/app/dao/test_services_dao.py @@ -48,7 +48,6 @@ from app.models import ( KEY_TYPE_NORMAL, KEY_TYPE_TEAM, KEY_TYPE_TEST, - EDIT_FOLDERS, EMAIL_TYPE, SMS_TYPE, INTERNATIONAL_SMS_TYPE, @@ -290,19 +289,16 @@ def test_create_service_returns_service_with_default_permissions(notify_db_sessi service = dao_fetch_service_by_id(service.id) _assert_service_permissions(service.permissions, ( - SMS_TYPE, EMAIL_TYPE, LETTER_TYPE, INTERNATIONAL_SMS_TYPE, EDIT_FOLDERS, + SMS_TYPE, EMAIL_TYPE, LETTER_TYPE, INTERNATIONAL_SMS_TYPE, )) @pytest.mark.parametrize("permission_to_remove, permissions_remaining", [ (SMS_TYPE, ( - EMAIL_TYPE, LETTER_TYPE, INTERNATIONAL_SMS_TYPE, EDIT_FOLDERS, + EMAIL_TYPE, LETTER_TYPE, INTERNATIONAL_SMS_TYPE, )), (EMAIL_TYPE, ( - SMS_TYPE, LETTER_TYPE, INTERNATIONAL_SMS_TYPE, EDIT_FOLDERS, - )), - (EDIT_FOLDERS, ( - EMAIL_TYPE, SMS_TYPE, LETTER_TYPE, INTERNATIONAL_SMS_TYPE, + SMS_TYPE, LETTER_TYPE, INTERNATIONAL_SMS_TYPE, )), ]) def test_remove_permission_from_service_by_id_returns_service_with_correct_permissions( @@ -334,14 +330,14 @@ def test_create_service_by_id_adding_and_removing_letter_returns_service_without service = dao_fetch_service_by_id(service.id) _assert_service_permissions(service.permissions, ( - SMS_TYPE, EMAIL_TYPE, LETTER_TYPE, INTERNATIONAL_SMS_TYPE, EDIT_FOLDERS, + SMS_TYPE, EMAIL_TYPE, LETTER_TYPE, INTERNATIONAL_SMS_TYPE, )) dao_remove_service_permission(service_id=service.id, permission=LETTER_TYPE) service = dao_fetch_service_by_id(service.id) _assert_service_permissions(service.permissions, ( - SMS_TYPE, EMAIL_TYPE, INTERNATIONAL_SMS_TYPE, EDIT_FOLDERS, + SMS_TYPE, EMAIL_TYPE, INTERNATIONAL_SMS_TYPE, )) @@ -474,7 +470,7 @@ def test_delete_service_and_associated_objects(notify_db_session): create_invited_user(service=service) assert ServicePermission.query.count() == len(( - SMS_TYPE, EMAIL_TYPE, LETTER_TYPE, INTERNATIONAL_SMS_TYPE, EDIT_FOLDERS, + SMS_TYPE, EMAIL_TYPE, LETTER_TYPE, INTERNATIONAL_SMS_TYPE, )) delete_service_and_all_associated_db_objects(service) diff --git a/tests/app/service/test_rest.py b/tests/app/service/test_rest.py index e001317c1..610c01015 100644 --- a/tests/app/service/test_rest.py +++ b/tests/app/service/test_rest.py @@ -25,7 +25,7 @@ from app.models import ( User, KEY_TYPE_NORMAL, KEY_TYPE_TEAM, KEY_TYPE_TEST, EMAIL_TYPE, SMS_TYPE, LETTER_TYPE, - EDIT_FOLDERS, INTERNATIONAL_SMS_TYPE, INBOUND_SMS_TYPE, + INTERNATIONAL_SMS_TYPE, INBOUND_SMS_TYPE, ) from tests import create_authorization_header from tests.app.conftest import ( @@ -160,7 +160,7 @@ def test_get_service_list_has_default_permissions(admin_request, service_factory set( json['permissions'] ) == set([ - EMAIL_TYPE, SMS_TYPE, INTERNATIONAL_SMS_TYPE, LETTER_TYPE, EDIT_FOLDERS, + EMAIL_TYPE, SMS_TYPE, INTERNATIONAL_SMS_TYPE, LETTER_TYPE, ]) for json in json_resp['data'] ) @@ -172,7 +172,7 @@ def test_get_service_by_id_has_default_service_permissions(admin_request, sample assert set( json_resp['data']['permissions'] ) == set([ - EMAIL_TYPE, SMS_TYPE, INTERNATIONAL_SMS_TYPE, LETTER_TYPE, EDIT_FOLDERS, + EMAIL_TYPE, SMS_TYPE, INTERNATIONAL_SMS_TYPE, LETTER_TYPE, ])