Add a test for the ‘available for 7 days’ text

So that we can check it’s still correct when we make it dynamic.
This commit is contained in:
Chris Hill-Scott
2016-07-18 08:39:10 +01:00
parent cfadead292
commit 55902d2927
2 changed files with 2 additions and 1 deletions

View File

@@ -8,7 +8,7 @@
<p class="bottom-gutter">
<a href="{{ url_for('.view_job_csv', service_id=current_service.id, job_id=job.id, status=status) }}" download="download" class="heading-small">Download this report</a>
&emsp;
Available for 7 days
<span id="time-left">Available for 7 days</span>
</p>
{% endif %}

View File

@@ -98,6 +98,7 @@ def test_should_show_page_for_one_job(
status=status_argument
)
assert csv_link.text == 'Download this report'
assert page.find('span', {'id': 'time-left'}).text == 'Available for 7 days'
mock_get_notifications.assert_called_with(
service_one['id'],
fake_uuid,