lhc/web/wiklou.git
3 years agoDisplay the file sha1 value in the file info page
RazeSoldier [Fri, 29 Dec 2017 14:03:55 +0000 (22:03 +0800)]
Display the file sha1 value in the file info page

When a visitor accesses an info page of an existing file, base-36 sha1 value of this file will displayed in the table of basic information.

Bug: T181651
Change-Id: Ib8cae3e4070a186e28e8625556d3c510af0701c2

3 years agoConvert Preferences class into PreferencesFactory service
Sam Wilson [Tue, 7 Nov 2017 03:10:14 +0000 (11:10 +0800)]
Convert Preferences class into PreferencesFactory service

This deprecates the Preferences class and replaces it with
a PreferencesFactory service. Basically, all code from Preferences
is moved into DefaultPreferencesFactory. All Prefereces methods
are now either shims calling DefaultPreferencesFactory or just
throw exceptions.

Bug: T178449
Change-Id: Id0b2db0c2de0890f6e1609a9a0dca207c4600f99

3 years agoMerge "Add test for DBConnRef"
jenkins-bot [Tue, 2 Jan 2018 22:48:46 +0000 (22:48 +0000)]
Merge "Add test for DBConnRef"

3 years agoOOjs UI: Fix font size for default overlay
Bartosz Dziewoński [Thu, 14 Dec 2017 01:29:19 +0000 (02:29 +0100)]
OOjs UI: Fix font size for default overlay

Menus/popups inside the default overlay suffer from the same issue as
dialogs, as described in the comment here.

Bug: T183069
Depends-On: Ied0541209c4a9d7bf8c0574b0a864ba09fff1b70
Change-Id: I53888581f9e1da3b036166613c46cbc1085aa55e

3 years agoMerge "Update OOjs UI to v0.24.4"
jenkins-bot [Tue, 2 Jan 2018 21:15:43 +0000 (21:15 +0000)]
Merge "Update OOjs UI to v0.24.4"

3 years agoFollow-up Ic67a6f1af: RCFilters: Untypo the recurring namespaces typo
Moriel Schottlender [Tue, 2 Jan 2018 20:23:25 +0000 (12:23 -0800)]
Follow-up Ic67a6f1af: RCFilters: Untypo the recurring namespaces typo

The param name is namespace, not namespaces. Do keep up, Schottlender.

Bug: T183910
Change-Id: Ib14a3918a85c22ddd2121c8dcc709ab53b5ff63f

3 years agoUpdate OOjs UI to v0.24.4
Bartosz Dziewoński [Tue, 2 Jan 2018 20:02:12 +0000 (21:02 +0100)]
Update OOjs UI to v0.24.4

Release notes:
 https://phabricator.wikimedia.org/diffusion/GOJU/browse/master/History.md;v0.24.4

Depends-On: Ia54fb8fddc159f1612ca3038cdbd7da63935aa83
Change-Id: I3e59bf24191ddb753602cd4221fe998b53d25d8c

3 years agoMerge "MCR database schema"
jenkins-bot [Tue, 2 Jan 2018 19:17:04 +0000 (19:17 +0000)]
Merge "MCR database schema"

3 years agoRCFilters: Correct looking for items in namespace group
Moriel Schottlender [Tue, 2 Jan 2018 18:29:03 +0000 (10:29 -0800)]
RCFilters: Correct looking for items in namespace group

To look for the namespace items, we either search for things in the
'namesapces' view (plural) or the 'namespace' group (singular) so
the code had a typo. This is a recurring typo, but overall, it makes
more sense to look for items in the **group** of namespaces rather
than in the namespace view, conceptually.

Bug: T183910
Change-Id: Ic67a6f1afd3e95fe776fbc5c33ecb7af737055b4

3 years agoMerge "Expand templates: Change 'text' to 'wikitext'"
jenkins-bot [Tue, 2 Jan 2018 18:14:07 +0000 (18:14 +0000)]
Merge "Expand templates: Change 'text' to 'wikitext'"

3 years agoMerge "Expand templates: Use editfont on wikitext inputs"
jenkins-bot [Tue, 2 Jan 2018 18:12:48 +0000 (18:12 +0000)]
Merge "Expand templates: Use editfont on wikitext inputs"

