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

Flaky e2e test: Default navigation hamburger menu spec failing: Hamburger Menu tests "before all" hook #8692

Closed
lorerod opened this issue Nov 9, 2023 · 0 comments · Fixed by #8696
Assignees
Labels
Flaky Indicates a flaky or unreliable test Testing Affects how the code is tested Type: Technical issue Improve something that users won't notice
Milestone

Comments

@lorerod
Copy link
Contributor

lorerod commented Nov 9, 2023

Describe the issue
This test is failing very frequently across multiple builds.

Error in "Hamburger Menu tests."before all" hook for "should open About""
Error: element ("#header-dropdown-link") still not displayed after 40000ms
    at async waitForAngularLoaded (/home/runner/work/cht-core/cht-core/tests/page-objects/default/common/common.wdio.page.js:285:3)
    at async waitForPageLoaded (/home/runner/work/cht-core/cht-core/tests/page-objects/default/common/common.wdio.page.js:291:3)
    at async Object.goToBase (/home/runner/work/cht-core/cht-core/tests/page-objects/default/common/common.wdio.page.js:203:3)
    at async Object.cookieLogin (/home/runner/work/cht-core/cht-core/tests/page-objects/default/login/login.wdio.page.js:59:3)
    at async Context.<anonymous> (/home/runner/work/cht-core/cht-core/tests/e2e/default/navigation/hamburger-menu.wdio-spec.js:6:5)
[0-6] FAILED in chrome - file:///tests/e2e/default/login/login-logout.wdio-spec.js, file:///tests/e2e/default/navigation/navigation.wdio-spec.js, file:///tests/e2e/default/navigation/hamburger-menu.wdio-spec.js

Describe the improvement you'd like
Fix it

@lorerod lorerod added Type: Technical issue Improve something that users won't notice Testing Affects how the code is tested Flaky Indicates a flaky or unreliable test labels Nov 9, 2023
@lorerod lorerod self-assigned this Nov 9, 2023
@latin-panda latin-panda added this to the 4.5.0 milestone Nov 15, 2023
@latin-panda latin-panda linked a pull request Nov 15, 2023 that will close this issue
5 tasks
lorerod added a commit that referenced this issue Nov 15, 2023
* Move the failing code out of the before to get a screenshot

* Move before each code to each test to get a screnshot

* Move goToReports to afterEach hook

* Change tests setup

* Change setup of default mobile specs

* Delete async from describe

* Remove oldLogout and oldCloseReloadModal since 4.4 is released

* Set shouldUpdate to true when using new CloseReloadModal

* Wait for page to load after cookie login

* Since not able to reproduce locally, only test upgrade to get a screenshot

* Add close reload modal after go to Abour. As per screenshot the reload modal is blocking the version

* Back to old close reload modal

* Add test id to about version element

* Revert "Add test id to about version element"

This reverts commit 359b7f3.

* Revert "Back to old close reload modal"

This reverts commit e0d37e1.

* Revert "Add close reload modal after go to Abour. As per screenshot the reload modal is blocking the version"

This reverts commit 7140b79.

* Revert "Since not able to reproduce locally, only test upgrade to get a screenshot"

This reverts commit d772113.

* Revert "Wait for page to load after cookie login"

This reverts commit 156e0a7.

* Use old close reload modal

* Change about version selector

* Add a test-id to retrieve about version element

* Reload app on about page

* Add go to base url before login

* Wait for page to Load

* remove a bunch more describe asyncs

* remove before function to get screenshot and better logging

* try a backwards compatible version selector

* Revert "try a backwards compatible version selector"

This reverts commit af76974.

* Add sync step

* Use new closeReloadModal after login

* Wait for page to load, close reload modal and, wait again for page to load

* Use old close reload modal

* Try to close old reload modal after going to about page

* Add new close reload modal

* Move afterEach from online Describe to first test

* Add after on second test also

* Restore changes before removing before function

* Get rid of breaks

* Add browser.refresh and sync to try to load the updated About Page

* wait for sw generation

* comment out slow running builds - revert before merging

* clarify found logs message

* refresh AFTER sync

* eslnit

* optimistically remove browser pause

* Revert "comment out slow running builds - revert before merging"

This reverts commit cf66af8.

* Delete unused function

---------

Co-authored-by: Maria Lorena Rodriguez Viruel <marialorenarodriguezviruel@MacBook-Pro-de-Maria.local>
Co-authored-by: Gareth Bowen <gareth@bowenwebdesign.co.nz>
1yuv pushed a commit that referenced this issue Nov 16, 2023
* Move the failing code out of the before to get a screenshot

* Move before each code to each test to get a screnshot

* Move goToReports to afterEach hook

* Change tests setup

* Change setup of default mobile specs

* Delete async from describe

* Remove oldLogout and oldCloseReloadModal since 4.4 is released

* Set shouldUpdate to true when using new CloseReloadModal

* Wait for page to load after cookie login

* Since not able to reproduce locally, only test upgrade to get a screenshot

* Add close reload modal after go to Abour. As per screenshot the reload modal is blocking the version

* Back to old close reload modal

* Add test id to about version element

* Revert "Add test id to about version element"

This reverts commit 359b7f3.

* Revert "Back to old close reload modal"

This reverts commit e0d37e1.

* Revert "Add close reload modal after go to Abour. As per screenshot the reload modal is blocking the version"

This reverts commit 7140b79.

* Revert "Since not able to reproduce locally, only test upgrade to get a screenshot"

This reverts commit d772113.

* Revert "Wait for page to load after cookie login"

This reverts commit 156e0a7.

* Use old close reload modal

* Change about version selector

* Add a test-id to retrieve about version element

* Reload app on about page

* Add go to base url before login

* Wait for page to Load

* remove a bunch more describe asyncs

* remove before function to get screenshot and better logging

* try a backwards compatible version selector

* Revert "try a backwards compatible version selector"

This reverts commit af76974.

* Add sync step

* Use new closeReloadModal after login

* Wait for page to load, close reload modal and, wait again for page to load

* Use old close reload modal

* Try to close old reload modal after going to about page

* Add new close reload modal

* Move afterEach from online Describe to first test

* Add after on second test also

* Restore changes before removing before function

* Get rid of breaks

* Add browser.refresh and sync to try to load the updated About Page

* wait for sw generation

* comment out slow running builds - revert before merging

* clarify found logs message

* refresh AFTER sync

* eslnit

* optimistically remove browser pause

* Revert "comment out slow running builds - revert before merging"

This reverts commit cf66af8.

* Delete unused function

---------

Co-authored-by: Maria Lorena Rodriguez Viruel <marialorenarodriguezviruel@MacBook-Pro-de-Maria.local>
Co-authored-by: Gareth Bowen <gareth@bowenwebdesign.co.nz>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Flaky Indicates a flaky or unreliable test Testing Affects how the code is tested Type: Technical issue Improve something that users won't notice
Projects
Status: Done
Development

Successfully merging a pull request may close this issue.

2 participants