mahara-contributors team mailing list archive
-
mahara-contributors team
-
Mailing list archive
-
Message #66823
[Bug 1982041] [NEW] And I scroll to the id "[id]" semi-reliably fails
Public bug reported:
The test that showed me this was the following:
./mahara_behat.sh rundebug site_features/webservices.feature:20
I have been finding line 60 is problematic.
https://git.mahara.org/mahara/mahara/-/blob/main/test/behat/features/site_features/webservices.feature#L60
If I add a breakpoint and stretch the window wide so the Edit button is
visible it is reliable. I also tried it many times without stretching it
out and it works while the breakpoint is in place.
The suspicion is the "And I scroll to the id
"webservices_token_pseudofieldset"" on the line before may not be
scrolling into view at a consistent speed and sometimes it doesn't get
there in time. Looking at the screenshots of the error this is the case.
Potential fixes.
Adding a "And I wait "1" seconds" allows the test to pass reliably.
However, it adds time and only fixes this one instance.
I'm wondering if building the delay into "And I scroll to the id "[id]""
and the other 'scroll into' steps. Adding a check that the requested id
is actually in the viewport here would prevent this issue in all places
making the tests more robust.
https://git.mahara.org/mahara/mahara/-/blob/main/htdocs/testing/frameworks/behat/classes/BehatGeneral.php#L1958
** Affects: mahara
Importance: Undecided
Status: New
** Tags: behat-dev
--
You received this bug notification because you are a member of Mahara
Contributors, which is subscribed to Mahara.
Matching subscriptions: mahara-contributors
https://bugs.launchpad.net/bugs/1982041
Title:
And I scroll to the id "[id]" semi-reliably fails
Status in Mahara:
New
Bug description:
The test that showed me this was the following:
./mahara_behat.sh rundebug site_features/webservices.feature:20
I have been finding line 60 is problematic.
https://git.mahara.org/mahara/mahara/-/blob/main/test/behat/features/site_features/webservices.feature#L60
If I add a breakpoint and stretch the window wide so the Edit button
is visible it is reliable. I also tried it many times without
stretching it out and it works while the breakpoint is in place.
The suspicion is the "And I scroll to the id
"webservices_token_pseudofieldset"" on the line before may not be
scrolling into view at a consistent speed and sometimes it doesn't get
there in time. Looking at the screenshots of the error this is the
case.
Potential fixes.
Adding a "And I wait "1" seconds" allows the test to pass reliably.
However, it adds time and only fixes this one instance.
I'm wondering if building the delay into "And I scroll to the id
"[id]"" and the other 'scroll into' steps. Adding a check that the
requested id is actually in the viewport here would prevent this issue
in all places making the tests more robust.
https://git.mahara.org/mahara/mahara/-/blob/main/htdocs/testing/frameworks/behat/classes/BehatGeneral.php#L1958
To manage notifications about this bug go to:
https://bugs.launchpad.net/mahara/+bug/1982041/+subscriptions