From 85b8b343e21c6bf81a75429d5836aea73f8a4652 Mon Sep 17 00:00:00 2001 From: Pea Tyczynska Date: Thu, 20 Dec 2018 18:09:00 +0000 Subject: [PATCH] Service deafault radio checked by default, existing tests pass. --- app/main/forms.py | 4 ++-- app/notify_client/service_api_client.py | 2 +- tests/app/main/views/test_templates.py | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/app/main/forms.py b/app/main/forms.py index b8f95bab4..7a45459ff 100644 --- a/app/main/forms.py +++ b/app/main/forms.py @@ -452,10 +452,10 @@ class LetterTemplateForm(EmailTemplateForm): choices=[ ('first', 'First class'), ('second', 'Second class'), - ('service_default', "Service default"), + ('None', "Service default"), ], validators=[DataRequired()], - default='service_default' + default='None' ) subject = TextAreaField( diff --git a/app/notify_client/service_api_client.py b/app/notify_client/service_api_client.py index e74420413..78f19896c 100644 --- a/app/notify_client/service_api_client.py +++ b/app/notify_client/service_api_client.py @@ -178,7 +178,7 @@ class ServiceAPIClient(NotifyAdminAPIClient): data.update({ 'postage': postage }) - elif postage == "service_default": + elif postage == 'None': data.update({ 'postage': None }) diff --git a/tests/app/main/views/test_templates.py b/tests/app/main/views/test_templates.py index 6b438b568..a7a715566 100644 --- a/tests/app/main/views/test_templates.py +++ b/tests/app/main/views/test_templates.py @@ -1091,7 +1091,7 @@ def test_should_show_interstitial_when_making_breaking_change( } if template_type == "letter": - data.update({"postage": "service_default"}) + data["postage"] = 'None' response = logged_in_client.post( url_for('.edit_service_template', service_id=service_id, template_id=template_id),