3 years agoPass $title to RevisionStore in Revision::newFromArchiveRow
addshore [Tue, 2 Jan 2018 17:04:51 +0000 (17:04 +0000)]
Pass $title to RevisionStore in Revision::newFromArchiveRow

Follow up to:
I60568b8ffd22d5e3f861c03b4b8ef14332e9015b

Change-Id: Icab36eecbaa2fdbc8832f2563786c0041930b608

3 years agoSync up with Parsoid parserTests.txt
Arlo Breault [Tue, 2 Jan 2018 15:39:45 +0000 (10:39 -0500)]
Sync up with Parsoid parserTests.txt

This now aligns with Parsoid commit 28d7734fa2385a8fa599e3ce1bfbcd8582c05bc4

Change-Id: Iee7f3f0022c9c770c1a02b401699df0915ea7c86

3 years agoAdd test for DBConnRef
daniel [Tue, 2 Jan 2018 14:25:17 +0000 (15:25 +0100)]
Add test for DBConnRef

Change-Id: I510b2ed22b3866392592a5df53aa0f3ff6aab750

3 years agoMerge "Fix border colour used for textarea"
jenkins-bot [Tue, 2 Jan 2018 14:16:34 +0000 (14:16 +0000)]
Merge "Fix border colour used for textarea"

3 years agoFix border colour used for textarea
Ed Sanders [Tue, 2 Jan 2018 13:36:56 +0000 (13:36 +0000)]
Fix border colour used for textarea

Prevents FOUC when WikiEditor finishes loading.

Change-Id: Ib3610939cdb4b6a65f702688de9852a203ad6bab

3 years agoExpand templates: Change 'text' to 'wikitext'
Ed Sanders [Mon, 1 Jan 2018 14:02:34 +0000 (14:02 +0000)]
Expand templates: Change 'text' to 'wikitext'

Change-Id: Idbddadc7187bbfe6214f313ac0205184bceb2d23

3 years agoExpand templates: Use editfont on wikitext inputs
Ed Sanders [Mon, 1 Jan 2018 14:01:38 +0000 (14:01 +0000)]
Expand templates: Use editfont on wikitext inputs

Change-Id: Ie8919b4d5caf13749d81b419aff276f7c57d7049

3 years agoMerge "Add @covers tags for more tests"
jenkins-bot [Tue, 2 Jan 2018 12:19:02 +0000 (12:19 +0000)]
Merge "Add @covers tags for more tests"

3 years agoMerge "HooksTest: Covers Hooks::callHook too"
jenkins-bot [Tue, 2 Jan 2018 11:55:26 +0000 (11:55 +0000)]
Merge "HooksTest: Covers Hooks::callHook too"

3 years agoAdd @covers tags for more tests
Kunal Mehta [Fri, 29 Dec 2017 23:44:13 +0000 (15:44 -0800)]
Add @covers tags for more tests

Change-Id: If2254b3a9e61e056091779a1ea14237aa7b42eb6

3 years agoGeneralize non-digit-grouping of four-digit numbers
Bartosz Dziewoński [Tue, 10 Oct 2017 18:51:50 +0000 (20:51 +0200)]
Generalize non-digit-grouping of four-digit numbers

In some languages it's conventional not to insert a thousands
separator in numbers that are four digits long (1000-9999).
Rather than copy-paste the custom code to do this between 13 files,
introduce another option and have the base Language class handle it.

This also fixes an issue in several languages where this logic
previously would not work for negative or fractional numbers.

To implement this, a new option is added to MessagesXx.php files,
`$minimumGroupingDigits = 2;`, with the meaning as defined in
<http://unicode.org/reports/tr35/tr35-numbers.html>. It is a little
roundabout, but it could allow us to migrate the number formatting
(currently all custom code) to some generic library easily.

Bug: T177846
Change-Id: Iedd8de5648cf2de1c94044918626de2f96365d48

3 years agoMerge "build: Updating mediawiki/mediawiki-codesniffer to 15.0.0"
jenkins-bot [Tue, 2 Jan 2018 10:12:26 +0000 (10:12 +0000)]
Merge "build: Updating mediawiki/mediawiki-codesniffer to 15.0.0"

3 years agoLocalisation updates from https://translatewiki.net.
Translation updater bot [Tue, 2 Jan 2018 08:42:01 +0000 (09:42 +0100)]
Localisation updates from https://translatewiki.net.

Change-Id: I4e4a02ce4bfd4b5a73d87c57b3a9e8ef12db5087

