mirror of
https://github.com/GSA/notifications-api.git
synced 2026-02-02 09:26:08 -05:00
String cleanup complete.
Signed-off-by: Cliff Hill <Clifford.hill@gsa.gov>
This commit is contained in:
@@ -67,17 +67,17 @@ def test_dao_update_annual_billing_for_future_years(notify_db_session, sample_se
|
||||
@pytest.mark.parametrize(
|
||||
"org_type, year, expected_default",
|
||||
[
|
||||
("federal", 2021, 150000),
|
||||
("state", 2021, 150000),
|
||||
(OrganizationType.FEDERAL, 2021, 150000),
|
||||
(OrganizationType.STATE, 2021, 150000),
|
||||
(None, 2021, 150000),
|
||||
("federal", 2020, 250000),
|
||||
("state", 2020, 250000),
|
||||
("other", 2020, 250000),
|
||||
(OrganizationType.FEDERAL, 2020, 250000),
|
||||
(OrganizationType.STATE, 2020, 250000),
|
||||
(OrganizationType.OTHER, 2020, 250000),
|
||||
(None, 2020, 250000),
|
||||
("federal", 2019, 250000),
|
||||
("federal", 2022, 40000),
|
||||
("state", 2022, 40000),
|
||||
("federal", 2023, 40000),
|
||||
(OrganizationType.FEDERAL, 2019, 250000),
|
||||
(OrganizationType.FEDERAL, 2022, 40000),
|
||||
(OrganizationType.STATE, 2022, 40000),
|
||||
(OrganizationType.FEDERAL, 2023, 40000),
|
||||
],
|
||||
)
|
||||
def test_set_default_free_allowance_for_service(
|
||||
|
||||
@@ -10,6 +10,7 @@ from app.dao.service_callback_api_dao import (
|
||||
reset_service_callback_api,
|
||||
save_service_callback_api,
|
||||
)
|
||||
from app.enums import CallbackType
|
||||
from app.models import ServiceCallbackApi
|
||||
from tests.app.db import create_service_callback_api
|
||||
|
||||
@@ -65,7 +66,7 @@ def test_update_service_callback_api_unique_constraint(sample_service):
|
||||
url="https://some_service/callback_endpoint",
|
||||
bearer_token="some_unique_string",
|
||||
updated_by_id=sample_service.users[0].id,
|
||||
callback_type="delivery_status",
|
||||
callback_type=CallbackType.DELIVERY_STATUS,
|
||||
)
|
||||
save_service_callback_api(service_callback_api)
|
||||
another = ServiceCallbackApi(
|
||||
@@ -73,7 +74,7 @@ def test_update_service_callback_api_unique_constraint(sample_service):
|
||||
url="https://some_service/another_callback_endpoint",
|
||||
bearer_token="different_string",
|
||||
updated_by_id=sample_service.users[0].id,
|
||||
callback_type="delivery_status",
|
||||
callback_type=CallbackType.DELIVERY_STATUS,
|
||||
)
|
||||
with pytest.raises(expected_exception=SQLAlchemyError):
|
||||
save_service_callback_api(another)
|
||||
@@ -85,7 +86,7 @@ def test_update_service_callback_can_add_two_api_of_different_types(sample_servi
|
||||
url="https://some_service/callback_endpoint",
|
||||
bearer_token="some_unique_string",
|
||||
updated_by_id=sample_service.users[0].id,
|
||||
callback_type="delivery_status",
|
||||
callback_type=CallbackType.DELIVERY_STATUS,
|
||||
)
|
||||
save_service_callback_api(delivery_status)
|
||||
complaint = ServiceCallbackApi(
|
||||
@@ -93,7 +94,7 @@ def test_update_service_callback_can_add_two_api_of_different_types(sample_servi
|
||||
url="https://some_service/another_callback_endpoint",
|
||||
bearer_token="different_string",
|
||||
updated_by_id=sample_service.users[0].id,
|
||||
callback_type="complaint",
|
||||
callback_type=CallbackType.COMPLAINT,
|
||||
)
|
||||
save_service_callback_api(complaint)
|
||||
results = ServiceCallbackApi.query.order_by(ServiceCallbackApi.callback_type).all()
|
||||
|
||||
Reference in New Issue
Block a user