On the beta cluster, the browser test should pass.
Add a new test to reflect the two different states.
Bug: T157165
Change-Id: I2a777436dfa3a14d58855449c39cc144b7149a62
This previously passed with a false positive as it replicated
the scenario `ReadMore is not present in minerva stable` by running
on the mobile domain.
This change makes it run on the desktop domain and pass (it now
fails given it runs on Minerva skin)
Bug: T157165
Change-Id: Idb2002b0f2d378cc0b6df73ad1381bfee32448c9
The ReadMore checkbox on the beta preferences page doesn't have an ID
anymore. It has a name though, which is used from now on.
The regression was introduced in I8636f32330e23814ba3b4c0f5e22e55aaf77883e.
Bug: T148856
Change-Id: Ieb20c8d9e97d53e6afae3a9fc99ce4dea471b0b5
Introduce a new config variable `RelatedArticlesFooterBlacklistedSkins`
to control skins that are allowed to show ReadMore in the footer.
As before Minerva beta mode is always allowed to show.
Depends-on: I366c8656a0f14a7069053b2e6199caac20471ea4
Depends-on: Ie4ac3c11e81eeea9f5b4a7161a64477cb5d60f07
Bug: T144047
Change-Id: I1663ab25083d9d907f288e60d506831bebb67945
This old classic returns again.
A browser test fails when this is not enabled as it asserts that
the user is in beta.
Bug: T120715
Change-Id: I2c5339ba959318a3b995a28e22f3df375ae53103
The ParserOutput object is already reset when state is reset, so there's no
point in setting or unsetting properties on it.
And since the only unit test was deleted, remove the hook for that too.
Change-Id: Idf12365e8c4b14e527d923edc1086bdaf349df32
selenium* jobs are a new way of running Ruby based Selenium tests. The
jobs are triggered daily.
Bug: T128190
Change-Id: I02fc3e8542d732ca728f47316a8e183ed28744e7
Until T128190 is resolved, we can not run both mobile and desktop job
daily. Since there are 3 mobile and only 1 desktop scenario, run mobile
job until running desktop jobs is possible.
Bug: T128084
Change-Id: I13eba1c2a4f33f8e88c8bc1a000914e65322b9cc
Tests now run fine on my local machine and at beta cluster. Please
notice that the first three scenarios run at mobile site, and the fourth
one runs at desktop site.
Bug: T120715
Change-Id: Ib57f48b01d909915ae44976aa51824b4530ffffc
The job requires features/scenarios tagged with environment
(@en.m.wikipedia.beta.wmflabs.org) and browser (@chrome) to run
properly.
I did not tag the last scenario, since it failed.
Bug: T126589
Change-Id: Ib99c50657f7a68d0b00048aac96c2f2892e89713
Introduce the rake test entry point which is invoked by CI.
Add a basic rubocop configuration based on
https://www.mediawiki.org/wiki/Manual:Coding_conventions/Ruby
Fix up a few ruby issues.
Bug: T120715
Change-Id: I3df0a3b13155259ec6cb5010e7aaa3bf9aa7b230
I33936a3 didn't introduce a regression but highlighted an issue with the
fixture in the RelatedPagesGateway unit test: the fixture is in the
legacy JSON format despite the API request URL including
formatversion=2.
Change-Id: Id372d022625d88eea685267ea6b6484cf6b28cbc
RelatedArticles tries to load the 'ext.cards' module and if
it succeeds it continues with showing the related articles
on the page.
Dependency: I6661527175eb889cec4193b18fa18207f332b4fc
Bug: T117108
Change-Id: I33936a3e9cd5d1f0296e48fd1c2bba77fff4e466
Leave all public-facing uses of "article" (including classes) because
the extension is remaining named RelatedArticles. Replace all other
instances with "page" for consistency with other extensions.
Bug: T117908
Change-Id: Ib0f258f26b0d11cfe8a598dbd90ff37afbbe36ac
By default, the Read More feature tries to use editor-curated articles
before using the CirrusSearch morelike: feature. Add a configuration
variable that disables the former behaviour but leave the default in
place.
Changes:
* Add the wgReadMoreOnlyUseCirrusSearch configuration variable, which
defaults to false, and pass it in to
mw.relatedArticles.RelatedPagesGateway at construction time
* Add the onlyUseCirrusSearch parameter to
mw.relatedArticles.RelatedPagesGateway, which controls whether to
ignore the editorCuratedArticles parameter
Bug: T117443
Change-Id: I0dfa67f4a68e8dc17302fef7ebf8d23c0c1d892c
When no related articles have been specified by an editor we instead
hit request pages similar to the current page using the CirrusSearch
extension's "morelike:" feature [0].
Changes:
* Config variable introduced RelatedArticlesUseCirrusSearch which allows
you to turn on use of the CirrusSearch API.
* Introduce a RelatedPagesGateway for dealing with making the API call
and returning consistent results
* Move the "simple" API call for hydrating related pages fetched from
the wgRelatedArticles configuration variable into RelatedPagesGateway
* Reduce the bootstrap module to just a bootstrap module!
Bug: T116707
Change-Id: Ia0ced1d7ae57c0939d1f5af275aa9d393f1420b1
While the related parser function sets the accumulated related pages as
extension data on the parser output
(see RelatedArticles\Hooks::onFuncRelated). The ParserClearState
handler, however, sets the empty list as a property, which is then
stored in the DB.
Changes:
* Make RelatedArticles\Hooks::onParserClearState use
ParserOutput#setExtensionData, mirroring ::onFuncRelated
* Add a unit test for the the handler
Bug: T115698
Change-Id: I3deaf1e8ee78944250c3f26315ee2450b444a035