3 years agoHooksTest: Covers Hooks::callHook too
Kunal Mehta [Tue, 2 Jan 2018 08:19:21 +0000 (00:19 -0800)]
HooksTest: Covers Hooks::callHook too

Change-Id: Id2b97b031b2fcf82a6fba66dae353db1acf340c3

3 years agoMerge "Chinese Conversion Table Update 2017-6"
jenkins-bot [Tue, 2 Jan 2018 07:21:52 +0000 (07:21 +0000)]
Merge "Chinese Conversion Table Update 2017-6"

3 years agoMerge "Add test for ApiClearHasMsg"
jenkins-bot [Tue, 2 Jan 2018 05:28:44 +0000 (05:28 +0000)]
Merge "Add test for ApiClearHasMsg"

3 years agoAdd test for ApiClearHasMsg
Phantom42 [Tue, 2 Jan 2018 02:58:08 +0000 (04:58 +0200)]
Add test for ApiClearHasMsg

Bug: T183769
Change-Id: I60c66a7cddaf03a83afd29e536281916ef3eb6d5

3 years agoBump RemexHTML version to 1.0.2
Subramanya Sastry [Tue, 2 Jan 2018 00:54:43 +0000 (18:54 -0600)]
Bump RemexHTML version to 1.0.2

Depends-On: I9fb9978c69f37bafc0049cd7ed343c033dd50ef8
Change-Id: I25bfac2c71b50db8d64f29f4b84af0a2732f245b

3 years agobuild: Updating mediawiki/mediawiki-codesniffer to 15.0.0
Umherirrender [Mon, 1 Jan 2018 13:10:16 +0000 (14:10 +0100)]
build: Updating mediawiki/mediawiki-codesniffer to 15.0.0

Clean up use of @codingStandardsIgnore
- @codingStandardsIgnoreFile -> phpcs:ignoreFile
- @codingStandardsIgnoreLine -> phpcs:ignore
- @codingStandardsIgnoreStart -> phpcs:disable
- @codingStandardsIgnoreEnd -> phpcs:enable

For phpcs:disable always the necessary sniffs are provided.
Some start/end pairs are changed to line ignore

Change-Id: I92ef235849bcc349c69e53504e664a155dd162c8

3 years agoUse MediaWikiCoversValidator for tests that don't use MediaWikiTestCase
Kunal Mehta [Fri, 29 Dec 2017 23:22:37 +0000 (15:22 -0800)]
Use MediaWikiCoversValidator for tests that don't use MediaWikiTestCase

Change-Id: I8c4de7e9c72c9969088666007b54c6fd23f6cc13

3 years agoLocalisation updates from https://translatewiki.net.
Translation updater bot [Mon, 1 Jan 2018 07:43:44 +0000 (08:43 +0100)]
Localisation updates from https://translatewiki.net.

Change-Id: Ib05ba7e02b1e4fdc06ebdc819f076106ad835d0c

3 years agoMerge "Add tests for ApiCheckToken"
jenkins-bot [Mon, 1 Jan 2018 01:18:52 +0000 (01:18 +0000)]
Merge "Add tests for ApiCheckToken"

3 years agoAdd tests for ApiCheckToken
Phantom42 [Sun, 31 Dec 2017 20:16:17 +0000 (22:16 +0200)]
Add tests for ApiCheckToken

Bug: T183768
Change-Id: I63ab0413252c7333f73b881995869454c4881a57

3 years agoMerge "Revision: Handle all return values of Title::newFromId"
jenkins-bot [Mon, 1 Jan 2018 00:05:25 +0000 (00:05 +0000)]
Merge "Revision: Handle all return values of Title::newFromId"

3 years agoRevision: Handle all return values of Title::newFromId
Sam Smith [Wed, 27 Dec 2017 14:17:04 +0000 (14:17 +0000)]
Revision: Handle all return values of Title::newFromId

In Revision::getKnownCurrent, fail early when Title::newFromId returns
null to avoid an uncatchable fatal error being triggered.

RevisionStore#getKnownCurrentRevision requires that the title parameter
be an instance of Title.

This follows on from Ia4c20a91.

Change-Id: I9bddafcc5df630d1dff1e2526194186cab7097e5

3 years agoFix typo in word "callback"
Umherirrender [Sun, 31 Dec 2017 12:35:10 +0000 (13:35 +0100)]
Fix typo in word "callback"

