Skip to content

Commit

Permalink
[QOL-9055] add scenario test for public reporting
Browse files Browse the repository at this point in the history
  • Loading branch information
ThrawnCA committed Sep 1, 2022
1 parent 2a01913 commit e53cc5e
Showing 1 changed file with 23 additions and 0 deletions.
23 changes: 23 additions & 0 deletions test/features/reporting.feature
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
@OpenData
@reporting
Feature: Reporting

@unauthenticated
Scenario: I can view a 'Broken Links' report anonymously
Given "Unauthenticated" as the persona
When I visit "/report"
And I click the link with text that contains "Broken links"
Then I should see an element with xpath "//select[@name='organization']"
And I should see an element with xpath "//table[@id='report-table']//th[contains(string(), 'Broken datasets')]"
And I should see an element with xpath "//table[@id='report-table']//th[contains(string(), 'Broken links')]"
And I should see an element with xpath "//table[@id='report-table']//td[position()=1]/a[contains(@href, 'report/broken-links') and contains(string(), 'Test Organisation')]"

@unauthenticated
Scenario: I can view a 'Data Usability Rating' report anonymously
Given "Unauthenticated" as the persona
When I visit "/report"
And I click the link with text that contains "Data usability rating"
Then I should see an element with xpath "//select[@name='organization']"
And I should see an element with xpath "//table[@id='report-table']//th[contains(string(), 'Score TBC')]"
And I should see an element with xpath "//table[@id='report-table']//th[contains(string(), 'Average score')]"
And I should see an element with xpath "//table[@id='report-table']//td[position()=1]/a[contains(@href, 'report/openness') and contains(string(), 'Test Organisation')]"

0 comments on commit e53cc5e

Please sign in to comment.