From d0dd6218f734a68c1accf99e12d99628e3bfa8c3 Mon Sep 17 00:00:00 2001 From: Pea Tyczynska Date: Wed, 1 Jul 2020 11:49:11 +0100 Subject: [PATCH] Show different page for local org users when adding new service --- app/main/views/add_service.py | 7 +++++++ tests/app/main/views/test_add_service.py | 2 +- 2 files changed, 8 insertions(+), 1 deletion(-) diff --git a/app/main/views/add_service.py b/app/main/views/add_service.py index b1b726189..3b9f563e2 100644 --- a/app/main/views/add_service.py +++ b/app/main/views/add_service.py @@ -80,6 +80,13 @@ def add_service(): template_id=example_sms_template['data']['id'] )) else: + if default_organisation_type == 'local': + return render_template( + 'views/add-service-local.html', + form=form, + heading=heading, + default_organisation_type=default_organisation_type, + ) return render_template( 'views/add-service.html', form=form, diff --git a/tests/app/main/views/test_add_service.py b/tests/app/main/views/test_add_service.py index 277e493f7..789f7474e 100644 --- a/tests/app/main/views/test_add_service.py +++ b/tests/app/main/views/test_add_service.py @@ -88,7 +88,7 @@ def test_show_different_page_if_user_org_type_is_local( assert page.select_one('h1').text.strip() == 'About your service' assert page.select_one('input[name=name]')['value'] == '' assert page.select_one('main .govuk-body').text.strip() == ( - 'Give your service a name that tells users what your' + 'Give your service a name that tells users what your ' 'messages are about, as well as who they’re from. For example:')