Change-Id: If47b9d80df4189317ec41998b35546a6118288c2

3 years agoLocalisation updates from https://translatewiki.net.
Translation updater bot [Sun, 31 Dec 2017 08:14:59 +0000 (09:14 +0100)]
Localisation updates from https://translatewiki.net.

Change-Id: I7a68758df8af2b9ffdf0e8d5a2c84fdbae221b9d

3 years agoMerge "Remove self-explaining "section heading" comments from classes"
jenkins-bot [Sat, 30 Dec 2017 21:25:14 +0000 (21:25 +0000)]
Merge "Remove self-explaining "section heading" comments from classes"

3 years agoParser: extract $title, follow-up 3d560be428
Kunal Mehta [Sat, 30 Dec 2017 10:32:06 +0000 (02:32 -0800)]
Parser: extract $title, follow-up 3d560be428

In the conversion away from extract(), the $title variable was missed. This
broke LabeledSectionTransclusion.

Change-Id: If4c140aedf16fc16a4ae2361f465798055748255

3 years agoMerge "Improve (weak and strict) type hints invarious places"
jenkins-bot [Sat, 30 Dec 2017 17:10:58 +0000 (17:10 +0000)]
Merge "Improve (weak and strict) type hints invarious places"

3 years agoMerge "Decapitalise services folder in tests/phpunit"
jenkins-bot [Sat, 30 Dec 2017 10:42:38 +0000 (10:42 +0000)]
Merge "Decapitalise services folder in tests/phpunit"

3 years agoMerge "Append leading \ to BlobStoreFactoryTest covers"
jenkins-bot [Sat, 30 Dec 2017 08:37:47 +0000 (08:37 +0000)]
Merge "Append leading \ to BlobStoreFactoryTest covers"

3 years agoLocalisation updates from https://translatewiki.net.
Translation updater bot [Sat, 30 Dec 2017 08:12:23 +0000 (09:12 +0100)]
Localisation updates from https://translatewiki.net.

Change-Id: I38e3c7018119fe60f30e1f0830eea7508d0061d5

3 years agoAppend leading \ to BlobStoreFactoryTest covers
Reedy [Sat, 30 Dec 2017 05:02:03 +0000 (05:02 +0000)]
Append leading \ to BlobStoreFactoryTest covers

Change-Id: I9b85aa9808c40aa728c6ef186c50bc8cdda08bc6

3 years agoTry to opportunistically flush statsd data in maintenance scripts
Aaron Schulz [Sat, 2 Dec 2017 21:12:41 +0000 (13:12 -0800)]
Try to opportunistically flush statsd data in maintenance scripts

This helps to avoid OOMs from buffer build-ups in the statsd
factory object. This piggy-backs on to the same checks used
for deferred update runs. In addition, the output() method
checks if the data size is getting large and emits if needed.

Bug: T181385
Change-Id: I598be98a5770f8358975815e51380c4b8f63a79e

3 years agoDecapitalise services folder in tests/phpunit
Reedy [Sat, 30 Dec 2017 04:09:52 +0000 (04:09 +0000)]
Decapitalise services folder in tests/phpunit

Change-Id: If3bf8fd704eccdde435cb3bfd99ba1c1d3caee1f

3 years agoStop testing hhvm 3.12 on travis
Reedy [Sat, 30 Dec 2017 02:01:32 +0000 (02:01 +0000)]
Stop testing hhvm 3.12 on travis

WMF is using 3.18, which we're testing

Change-Id: I7749d4fe81433a1fd2e07447af1912c30d7c9330

3 years agoMerge "Special:ProtectedPages: Add fields directly in $formDescriptor"
jenkins-bot [Fri, 29 Dec 2017 22:05:42 +0000 (22:05 +0000)]
Merge "Special:ProtectedPages: Add fields directly in $formDescriptor"

3 years agoVerify that all @covers tags are sane when running tests
Kunal Mehta [Fri, 22 Dec 2017 07:24:06 +0000 (23:24 -0800)]
Verify that all @covers tags are sane when running tests

PHPUnit only verifies that @covers tags are correct when actually
running coverage - but that's too slow to do on every commit. And if
even a single tag is incorrect, the entire coverage job will fail. It
also has some different requirements compared to normal tags, like all
namespaced classes must use their absolute name. All of those things
combined make it easy for developers to accidentally break the coverage
job.

