Page MenuHomePhabricator

LinkFilter missing api i18n messages
Closed, ResolvedPublic

Description

The extension is using old API message formats, these should be replaced with i18n messages with entries in en.json and qqq.json

As well as message apihelp-linkfilter-description, descriptions for the 2 parameters, and one for the example is necessary

See https://www.mediawiki.org/wiki/API:Localisation for more information. Looking at many other extensions will also provide working examples. Such as https://github.com/wikimedia/mediawiki-extensions-CodeReview/blob/master/api/ApiCodeDiff.php#L73-L95 along with https://github.com/wikimedia/mediawiki-extensions-CodeReview/blob/master/i18n/en.json#L192-L195 and https://github.com/wikimedia/mediawiki-extensions-CodeReview/blob/master/i18n/qqq.json#L218-L221

19:07:52 1) ApiDocumentationTest::testDocumentationExists with data set "Module linkfilter with MiserMode=false, AllowCategorizedRecentChanges=false" ('linkfilter', array(false, false))
19:07:52 Module description message apihelp-linkfilter-description exists
19:07:52 Failed asserting that false is true.
19:07:52 
19:07:52 /srv/jenkins-workspace/workspace/mwext-testextension-php55/src/tests/phpunit/structure/ApiDocumentationTest.php:51
19:07:52 /srv/jenkins-workspace/workspace/mwext-testextension-php55/src/tests/phpunit/structure/ApiDocumentationTest.php:80
19:07:52 /srv/jenkins-workspace/workspace/mwext-testextension-php55/src/tests/phpunit/MediaWikiTestCase.php:399
19:07:52 /srv/jenkins-workspace/workspace/mwext-testextension-php55/src/maintenance/doMaintenance.php:111
19:07:52 
19:07:52 2) ApiDocumentationTest::testDocumentationExists with data set "Module linkfilter with MiserMode=true, AllowCategorizedRecentChanges=true" ('linkfilter', array(true, true))
19:07:52 Module description message apihelp-linkfilter-description exists
19:07:52 Failed asserting that false is true.
19:07:52 
19:07:52 /srv/jenkins-workspace/workspace/mwext-testextension-php55/src/tests/phpunit/structure/ApiDocumentationTest.php:51
19:07:52 /srv/jenkins-workspace/workspace/mwext-testextension-php55/src/tests/phpunit/structure/ApiDocumentationTest.php:80
19:07:52 /srv/jenkins-workspace/workspace/mwext-testextension-php55/src/tests/phpunit/MediaWikiTestCase.php:399
19:07:52 /srv/jenkins-workspace/workspace/mwext-testextension-php55/src/maintenance/doMaintenance.php:111
19:07:52

Event Timeline

Restricted Application added a subscriber: Aklapper. · View Herald Transcript

I will work to fix this to get the other patch merged as soon as possible :)

You might need a bit of back and forth with CI to make the tests to pass, but shouldn't be anything excessive

Change 328024 had a related patch set uploaded (by Divadsn):
LinkFilter missing api i18n messages

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

Patch is on Gerrit, thanks to jenkins-bot I found the mistake that I had forgotten to remove.

Change 328024 merged by jenkins-bot:
LinkFilter missing api i18n messages

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