From 6279b327d60901a15f93c3ce5a2f7c29a6c719ea Mon Sep 17 00:00:00 2001 From: Leo Hemsted Date: Wed, 17 Aug 2016 15:59:16 +0100 Subject: [PATCH 1/4] Update README.md --- README.md | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) diff --git a/README.md b/README.md index 375e7208e..8dec06960 100644 --- a/README.md +++ b/README.md @@ -19,7 +19,7 @@ GOV.UK Notify admin application. ## First-time setup Languages needed -- Python 3 +- Python 3.4 - [Node](http://nodejs.org/) 5.0.0 or greater ```shell brew install node @@ -34,18 +34,15 @@ version of Node. npm rebuild node-sass ``` -The app runs within a virtual environment. To [install virtualenv](https://virtualenv.readthedocs.org/en/latest/installation.html), run -```shell - [sudo] pip install virtualenv -``` - -Make a virtual environment for this app: +The app runs within a virtual environment. We use mkvirtualenv for easier working with venvs ```shell + pip install virtualenvwrapper mkvirtualenv -p /usr/local/bin/python3 notifications-admin ``` Install dependencies and build the frontend assets: ```shell + workon notifications-admin ./scripts/bootstrap.sh ``` @@ -74,6 +71,10 @@ export DESKPRO_ASSIGNED_AGENT_TEAM_ID="" "> environment.sh ``` +## AWS credentials + +Your aws credentials should be stored in a folder located at `~/.aws`. Follow [Amazon's instructions](http://docs.aws.amazon.com/cli/latest/userguide/cli-chap-getting-started.html#cli-config-files) for storing them correctly + ## Running the application From aa166856b43fc246f87203f6d0082b365f4fa06b Mon Sep 17 00:00:00 2001 From: Chris Hill-Scott Date: Mon, 22 Aug 2016 10:17:03 +0100 Subject: [PATCH 2/4] Change 'verification code' to 'security code' Extensive testing on Verify has shown that this is understood better. --- app/templates/views/register-from-invite.html | 2 +- app/templates/views/register.html | 2 +- app/templates/views/two-factor.html | 2 +- app/templates/views/verification-not-received.html | 4 ++-- app/templates/views/verify-mobile.html | 4 ++-- tests/app/main/views/test_code_not_received.py | 2 +- tests/app/main/views/test_two_factor.py | 2 +- tests/app/main/views/test_verify.py | 2 +- 8 files changed, 10 insertions(+), 10 deletions(-) diff --git a/app/templates/views/register-from-invite.html b/app/templates/views/register-from-invite.html index 38b277c31..014b03eda 100644 --- a/app/templates/views/register-from-invite.html +++ b/app/templates/views/register-from-invite.html @@ -14,7 +14,7 @@ Create an account – GOV.UK Notify

Your account will be created with this email: {{email_address}}

{{ textbox(form.name, width='3-4') }} - {{ textbox(form.mobile_number, width='3-4', hint='We’ll send you a verification code by text message') }} + {{ textbox(form.mobile_number, width='3-4', hint='We’ll send you a security code by text message') }} {{ textbox(form.password, hint="Your password must have at least 10 characters", width='3-4') }} {{ page_footer("Continue") }} {{form.service}} diff --git a/app/templates/views/register.html b/app/templates/views/register.html index ff76eb4c8..86507838f 100644 --- a/app/templates/views/register.html +++ b/app/templates/views/register.html @@ -14,7 +14,7 @@ Create an account – GOV.UK Notify {{ textbox(form.name, width='3-4') }} {{ textbox(form.email_address, hint="Must be from a central government organisation", width='3-4', safe_error_message=True) }} - {{ textbox(form.mobile_number, width='3-4', hint='We’ll send you a verification code by text message') }} + {{ textbox(form.mobile_number, width='3-4', hint='We’ll send you a security code by text message') }} {{ textbox(form.password, hint="At least 10 characters", width='3-4') }} {{ page_footer("Continue") }}
diff --git a/app/templates/views/two-factor.html b/app/templates/views/two-factor.html index 2459ae8dc..6be75c039 100644 --- a/app/templates/views/two-factor.html +++ b/app/templates/views/two-factor.html @@ -13,7 +13,7 @@

Check your phone

-

We’ve sent you a text message with a verification code.

+

We’ve sent you a text message with a security code.