There are some external tools that also do this, but those tools are
incompatible with our unusual PHPUnit setup (the phpunit.php wrapper
script).

The MediaWikiCoversValidator trait just calls the same method that
PHPUnit does to validate @covers tags. It is implemented as a trait so
that test cases that implement PHPUnit_Framework_TestCase directly can
still use this.

Bug: T171899
Change-Id: I1d564bcae2bfbedb004c440b90db6341148ed4ba

3 years agoMerge "API: Fix doc comment for ApiFormatNone"
jenkins-bot [Fri, 29 Dec 2017 13:48:06 +0000 (13:48 +0000)]
Merge "API: Fix doc comment for ApiFormatNone"

3 years agoMerge "[MCR] Revision::newFromArchiveRow remove recently added $title param"
jenkins-bot [Fri, 29 Dec 2017 10:31:22 +0000 (10:31 +0000)]
Merge "[MCR] Revision::newFromArchiveRow remove recently added $title param"

3 years agoMerge "Revert "[MCR] Add and use $title param to RevisionStore getPrevious/Next""
jenkins-bot [Fri, 29 Dec 2017 10:28:24 +0000 (10:28 +0000)]
Merge "Revert "[MCR] Add and use $title param to RevisionStore getPrevious/Next""

3 years agoMerge "Revert "[MCR] Add optional $title param to Revision byId methods""
jenkins-bot [Fri, 29 Dec 2017 10:28:21 +0000 (10:28 +0000)]
Merge "Revert "[MCR] Add optional $title param to Revision byId methods""

3 years agoAPI: Fix doc comment for ApiFormatNone
Kunal Mehta [Fri, 29 Dec 2017 09:01:07 +0000 (01:01 -0800)]
API: Fix doc comment for ApiFormatNone

Change-Id: I42812402b91b2775657e68189fb662a1a3d33c08

3 years agoLocalisation updates from https://translatewiki.net.
Translation updater bot [Fri, 29 Dec 2017 08:30:53 +0000 (09:30 +0100)]
Localisation updates from https://translatewiki.net.

Change-Id: I3656774b88a5d31eff6b78779528c270b484ddd7

3 years agoMerge "Make ImagePage#getThumbPrevText and ImagePage#makeSizeLink protected instead...
jenkins-bot [Fri, 29 Dec 2017 06:27:50 +0000 (06:27 +0000)]
Merge "Make ImagePage#getThumbPrevText and ImagePage#makeSizeLink protected instead of private"

3 years agoSpecial:ProtectedPages: Add fields directly in $formDescriptor
Prateek Saxena [Fri, 29 Dec 2017 04:10:41 +0000 (09:40 +0530)]
Special:ProtectedPages: Add fields directly in $formDescriptor

…instead of having separate functions.

Change-Id: Ife9ca83b97b24e4372d1b43b0eea41c3ac5c0fe2

3 years agoMerge "Remove duplicate getTitle call in RevisionStore::getNextRevision"
jenkins-bot [Fri, 29 Dec 2017 00:21:55 +0000 (00:21 +0000)]
Merge "Remove duplicate getTitle call in RevisionStore::getNextRevision"

3 years agoMerge "[MCR] pass $queryFlags into RevisionStore::getTitle"
jenkins-bot [Fri, 29 Dec 2017 00:20:56 +0000 (00:20 +0000)]
Merge "[MCR] pass $queryFlags into RevisionStore::getTitle"

3 years agoMerge "Remove leading backslashes from "use \…" tags"
jenkins-bot [Thu, 28 Dec 2017 23:48:21 +0000 (23:48 +0000)]
Merge "Remove leading backslashes from "use \…" tags"

3 years ago[MCR] Revision::newFromArchiveRow remove recently added $title param
addshore [Thu, 28 Dec 2017 18:57:13 +0000 (18:57 +0000)]
[MCR] Revision::newFromArchiveRow remove recently added $title param

The $title param was added as part of
Ieabca1cf157fb667c75fc907b9da2917f71c61b3 and is not yet used
by any code.

The underlying issue with title fetching in RevisionStore has been fixed
in commit 4de36baa63afc23398f5d1747f08fc47309c314c
I15e4663902e2cbfe15b0da2e46449330e313bd0d

