Page MenuHomePhabricator

Write selenium tests for CheckUser
Open, Needs TriagePublicFeature

Description

Currently there exists no front-end browser tests for CheckUser. Due to the added complexity of testing for correct page output using phpunit, using selenium (which is built for testing the page that is sent to the browser) will allow the automated testing of whether the user can use the special pages implemented by CheckUser. This will also likely need some test data that can be preloaded into the CheckUser table and also likely a reset of the DB on every test as events (such as logins) will affect the data seen by the next test.

Event Timeline

Change 833468 had a related patch set uploaded (by Dreamy Jazz; author: Dreamy Jazz):

[mediawiki/extensions/CheckUser@master] Start on selenium tests for browser side testing of CheckUser

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

Change 833468 merged by jenkins-bot:

[mediawiki/extensions/CheckUser@master] Start on selenium tests for browser side testing of CheckUser

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

I'm assuming you were following the documentation or sample code I wrote (and forgot to update), but we've switched from sync to async mode for selenium tests (because of upstream changes). See T256626 for details. It would be great if you moved to async mode while there isn't much code. Let me know if you need help or reviews.

Change 850611 had a related patch set uploaded (by Dreamy Jazz; author: Dreamy Jazz):

[mediawiki/extensions/CheckUser@master] Selenium: Allow tests to grant checkuser group and some more tests

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

Writing most of the tests is blocked on being able to have an account that has the checkuser group. Doing that is detailed in a subtask.