Skip to content

Commit

Permalink
[#2111] Fix failing zoomFeature cypress test (#2114)
Browse files Browse the repository at this point in the history
Fix nondeterministically failing zoomFeature cypress test

The "range changes in chartview should reflect in zoom" test in
chartView_zoomFeature.cy.js fails because as time passes, the
coordinates in the ramp that correspond to the desired zoom area
change.

Let's add an "until" filter to the relevant cypress tests to stop this
from happening
  • Loading branch information
jonasongg authored Feb 16, 2024
1 parent 945405a commit 9ff7a96
Showing 1 changed file with 11 additions and 0 deletions.
11 changes: 11 additions & 0 deletions frontend/cypress/tests/chartView/chartView_zoomFeature.cy.js
Original file line number Diff line number Diff line change
Expand Up @@ -251,6 +251,9 @@ describe('range changes in chartview should reflect in zoom', () => {
cy.get('div.mui-textfield.search_box > input:visible')
.should('be.visible')
.type('jamessspanggg');
cy.get('input[name="until"]:visible')
.type('2023-12-31');

cy.get('body').type(zoomKey, { release: false })
.get('#summary-charts .summary-chart__ramp .ramp')
.first()
Expand All @@ -277,6 +280,9 @@ describe('range changes in chartview should reflect in zoom', () => {
cy.get('div.mui-textfield.search_box > input:visible')
.should('be.visible')
.type('jamessspanggg');
cy.get('input[name="until"]:visible')
.type('2023-12-31');

cy.get('body').type(zoomKey, { release: false })
.get('#summary-charts .summary-chart__ramp .ramp')
.first()
Expand All @@ -303,6 +309,9 @@ describe('range changes in chartview should reflect in zoom', () => {
cy.get('div.mui-textfield.search_box > input:visible')
.should('be.visible')
.type('jamessspanggg');
cy.get('input[name="until"]:visible')
.type('2023-12-31');

cy.get('body').type(zoomKey, { release: false })
.get('#summary-charts .summary-chart__ramp .ramp')
.first()
Expand All @@ -329,6 +338,8 @@ describe('range changes in chartview should reflect in zoom', () => {
cy.get('div.mui-textfield.search_box > input:visible')
.should('be.visible')
.type('jamessspanggg');
cy.get('input[name="until"]:visible')
.type('2023-12-31');

cy.get('body').type(zoomKey, { release: false })
.get('#summary-charts .summary-chart__ramp .ramp')
Expand Down

0 comments on commit 9ff7a96

Please sign in to comment.