{{ textbox( diff --git a/app/templates/views/verification-not-received.html b/app/templates/views/verification-not-received.html index da577cceb..7b322f087 100644 --- a/app/templates/views/verification-not-received.html +++ b/app/templates/views/verification-not-received.html @@ -8,7 +8,7 @@
-

Resend verification code

+

Resend security code

Text messages sometimes take a few minutes to arrive. If you do not receive the text message, you can resend it.

@@ -16,7 +16,7 @@

- Resend verification code + Resend security code

diff --git a/app/templates/views/verify-mobile.html b/app/templates/views/verify-mobile.html index 2ed9dbdd1..4cb7135a7 100644 --- a/app/templates/views/verify-mobile.html +++ b/app/templates/views/verify-mobile.html @@ -10,10 +10,10 @@ Confirm your mobile number – GOV.UK Notify

Confirm your mobile number

-

We've sent you a confirmation code by text message.

+

We’ve sent you a security code by text message.

-

diff --git a/tests/app/main/views/test_code_not_received.py b/tests/app/main/views/test_code_not_received.py index 271b6ee81..f7d5f89a7 100644 --- a/tests/app/main/views/test_code_not_received.py +++ b/tests/app/main/views/test_code_not_received.py @@ -42,7 +42,7 @@ def test_should_render_correct_resend_template_for_active_user(app_, assert response.status_code == 200 page = BeautifulSoup(response.data.decode('utf-8'), 'html.parser') - assert page.h1.string == 'Resend verification code' + assert page.h1.string == 'Resend security code' # there shouldn't be a form for updating mobile number assert page.find('form') is None diff --git a/tests/app/main/views/test_two_factor.py b/tests/app/main/views/test_two_factor.py index 367941c28..cf234483f 100644 --- a/tests/app/main/views/test_two_factor.py +++ b/tests/app/main/views/test_two_factor.py @@ -17,7 +17,7 @@ def test_should_render_two_factor_page(app_, 'email': api_user_active.email_address} response = client.get(url_for('main.two_factor')) assert response.status_code == 200 - assert '''We’ve sent you a text message with a verification code.''' in response.get_data(as_text=True) + assert '''We’ve sent you a text message with a security code.''' in response.get_data(as_text=True) def test_should_login_user_and_redirect_to_service_dashboard(app_, diff --git a/tests/app/main/views/test_verify.py b/tests/app/main/views/test_verify.py index 2a7599890..4aaab069b 100644 --- a/tests/app/main/views/test_verify.py +++ b/tests/app/main/views/test_verify.py @@ -18,7 +18,7 @@ def test_should_return_verify_template(app_, page = BeautifulSoup(response.data.decode('utf-8'), 'html.parser') assert page.h1.text == 'Check your phone' message = page.find_all('p')[1].text - assert message == "We’ve sent you a text message with a verification code." + assert message == "We’ve sent you a text message with a security code." def test_should_redirect_to_add_service_when_sms_code_is_correct(app_, From 8cca2ef2350d215c604cb62c204d8795abf391a0 Mon Sep 17 00:00:00 2001 From: Chris Hill-Scott Date: Mon, 22 Aug 2016 10:18:42 +0100 Subject: [PATCH 3/4] Lose the 'now' in the 'check your email' title --- app/templates/views/registration-continue.html | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/templates/views/registration-continue.html b/app/templates/views/registration-continue.html index 6a8c472cb..ab3e54275 100644 --- a/app/templates/views/registration-continue.html +++ b/app/templates/views/registration-continue.html @@ -6,7 +6,7 @@ {% block maincolumn_content %} -

​Now check your email​

+

Check your email​

We’ve sent an email to {{ session['user_details']['email'] }}.

Click the link in the email to continue your registration.

From 78de805b9a762c7f1d2a8bf42e566fc5a2343813 Mon Sep 17 00:00:00 2001 From: Chris Hill-Scott Date: Mon, 22 Aug 2016 10:19:25 +0100 Subject: [PATCH 4/4] Remove and/or from request to go live page We don't use 'and/or' - you should just stick to 'and'. --- app/templates/views/service-settings/request-to-go-live.html | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/app/templates/views/service-settings/request-to-go-live.html b/app/templates/views/service-settings/request-to-go-live.html index cb725f1fb..f25a9baa5 100644 --- a/app/templates/views/service-settings/request-to-go-live.html +++ b/app/templates/views/service-settings/request-to-go-live.html @@ -30,7 +30,7 @@ {{ textbox( form.usage, - label='Estimate how many emails and/or text messages you’ll send each month', + label='Estimate how many emails and text messages you’ll send each month', hint='If your estimate is likely to change, tell us how ', width='1-1', rows=5 @@ -57,7 +57,7 @@ - {{ page_footer('Request to go live') }} + {{ page_footer('Request to go live') }}