This patch removes the param that is not needed, but adds duplicate
logic to fetch a Title object to pass into the Revision object that
is created.
This logic is pulled directly from
RevisionStore::newRevisionFromArchiveRow.

Change-Id: I60568b8ffd22d5e3f861c03b4b8ef14332e9015b

3 years agoRevert "[MCR] Add and use $title param to RevisionStore getPrevious/Next"
addshore [Thu, 28 Dec 2017 18:48:55 +0000 (18:48 +0000)]
Revert "[MCR] Add and use $title param to RevisionStore getPrevious/Next"

This reverts commit a760526bb41df8a46f70b498a2059323a99a683c.
This is a PARTIAL revert and the changes to the follwing methods remain:
 - Revision::newFromArchiveRow

This is no longer needed as the underlying issue has been fixed
in commit 4de36baa63afc23398f5d1747f08fc47309c314c
I15e4663902e2cbfe15b0da2e46449330e313bd0d

Change-Id: I3e0ae29e62d59bcb4be871ef5b389a673ce8f103

3 years agoRevert "[MCR] Add optional $title param to Revision byId methods"
addshore [Thu, 28 Dec 2017 18:34:17 +0000 (18:34 +0000)]
Revert "[MCR] Add optional $title param to Revision byId methods"

This reverts commit 7bfb4f195121008471974490ae24a86f2a450951.
and 56b7ba03a286c0997752fb61b14662347ea0e9de

This is no longer needed as the underlying issue has been fixed
in commit 4de36baa63afc23398f5d1747f08fc47309c314c
I15e4663902e2cbfe15b0da2e46449330e313bd0d

Bug: T183505
Change-Id: I194a558625d15fd4f7929e363557847f8bebde4f

3 years agoMerge "Add @covers tags API tests without them"
jenkins-bot [Thu, 28 Dec 2017 16:53:39 +0000 (16:53 +0000)]
Merge "Add @covers tags API tests without them"

3 years agoMerge "Add @covers tags to languages tests"
jenkins-bot [Thu, 28 Dec 2017 16:47:45 +0000 (16:47 +0000)]
Merge "Add @covers tags to languages tests"

3 years agoMerge "Add @covers tags to miscellaneous tests (#2)"
jenkins-bot [Thu, 28 Dec 2017 16:45:17 +0000 (16:45 +0000)]
Merge "Add @covers tags to miscellaneous tests (#2)"

3 years agoMerge "Add @coversNothing in places where @covers does not apply"
jenkins-bot [Thu, 28 Dec 2017 16:39:10 +0000 (16:39 +0000)]
Merge "Add @coversNothing in places where @covers does not apply"

3 years agoSimplify autocomplete attribute in HTMLForm
Fomafix [Thu, 21 Apr 2016 05:39:08 +0000 (05:39 +0000)]
Simplify autocomplete attribute in HTMLForm

Follows-up 7489a3e8

Change-Id: Ifb17c88e39df7031054b3bee83772172c64d0a6b

3 years agoImprove (weak and strict) type hints invarious places
Thiemo Mättig [Thu, 28 Dec 2017 15:31:56 +0000 (16:31 +0100)]
Improve (weak and strict) type hints invarious places

Change-Id: I3a42ec1547fae971d7b495c99dd144739d8521ab

3 years agoRemove leading backslashes from "use \…" tags
Thiemo Mättig [Thu, 28 Dec 2017 15:30:05 +0000 (16:30 +0100)]
Remove leading backslashes from "use \…" tags

Change-Id: I494b029de089a07e3b946ee78293a12d5036f63e

3 years agoRemove self-explaining "section heading" comments from classes
Thiemo Mättig [Thu, 28 Dec 2017 15:12:08 +0000 (16:12 +0100)]
Remove self-explaining "section heading" comments from classes

I can see that "parent::__construct" literally calls the parent
constructor. I can see that stuff preceeded by the keyword "protected"
is protected. I really (really) don't need comments explaining such.

Change-Id: I7458e714976a6acd3ba6a7c93fdc27d03903df83

3 years agoRemove duplicate getTitle call in RevisionStore::getNextRevision
addshore [Thu, 28 Dec 2017 13:15:49 +0000 (13:15 +0000)]
Remove duplicate getTitle call in RevisionStore::getNextRevision

Change-Id: I5b7cd0e2a9ce413e582b4bdeeebc94a143896728

