Page MenuHomePhabricator

Fix and restore daily browser tests for TwoColConflict
Closed, ResolvedPublic

Description

In T232608: Delete selenium-daily-beta-EXTENSION Jenkins jobs that are broken more than 30 days the daily browser tests for TwoColConflict are being reported as broken, and the job being deleted after 30 days. Before going default with the extension we need to restore this safety net.

Acceptance criteria:

  • We understand what failed and fixed it
  • The test run once a day
  • Failing tests send an email to techwish-devs@wikimedia.de

Link to job: https://integration.wikimedia.org/ci/job/selenium-daily-beta-TwoColConflict/


Foes vanquished:

  • patch Use wdio-mediawiki public API rather than peeking at internal files using relative paths.
  • patch Temporarily hide the beta features "save" bar, it has problematic floating behavior and obscures UI elements.
  • patch Disable "2017 wikitext source editor", this doesn't provide a simple ES interface to let us set content.

Details

Related Gerrit Patches:
mediawiki/extensions/TwoColConflict : masterPrevent VisualEditor
mediawiki/extensions/TwoColConflict : master[WIP] set edit box content for VE
mediawiki/extensions/TwoColConflict : masterHide the floating save-bar
mediawiki/extensions/TwoColConflict : masterScroll beta preference into view
integration/config : masterReenable TwoColConflict browser tests
mediawiki/extensions/TwoColConflict : masterUse wdio-mediawiki core wrappers
mediawiki/extensions/TwoColConflict : masterFix browser test

Event Timeline

Let me know when you're ready to work on fixing the tests. I can restore the job and configure it to send failure mails to techwish-devs@wikimedia.de.

Change 540097 had a related patch set uploaded (by Awight; owner: Awight):
[mediawiki/extensions/TwoColConflict@master] Fix browser test

https://gerrit.wikimedia.org/r/540097

Change 540098 had a related patch set uploaded (by Awight; owner: Awight):
[integration/config@master] Reenable TwoColConflict browser tests

https://gerrit.wikimedia.org/r/540098

Change 540105 had a related patch set uploaded (by Awight; owner: Awight):
[mediawiki/extensions/TwoColConflict@master] Use wdio-mediawiki core wrappers

https://gerrit.wikimedia.org/r/540105

Change 540097 abandoned by Awight:
Fix browser test

https://gerrit.wikimedia.org/r/540097

awight claimed this task.Oct 1 2019, 1:19 PM

Change 540105 merged by jenkins-bot:
[mediawiki/extensions/TwoColConflict@master] Use wdio-mediawiki core wrappers

https://gerrit.wikimedia.org/r/540105

zeljkofilipin triaged this task as Normal priority.Oct 2 2019, 1:57 PM

We understand what failed and fixed it

According to T199113, the problem was:

selenium-daily-beta-TwoColConflict fails with ERROR: Cannot find module '../../../../../tests/selenium/pageobjects/edit.page'

It was probably fixed here:

https://gerrit.wikimedia.org/r/c/mediawiki/extensions/TwoColConflict/+/540105/5/tests/selenium/pageobjects/editconflict.page.js

Change 540098 merged by jenkins-bot:
[integration/config@master] Reenable TwoColConflict browser tests

https://gerrit.wikimedia.org/r/540098

selenium-daily-beta-TwoColConflict job is deployed.

It is failing:

...
+ npm run-script selenium-daily
...
Number of specs: 5


0 passing (57.80s)
5 failing
...

Instructions on how to target beta cluster (as the job does) is available at Selenium/Node.js/Target beta cluster.

Let me know if you have any questions or need help fixing the failures.

Change 540425 had a related patch set uploaded (by Awight; owner: Awight):
[mediawiki/extensions/TwoColConflict@master] Scroll beta preference into view

https://gerrit.wikimedia.org/r/540425

awight added a comment.Oct 4 2019, 7:43 AM

This might be fixed once we merge:

https://gerrit.wikimedia.org/r/540425 is the only patch open here. It seems it fails because it uses a Webdriverio version 5 feature, but we aren't on version 5 yet. @zeljkofilipin, is there a backwards-compatible method we can use instead of scrollIntoView? Or are we able to update to version 5 within the next days?

awight added a comment.EditedOct 4 2019, 7:50 AM

https://gerrit.wikimedia.org/r/540425 is the only patch open here. It seems it fails because it uses a Webdriverio version 5 feature, but we aren't on version 5 yet. @zeljkofilipin, is there a backwards-compatible method we can use instead of scrollIntoView? Or are we able to update to version 5 within the next days?

I don't think this is quite right. scrollIntoView is well-supported by browsers: https://developer.mozilla.org/en-US/docs/Web/API/Element/scrollIntoView . Maybe I need to wrap my code in browser.execute, but I think it actually works as I've written it, since I'm running wdio 4 and it passes for me.

awight added a comment.Oct 4 2019, 9:05 AM

There was a wdio 4 function after all, patch has been updated.
http://v4.webdriver.io/api/protocol/moveTo.html

Ready for final review.

Change 540425 merged by jenkins-bot:
[mediawiki/extensions/TwoColConflict@master] Scroll beta preference into view

https://gerrit.wikimedia.org/r/540425

selenium-daily-beta-TwoColConflict is still failing, now with TwoColConflict "before all" hook: invalidjson: No valid JSON response

Change 541197 had a related patch set uploaded (by Awight; owner: Awight):
[mediawiki/extensions/TwoColConflict@master] Hide the floating save-bar

https://gerrit.wikimedia.org/r/541197

Change 541197 merged by jenkins-bot:
[mediawiki/extensions/TwoColConflict@master] Hide the floating save-bar

https://gerrit.wikimedia.org/r/541197

Change 541255 had a related patch set uploaded (by Awight; owner: Awight):
[mediawiki/extensions/TwoColConflict@master] [WIP] set edit box content for VE

https://gerrit.wikimedia.org/r/541255

Change 541256 had a related patch set uploaded (by Awight; owner: Awight):
[mediawiki/extensions/TwoColConflict@master] [WIP] Set content under VE

https://gerrit.wikimedia.org/r/541256

Change 541255 abandoned by Awight:
[WIP] set edit box content for VE

https://gerrit.wikimedia.org/r/541255

awight updated the task description. (Show Details)Oct 9 2019, 12:04 PM

Change 541256 merged by jenkins-bot:
[mediawiki/extensions/TwoColConflict@master] Prevent VisualEditor

https://gerrit.wikimedia.org/r/541256

awight updated the task description. (Show Details)Oct 9 2019, 1:09 PM
awight removed a project: Patch-For-Review.
thiemowmde closed this task as Resolved.Oct 9 2019, 2:09 PM