Skip to content

Commit

Permalink
chore: use cy.containsExact helper to select filter button
Browse files Browse the repository at this point in the history
  • Loading branch information
HendrikThePendric committed Dec 18, 2024
1 parent d812e53 commit 6686ed1
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion cypress/e2e/common/add_a_FILTERTYPE_filter.js
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ const OU_ID = 'ImspTQPwCqd' //Sierra Leone
const FACILITY_TYPE = 'Clinic'

When('I add a {string} filter', (dimensionType) => {
cy.contains('Filter').click()
cy.containsExact('Filter').click()

// select an item in the modal
switch (dimensionType) {
Expand Down
2 changes: 1 addition & 1 deletion cypress/e2e/filter_restrict/filter_restrict.js
Original file line number Diff line number Diff line change
Expand Up @@ -168,7 +168,7 @@ Scenario: I restrict filters to no dimensions and do not see Add Filter in dashb
*/

Then('Add Filter button is not visible', () => {
cy.contains('Filter').should('not.exist')
cy.containsExact('Filter').should('not.exist')
})

When('I delete the dashboard', () => {
Expand Down
2 changes: 1 addition & 1 deletion cypress/e2e/view_errors/item_chart_fails_to_render.js
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ Given('I open a dashboard with a chart that will fail', () => {
When(
'I apply a {string} filter of type {string}',
(dimensionType, filterName) => {
cy.contains('Filter').click()
cy.containsExact('Filter').click()
cy.get(filterDimensionsPanelSel).contains(dimensionType).click()
cy.get(dimensionsModalSel, EXTENDED_TIMEOUT).should('be.visible')

Expand Down

0 comments on commit 6686ed1

Please sign in to comment.