Commit graph

5 commits

Author SHA1 Message Date
DannyS712
0eaf981190 Remove BC support for creating ConfiguredReadOnlyMode with Config
Class is not @newable / stable to create, so no need to mention in
the release notes

Change-Id: I04a89c9641866907b26988c91c81a3208d57a3f3
2020-10-26 00:27:17 +00:00
Aryeh Gregor
18ec468633 Don't pass Config to service constructors
We don't want to depend on the entire site configuration when we only
need a few specific settings.

This change additionally means that these services no longer see a live
version of the settings, but rather a copy. This means in tests you
really do have to call overrideMwServices() if you want services to pick
up your config changes.

ResourceLoader and SearchEngineConfig will need more work to port,
because they expose their member Config in a getter, and the getter is
actually used.

Parser and NamespaceInfo are also relatively complicated, so I split
them into separate patches.

Tested with 100% code coverage. \o/

Depends-On: If6534b18f6657ec1aba7327463f2661037f995b3
Change-Id: I1a3f358e8659b49de4502dc8216ecb6f35f4e02a
2019-05-02 11:33:56 +03:00
Aryeh Gregor
9d5e3ad0f5 Drop clearCache() from (Configured)ReadOnlyMode
These are services, so tests should just override services to reset
them.

Change-Id: Icb1a041f8fac1ea0b7421e69b7b31b24171d868b
2019-04-10 19:39:34 +03:00
Fomafix
4b46994799 Fix usage of MediaWikiServices in comments and documentation
MediaWikiServices::getFoo()

is wrong. Right is:

MediaWikiServices::getInstance()->getFoo()

Change-Id: Ib6d844ddfe5bd6ccd72b887a63d9ad476c8d196f
2019-03-03 14:09:33 +00:00
addshore
c2aa8ba9ea Split ConfiguredReadOnlyMode into own file
Change-Id: I7c12a571bb5ce76c132a738b48b2b82d763a8860
2017-08-07 09:24:19 +00:00