mirror of
https://github.com/GSA/notifications-api.git
synced 2025-12-22 16:31:15 -05:00
Refactored code to use new service permissions only
This commit is contained in:
@@ -316,7 +316,8 @@ def test_rejects_api_calls_with_international_numbers_if_service_does_not_allow_
|
||||
|
||||
|
||||
@pytest.mark.parametrize('key_type', ['test', 'normal'])
|
||||
def test_allows_api_calls_with_international_numbers_if_service_does_allow_int_sms(sample_service, key_type):
|
||||
sample_service.permissions = ['international_sms']
|
||||
result = validate_and_format_recipient('20-12-1234-1234', key_type, sample_service, 'sms')
|
||||
def test_allows_api_calls_with_international_numbers_if_service_does_allow_int_sms(
|
||||
key_type, notify_db, notify_db_session):
|
||||
service = create_service(notify_db, notify_db_session, permissions=['sms', 'international_sms'])
|
||||
result = validate_and_format_recipient('20-12-1234-1234', key_type, service, 'sms')
|
||||
assert result == '201212341234'
|
||||
|
||||
Reference in New Issue
Block a user