From d1449a26ad7f9557529e3d7774e9503c4b0e465f Mon Sep 17 00:00:00 2001 From: Rebecca Law Date: Fri, 3 Feb 2017 10:35:35 +0000 Subject: [PATCH] Use table instead of lists. Edits to contents. --- app/templates/views/integration_testing.html | 127 ++++++++++++++----- 1 file changed, 95 insertions(+), 32 deletions(-) diff --git a/app/templates/views/integration_testing.html b/app/templates/views/integration_testing.html index 9c9627df1..fa6fec5bc 100644 --- a/app/templates/views/integration_testing.html +++ b/app/templates/views/integration_testing.html @@ -1,3 +1,4 @@ +{% from "components/table.html" import mapping_table, row, text_field, edit_field, field %} {% extends "withoutnav_template.html" %} {% block page_title %} @@ -11,22 +12,34 @@

Integration testing

- Service teams should do all their testing within the GOV.UK Notify production environment, https://api.notifications.service.gov.uk. -

-

- You don’t need different Notify accounts or access to other Notify environments. Instead, there are different types of API keys that let you do functional or performance integration testing. + There are different types of API keys that let you do functional or performance integration testing. + You don’t need different GOV.UK Notify accounts or access to other GOV.UK Notify environments.

Types of API Keys

-

- There are 3 types of API key available within GOV.UK Notify: -

- +
+ {% call mapping_table( + caption='Test numbers/address that generate error responses', + field_headings=['Label', 'Value'], + field_headings_visible=False, + caption_visible=False + ) %} + {% call row() %} + {{ text_field('Live') }} + {{ text_field('sends to anyone') }} + {% endcall %} + {% call row() %} + {{ text_field('Team and whitelist') }} + {{ text_field('limits who you can send to') }} + {% endcall %} + + {% call row() %} + {{ text_field('Test') }} + {{ text_field('pretends to send messages') }} + {% endcall %} + {%endcall%} +

Live key

Once your service is live you are able to create Live keys. You can then use these keys to send messages to anyone. @@ -35,26 +48,27 @@ Messages sent with a live key show up on your dashboard and count against your text message and email allowances.

- You should plan to rotate these keys on a regular basis. You can have more than one active key at a time. To revoke a key click the revoke button on the API Key page. + You should revoke and re-create these keys on a regular basis. You can have more than one active key at a time. To revoke a key click the revoke button on the API Key page.

-

Team key

+

Team and whitelist key

- Use a team key for end-to-end functional testing. + Use a team and whitelist key for end-to-end functional testing.

- A team key lets you send real messages to members of your team and address/numbers that you have added to your whitelist. You will get an error if you use these keys to send messages to anyone else. + A team and whitelist key lets you send real messages to members of your team and addresses/numbers that you have added to your whitelist. You will get an error if you use these keys to send messages to anyone else.

- Messages sent with a team key show up on your dashboard and count against your text message and email allowances. + Messages sent with a team and whitelist key show up on your dashboard and count against your text message and email allowances.

Test key

- Use a test key to test the performance of your service and its integration with GOV.UK Notify under load. + Use a test key to test the performance of your service and its integration with GOV.UK Notify.

- Test keys don’t send real messages but do generates realistic responses. There’s no restriction on who you can send to or how many messages you can send per day. + Test keys don’t send real messages but do generates realistic responses. + There’s no restriction on who you can send to.

Messages sent using a test key don’t show up on your dashboard or count against your text message and email allowances. @@ -63,23 +77,72 @@ By default, all messages sent with a test key will result in a delivered status.

- If you want to test failure statuses with a test key, use the following phone numbers and email addresses: + If you want to test failure responses with a test key, use the following numbers and addresses: +

-
  • "07700900003" => temporary failure
  • -
  • "07700900002" => permanent failure
  • -
  • "temp-fail@simulator.notify" => temporary failure
  • -
  • "perm-fail@simulator.notify" => permanent failure
  • + {% call mapping_table( + caption='Test numbers/address that generate error responses', + field_headings=['Label', 'Value', 'Action'], + field_headings_visible=False, + caption_visible=False + ) %} + {% call row() %} + {{ text_field('07700900003') }} + {{ text_field('temporary failure') }} + {% endcall %} + {% call row() %} + {{ text_field('07700900002') }} + {{ text_field('permanent failure') }} + {% endcall %} + {% call row() %} + {{ text_field('temp-fail@simulator.notify') }} + {{ text_field('temporary failure') }} + {% endcall %} + {% call row() %} + {{ text_field('perm-fail@simulator.notify') }} + {{ text_field('permanent failure') }} + {% endcall %} + {% call row() %} + {{ text_field('any other valid number or address') }} + {{ text_field('delivered') }} + {% endcall %} + {% endcall %} + +

    Smoke testing your integration

    - If you need to smoke test your integration with Notify on a regular basis, you should use the smoke test numbers and addresses below. -

  • “07700900000”
  • -
  • “07700900111”
  • -
  • “07700900222”
  • -
  • “simulate-delivered@notifications.service.gov.uk”
  • -
  • “simulate-delivered-2@notifications.service.gov.uk”
  • -
  • “simulate-delivered-3@notifications.service.gov.uk”
  • + If you need to smoke test your integration with GOV.UK Notify on a regular basis, you should use the smoke test numbers and addresses below. +
    + {% call mapping_table( + caption='Test numbers/address that generate error responses', + field_headings=['Label'], + field_headings_visible=False, + caption_visible=False + ) %} + {% call row() %} + {{ text_field('07700900111') }} + {% endcall %} + {% call row() %} + {{ text_field('07700900222') }} + {% endcall %} + {% call row() %} + {{ text_field('07700900333') }} + {% endcall %} + {% call row() %} + {{ text_field('simulate-delivered@notifications.service.gov.uk') }} + {% endcall %} + {% call row() %} + {{ text_field('simulate-delivered-2@notifications.service.gov.uk') }} + {% endcall %} + + {% call row() %} + {{ text_field('simulate-delivered-3@notifications.service.gov.uk') }} + {% endcall %} + {% endcall %} +
    +

    The smoke test numbers and addresses will immediately return a successful response, but won’t send a real message and won’t produce a delivery receipt. @@ -87,7 +150,7 @@

    You can use the smoke test numbers and addresses with any type of key. - If your smoke tests need to fetch a delivery receipt, then use a test key - and don’t use these numbers and addresses. + If your smoke tests need to get the status of a message, then use a test key and don’t use these numbers and addresses.