Merge pull request #2230 from alphagov/add-branding-name-to-ui

Show the 'name' of the email branding in the adding and editing screens
This commit is contained in:
Tom Byers
2018-08-14 16:05:56 +01:00
committed by GitHub
14 changed files with 48 additions and 73 deletions

View File

@@ -26,10 +26,11 @@ def test_get_letter_email_branding(mocker):
def test_create_email_branding(mocker):
org_data = {'logo': 'test.png', 'name': 'test name', 'colour': 'red'}
org_data = {'logo': 'test.png', 'name': 'test name', 'text': 'test name', 'colour': 'red'}
mock_post = mocker.patch('app.notify_client.email_branding_client.EmailBrandingClient.post')
EmailBrandingClient().create_email_branding(logo=org_data['logo'], name=org_data['name'], colour=org_data['colour'])
EmailBrandingClient().create_email_branding(
logo=org_data['logo'], name=org_data['name'], text=org_data['text'], colour=org_data['colour'])
mock_post.assert_called_once_with(
url='/email-branding',
@@ -38,11 +39,12 @@ def test_create_email_branding(mocker):
def test_update_email_branding(mocker, fake_uuid):
org_data = {'logo': 'test.png', 'name': 'test name', 'colour': 'red'}
org_data = {'logo': 'test.png', 'name': 'test name', 'text': 'test name', 'colour': 'red'}
mock_post = mocker.patch('app.notify_client.email_branding_client.EmailBrandingClient.post')
EmailBrandingClient().update_email_branding(
branding_id=fake_uuid, logo=org_data['logo'], name=org_data['name'], colour=org_data['colour'])
branding_id=fake_uuid, logo=org_data['logo'], name=org_data['name'], text=org_data['text'],
colour=org_data['colour'])
mock_post.assert_called_once_with(
url='/email-branding/{}'.format(fake_uuid),