← Back to team overview

mahara-contributors team mailing list archive

[Bug 1708335] [NEW] false fails in behat tests occuring after "I scroll to" steps?

 

Public bug reported:

I noticed that the automated tests often flake out at the same lines:
98/179 of resume_page.feature
37/49 of social_media_buttons.feature
What these lines have in common is that they follow an "I scroll to..." step in the test. I wondered whether this was because the next step was trying to execute before the scroll finished, and from looking at the code, the scroll step doesn't run through the spin function, so maybe that's why we get fails??

Anyway to test that theory, I did some digging into implementing a wait
in that scenario and discovered Mink has a wait function that takes a
timeout and a javascript function. I've tested it and it seems to work,
so will push up changes for other people to try out to see if it makes
the scroll step more robust.

** Affects: mahara
     Importance: Undecided
     Assignee: Rebecca Blundell (rjb-dev)
         Status: In Progress


** Tags: behat

** Changed in: mahara
       Status: New => In Progress

** Changed in: mahara
     Assignee: (unassigned) => Rebecca Blundell (rjb-dev)

-- 
You received this bug notification because you are a member of Mahara
Contributors, which is subscribed to Mahara.
Matching subscriptions: Subscription for all Mahara Contributors -- please ask on #mahara-dev or mahara.org forum before editing or unsubscribing it!
https://bugs.launchpad.net/bugs/1708335

Title:
  false fails in behat tests occuring after "I scroll to" steps?

Status in Mahara:
  In Progress

Bug description:
  I noticed that the automated tests often flake out at the same lines:
  98/179 of resume_page.feature
  37/49 of social_media_buttons.feature
  What these lines have in common is that they follow an "I scroll to..." step in the test. I wondered whether this was because the next step was trying to execute before the scroll finished, and from looking at the code, the scroll step doesn't run through the spin function, so maybe that's why we get fails??

  Anyway to test that theory, I did some digging into implementing a
  wait in that scenario and discovered Mink has a wait function that
  takes a timeout and a javascript function. I've tested it and it seems
  to work, so will push up changes for other people to try out to see if
  it makes the scroll step more robust.

To manage notifications about this bug go to:
https://bugs.launchpad.net/mahara/+bug/1708335/+subscriptions


Follow ups