Summary: | administration_tasks.t is failing randomly | ||
---|---|---|---|
Product: | Koha | Reporter: | Victor Grousset/tuxayo <victor> |
Component: | Test Suite | Assignee: | Victor Grousset/tuxayo <victor> |
Status: | Patch doesn't apply --- | QA Contact: | Testopia <testopia> |
Severity: | normal | ||
Priority: | P5 - low | CC: | jonathan.druart, lucas, mtj, tomascohen |
Version: | Main | ||
Hardware: | All | ||
OS: | All | ||
GIT URL: | Change sponsored?: | --- | |
Patch complexity: | --- | Documentation contact: | |
Documentation submission: | Text to go in the release notes: | ||
Version(s) released in: | Circulation function: | ||
Attachments: |
Bug 28647: Selenium lib: make error handler fail gracefully
Bug 28647: Wait for elements to load + do twice an unreliable operation |
Description
Victor Grousset/tuxayo
2021-07-02 03:05:26 UTC
I can reproduce. I'm trying stuff like adding finds before so it waits for an element to be here before continuing. But haven't found yet something that actually works when retrying a lot of times. For some reason, sometimes $driver->get($mainpage); doesn't do anything and we can wait as much as we want and we won't be on the mainpage outrageous fix: $driver->get($mainpage); $driver->get($mainpage); It should still eventually fail but the probability will be: once in "a few dozen times" x "a few dozen times" So much lower :D Created attachment 122624 [details] [review] Bug 28647: Selenium lib: make error handler fail gracefully Quitting the driver makes all the next use of Selenium in the file fail. And go to te error handler where it fails again and goes to the error handler. Now it just fails the current test and continues. I don't know how this wasn't an issue in the previous work on the test suite. Created attachment 122625 [details] [review] Bug 28647: Wait for elements to load + do twice an unreliable operation Confirmed by 1000 passing runs. After testing: removing any of the 3 fixes almost surely causes a fail in less than 200 runs. How to recreate the failure? Running prove t/db_dependent/selenium/administration_tasks.t in a loop without the patches. And hope that on your machine there isn't a too low probability of failure. Sadly this no longer applies to current master. |