3 years ago[MCR] pass $queryFlags into RevisionStore::getTitle
addshore [Thu, 28 Dec 2017 13:14:39 +0000 (13:14 +0000)]
[MCR] pass $queryFlags into RevisionStore::getTitle

Bug: T183716
Bug: T183717
Bug: T183505
Change-Id: I15e4663902e2cbfe15b0da2e46449330e313bd0d

3 years agoMerge "Add @covers tags to database tests"
jenkins-bot [Thu, 28 Dec 2017 11:08:09 +0000 (11:08 +0000)]
Merge "Add @covers tags to database tests"

3 years agoMerge "tests: Complete test coverage of HtmlArmor"
jenkins-bot [Thu, 28 Dec 2017 11:05:51 +0000 (11:05 +0000)]
Merge "tests: Complete test coverage of HtmlArmor"

3 years agoMerge "Remove useless StatusTest::testCanConstruct()"
jenkins-bot [Thu, 28 Dec 2017 10:42:14 +0000 (10:42 +0000)]
Merge "Remove useless StatusTest::testCanConstruct()"

3 years agoMerge "Remove resolved todo from MWNamespace test"
jenkins-bot [Thu, 28 Dec 2017 10:40:10 +0000 (10:40 +0000)]
Merge "Remove resolved todo from MWNamespace test"

3 years agoMerge "Improve @covers for TemplateParserTest"
jenkins-bot [Thu, 28 Dec 2017 10:34:47 +0000 (10:34 +0000)]
Merge "Improve @covers for TemplateParserTest"

3 years agoMerge "make 7zip wrapper usable for dumping text revisions again"
jenkins-bot [Thu, 28 Dec 2017 09:59:10 +0000 (09:59 +0000)]
Merge "make 7zip wrapper usable for dumping text revisions again"

3 years agoMerge "Change php extract() to explicit code"
jenkins-bot [Thu, 28 Dec 2017 09:44:58 +0000 (09:44 +0000)]
Merge "Change php extract() to explicit code"

3 years agoMerge "Add HTML attributes lang and dir to toctitle"
jenkins-bot [Thu, 28 Dec 2017 09:37:47 +0000 (09:37 +0000)]
Merge "Add HTML attributes lang and dir to toctitle"

3 years agoMerge "maintenance: Add unit test for Benchmarker class"
jenkins-bot [Thu, 28 Dec 2017 09:22:01 +0000 (09:22 +0000)]
Merge "maintenance: Add unit test for Benchmarker class"

3 years agotests: Complete test coverage of HtmlArmor
Kunal Mehta [Thu, 28 Dec 2017 03:22:51 +0000 (19:22 -0800)]
tests: Complete test coverage of HtmlArmor

Change-Id: I3c50ea56721226ddb37bcf4778a7d71e9b56d0f7

3 years agoAdd @coversNothing in places where @covers does not apply
Kunal Mehta [Thu, 28 Dec 2017 08:38:21 +0000 (00:38 -0800)]
Add @coversNothing in places where @covers does not apply

These tests apply to things that are not relevant to PHP code coverage,
such as testing presence of messages, JSON files, or the PHPUnit tests
themselves.

Using @coversNothing indicates that there is no code here to be covered,
and prevents warnings when using --strict-coverage mode (T152923).

Change-Id: Id89ee2c15a3ce3f10e34b13fb677cd1af75af9e6

3 years agoImprove @covers for TemplateParserTest
Kunal Mehta [Thu, 28 Dec 2017 08:31:08 +0000 (00:31 -0800)]
Improve @covers for TemplateParserTest

The current @covers tags for TemplateParserTest are an incomplete call
stack for TemplateParser::processTemplate, and miss out on some
functions that are called. Those functions could be repeated in @covers
tags, but it would be burdensome to keep it up to date.

Instead, just use class level @covers for the whole test case. This also
takes care of the previously uncovered testEnableRecursivePartials().

Change-Id: I475ceba26b70a115b40d7735834a07f298f7bf99

3 years agoAdd @covers tags to database tests
Kunal Mehta [Thu, 28 Dec 2017 08:28:45 +0000 (00:28 -0800)]
Add @covers tags to database tests

Change-Id: Ic46bb961b41856d390ffe0e3632790c506f5655b

