diff --git a/tests/py/test_email.py b/tests/py/test_email.py index a7077001d9..cc85892013 100644 --- a/tests/py/test_email.py +++ b/tests/py/test_email.py @@ -101,7 +101,7 @@ def test_post_with_looooong_address_is_400(self): def test_verify_email_without_adding_email(self): response = self.verify_email('', 'sample-nonce') - assert 'Missing Info' in response.body + assert 'Bad Info' in response.body def test_verify_email_wrong_nonce(self): self.hit_email_spt('add-email', 'alice@example.com') diff --git a/tests/ttw/test_verify_email.py b/tests/ttw/test_verify_email.py deleted file mode 100644 index a6a3279613..0000000000 --- a/tests/ttw/test_verify_email.py +++ /dev/null @@ -1,15 +0,0 @@ -from __future__ import absolute_import, division, print_function, unicode_literals - -from gratipay.testing import BrowserHarness - - -class Tests(BrowserHarness): - - def test_clicking_resend_doesnt_error(self): - self.make_participant('alice', claimed_time='now') - self.sign_in('alice') - self.visit('/~alice/emails/verify.html?email=alice@gratipay.com&nonce=abcd') - assert self.has_text('The verification code for alice@gratipay.com is bad.') - self.css('button.resend').click() - assert self.has_element('.notification.notification-success', 2) - assert self.has_text('A verification email has been sent') diff --git a/www/~/%username/emails/verify.html.spt b/www/~/%username/emails/verify.html.spt index 056994b45a..d607ed5a72 100644 --- a/www/~/%username/emails/verify.html.spt +++ b/www/~/%username/emails/verify.html.spt @@ -29,16 +29,6 @@ if participant == user.participant: suppress_sidebar = True [-----------------------------------------------------------------------------] {% extends "templates/base.html" %} - -{% block scripts %} - -{{ super() }} -{% endblock %} - {% block content %} {% if user.ANON %}

{{ _("Please Sign In") }}

@@ -58,31 +48,22 @@ suppress_sidebar = True {% else %} {% if result == email.VERIFICATION_SUCCEEDED %}

{{ _("Success!") }}

-

{{ _("Your email address {0} is now connected to your Gratipay account.", - ("%s"|safe) % email) }}

+

{{ _( "{email_address} is now connected to your Gratipay account." + , email_address=("%s"|safe) % email_address + ) }}

{% elif result == email.VERIFICATION_STYMIED %}

{{ _("Address Taken") }}

-

{{ _("The email address {0} is already connected to a different Gratipay account.", - ("%s"|safe) % email_address) }}

+

{{ _( "{email_address} is already connected to a different Gratipay account." + , email_address=("%s"|safe) % email_address + ) }}

{% elif result == email.VERIFICATION_REDUNDANT %}

{{ _("Already Verified") }}

-

{{ _("Your email address {0} is already connected to your Gratipay account.", - ("%s"|safe) % email_address) }}

- {% elif result == email.VERIFICATION_MISSING %} -

{{ _("Missing Info") }}

-

{{ _("Sorry, that's a bad link. You'll need to view your email addresses " - "and start over.") }}

+

{{ _( "{email_address} is already connected to your Gratipay account." + , email_address=("%s"|safe) % email_address + ) }}

{% else %} - {% if result == email.VERIFICATION_EXPIRED %} -

{{ _("Expired") }}

-

{{ _("The verification code for {0} has expired.", - ("%s"|safe) % email_address) }}

- {% elif result == email.VERIFICATION_FAILED %} -

{{ _("Failure") }}

-

{{ _("The verification code for {0} is bad.", - ("%s"|safe) % email_address) }}

- {% endif %} -

+

{{ _("Bad Info") }}

+

{{ _("Sorry, that's a bad or expired link. You'll need to start over.") }}

{% endif %} {{ _("View your email addresses") }}. {% endif %}