Page MenuHomePhabricator

Create unit tests for URL manipulation in RCFilters
Closed, ResolvedPublic

Description

Find a way to test the mw.Uri parameter manipulation and validation in RCFilters.

Event Timeline

Change 357124 had a related patch set uploaded (by Mooeypoo; owner: Mooeypoo):
[mediawiki/core@master] RCFilters: Add UriProcessor and unit tests for URL manipulations

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

Change 357116 had a related patch set uploaded (by Catrope; owner: Mooeypoo):
[mediawiki/core@master] RCFilters: Make frontend URL follow backend rules and add 'urlversion=2'

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

Change 357124 abandoned by Catrope:
RCFilters: Add UriProcessor and unit tests for URL manipulations

Reason:
Squashed into https://gerrit.wikimedia.org/r/#/c/357116

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

Change 357116 merged by jenkins-bot:
[mediawiki/core@master] RCFilters: Make frontend URL follow backend rules and add 'urlversion=2'

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

Checked in betalabs - especially the following cases: 'Highlight parameters in Uri query set highlight state in the model',
'Parameters in Uri query set parameter value in the model''Invert parameter in Uri query set invert state in the model'

The filter sets with highlighting (both - when filters are selected and not selected) and inverted (also with highlighting and selected/not selected filters) can be copied/bookmarked successfully.

Note: even the edge test case is working:

  • a user does not have enabled RC filters, but receives a url where invert and highlight were used.
  • pastes the url in browser address bar and sees default
  • saves it as a bookmark
  • enables RC filters
  • invoke the saved bookmark and sees highlight/invert/selected or not selected (highlight only) filters.
Etonkovidova closed this task as Resolved.Jul 14 2017, 6:10 PM