3 years agoRemove resolved todo from MWNamespace test
Kunal Mehta [Thu, 28 Dec 2017 08:27:40 +0000 (00:27 -0800)]
Remove resolved todo from MWNamespace test

The todo was added by Addshore in aea1b27db02 at the same time he added
all the @covers tags, so it appears to all be resolved.

Change-Id: I03d866fdd1ca382ca2b1699e01a0dd9a28eef1ec

3 years agoRemove useless StatusTest::testCanConstruct()
Kunal Mehta [Thu, 28 Dec 2017 08:25:25 +0000 (00:25 -0800)]
Remove useless StatusTest::testCanConstruct()

Neither Status, nor StatusValue have constructors, so there's not much
point testing whether the object can be constructed.

Change-Id: I170940889b5da5198ef4576d04786f84c293dd01

3 years agoAdd @covers tags to languages tests
Kunal Mehta [Thu, 28 Dec 2017 08:24:40 +0000 (00:24 -0800)]
Add @covers tags to languages tests

I removed comments that merely repeated the location of the class being
tested. There are other tests in this directory that don't have a
corresponding class and need further investigation.

Change-Id: Ic16f0887b5030ac53fab4382cfaedfb5426cdb08

3 years agoAdd @covers tags to miscellaneous tests (#2)
Kunal Mehta [Thu, 28 Dec 2017 08:22:35 +0000 (00:22 -0800)]
Add @covers tags to miscellaneous tests (#2)

Change-Id: I9116598bee4f4917e02290d273644c13475ff721

3 years agoLocalisation updates from https://translatewiki.net.
Translation updater bot [Thu, 28 Dec 2017 08:04:14 +0000 (09:04 +0100)]
Localisation updates from https://translatewiki.net.

Change-Id: Icc11f7ae67c7a70f4c59eec632c74926700a69c9

3 years agomaintenance: Add unit test for Benchmarker class
Timo Tijhof [Wed, 27 Dec 2017 20:44:38 +0000 (21:44 +0100)]
maintenance: Add unit test for Benchmarker class

Change-Id: I3f835fc07741fd42b8adb5b019f72589429cc14f

3 years agoMerge "phpunit: Remove outdated comment about calling of LinkCache::clear()"
jenkins-bot [Wed, 27 Dec 2017 22:04:37 +0000 (22:04 +0000)]
Merge "phpunit: Remove outdated comment about calling of LinkCache::clear()"

3 years agoMerge "mw.rcfilters.ui.SaveFiltersPopupButtonWidget: Remove pointless option"
jenkins-bot [Wed, 27 Dec 2017 21:39:36 +0000 (21:39 +0000)]
Merge "mw.rcfilters.ui.SaveFiltersPopupButtonWidget: Remove pointless option"

3 years agoMerge "Add grep comment for js vars wgRestriction*"
jenkins-bot [Wed, 27 Dec 2017 21:14:54 +0000 (21:14 +0000)]
Merge "Add grep comment for js vars wgRestriction*"

3 years agophpunit: Remove outdated comment about calling of LinkCache::clear()
Timo Tijhof [Wed, 27 Dec 2017 20:52:44 +0000 (21:52 +0100)]
phpunit: Remove outdated comment about calling of LinkCache::clear()

This is actually being called now, from resetDB() between tests.

Change-Id: I5aa15ce3fd57b6fc90b424fde8691ff33c7ddf45

3 years agoAdd HTML attributes lang and dir to toctitle
Fomafix [Fri, 29 May 2015 17:07:55 +0000 (17:07 +0000)]
Add HTML attributes lang and dir to toctitle

The toctitle is in user interface language. This change add the
HTML attributes lang and dir to the toctitle.

This allows to copy (a part of) the rendered HTML to a word processing
and the language for spell checking has the right language.

Change-Id: I17730869f81744560672d7d0acb67ced71e69c4e

3 years agoAdd @covers tags API tests without them
Kunal Mehta [Sun, 24 Dec 2017 23:44:36 +0000 (15:44 -0800)]
Add @covers tags API tests without them

Change-Id: Ida0f954cb0a44719af3a3d0c6bda4587c9ca42b6

3 years agoAdd tests for TextboxBuilder
Kunal Mehta [Mon, 25 Dec 2017 01:35:00 +0000 (17:35 -0800)]
Add tests for TextboxBuilder

Change-Id: I305e0bce902fb027bf02cc8a28e8846808f6437c