Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

test: add cypress tests for Outlier table DHIS2-17162 #3008

Merged
merged 8 commits into from
Apr 11, 2024

Conversation

edoardo
Copy link
Member

@edoardo edoardo commented Mar 27, 2024

Implements DHIS2-17162


Key features

  1. add Cypress tests for the Outlier table feature

Description

Tests are based on the spec


Screenshots

Screenshot 2024-03-27 at 16 06 06

@edoardo edoardo requested a review from martinkrulltott March 27, 2024 15:07
@dhis2-bot
Copy link
Contributor

dhis2-bot commented Mar 27, 2024

@dhis2-bot dhis2-bot temporarily deployed to netlify March 27, 2024 15:09 Inactive
Copy link

cypress bot commented Mar 27, 2024

1 flaky test on run #2762 ↗︎

0 770 2 0 Flakiness 1

Details:

Merge d171fee into 01f8f3c...
Project: Data Visualizer App Commit: 84ec8aa8d0 ℹ️
Status: Passed Duration: 09:20 💡
Started: Apr 11, 2024 9:30 AM Ended: Apr 11, 2024 9:40 AM
Flakiness  cypress/integration/dimensions/data.cy.js • 1 flaky test • e2e-chrome-parallel-2.41

View Output Video

Test Artifacts
Data dimension > displays Event data items correctly Test Replay Screenshots Video

Review all test suite changes for PR #3008 ↗︎

@dhis2-bot dhis2-bot temporarily deployed to netlify March 27, 2024 17:49 Inactive
@dhis2-bot dhis2-bot temporarily deployed to netlify April 3, 2024 09:00 Inactive
cy.getBySel(dataTypesSelectButtonEl).click()
cy.getBySelLike(dataTypeSelectOptionEl).contains(dataType).click()
cy.getBySel(dataTypesSelectButtonEl).then(($typesSelect) => {
// account for disabled type selector with preselected item
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

In which case is this needed to have?
!$typesSelect.text().includes(dataType) looks over-engineered to me 🤔

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I added a comment, perhaps is not very clear 😅
Basically, when you have only 1 type enabled, the whole select gets disabled with the preselected type, then the actions for selecting the type don't work.
So, the reasoning is, if the type you want is already selected, don't try to select it again, this accounts also for the case of only 1 type available described above.

@dhis2-bot dhis2-bot temporarily deployed to netlify April 8, 2024 08:34 Inactive
@edoardo edoardo force-pushed the test/cypress-for-outlier-table branch from 708e1c8 to d171fee Compare April 11, 2024 09:23
@dhis2-bot dhis2-bot temporarily deployed to netlify April 11, 2024 09:26 Inactive
@edoardo edoardo merged commit db0c6da into dev Apr 11, 2024
21 of 23 checks passed
@edoardo edoardo deleted the test/cypress-for-outlier-table branch April 11, 2024 10:50
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants