From f5daa789121f48b78995b3a03b6b4922f5afb688 Mon Sep 17 00:00:00 2001 From: Stephen McMurtry Date: Fri, 9 Jul 2021 16:40:14 -0400 Subject: [PATCH 1/2] added alt text to the canada wordmark --- .../jinja_templates/email_preview_template.jinja2 | 2 +- notifications_utils/jinja_templates/email_template.jinja2 | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/notifications_utils/jinja_templates/email_preview_template.jinja2 b/notifications_utils/jinja_templates/email_preview_template.jinja2 index 016e0cd4..44b051de 100644 --- a/notifications_utils/jinja_templates/email_preview_template.jinja2 +++ b/notifications_utils/jinja_templates/email_preview_template.jinja2 @@ -83,7 +83,7 @@
 diff --git a/notifications_utils/jinja_templates/email_template.jinja2 b/notifications_utils/jinja_templates/email_template.jinja2 index be81bda5..be226dc3 100644 --- a/notifications_utils/jinja_templates/email_template.jinja2 +++ b/notifications_utils/jinja_templates/email_template.jinja2 @@ -174,7 +174,7 @@  Date: Fri, 9 Jul 2021 16:58:48 -0400 Subject: [PATCH 2/2] added some pytest config and fixed the broken tests --- setup.cfg | 2 ++ tests/test_template_types.py | 4 ++-- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/setup.cfg b/setup.cfg index f553d807..57186c3d 100644 --- a/setup.cfg +++ b/setup.cfg @@ -1,5 +1,7 @@ [tool:pytest] xfail_strict=true +testpaths = tests +addopts = -p no:warnings -n4 [flake8] # W504 line break after binary operator diff --git a/tests/test_template_types.py b/tests/test_template_types.py index 0ed66c5c..e7d811c4 100644 --- a/tests/test_template_types.py +++ b/tests/test_template_types.py @@ -160,7 +160,7 @@ def test_alt_text_with_no_brand_text_and_fip_banner_english_shown(renderer): brand_name="Notify Logo", ) ) - assert 'alt=" "' in email + assert 'alt="Symbol of the Government of Canada / Symbole du gouvernement du Canada"' in email assert 'alt="Notify Logo"' in email @@ -177,7 +177,7 @@ def test_alt_text_with_no_brand_text_and_fip_banner_french_shown(renderer): brand_name="Notify Logo", ) ) - assert 'alt=" "' in email + assert 'alt="Symbol of the Government of Canada / Symbole du gouvernement du Canada"' in email assert 'alt="Notify Logo"' in email