This allows browser tests to access the "new wikitext" mode, but
should not affect any tests which don't explicitly enable the
associated beta preference.
Bug: T270240
Change-Id: I2ba889e1a5dd03549d8d7cb00678a30882ff03fe
This restores commit: "Improve custom folding and grouping"
I7d819fdb376c861f40bfc01aed74cd3706141b20 (9af96ef4c7)
by partially reverting the following revert:
I31ed9488297e516920a2183e4311357ffdd098a7 (34ab93a6b8)
Bug: T271365
Change-Id: I987bde4c1ada95e938089122a257292aa16737ae
For MySQL/Sqlite, drop the table options, they are for MySQL < 5.0 which
was released in 2003 and not any use today.
For Postgres, rename pagecontent table to text, approved as part of the
RFC. Swap order of creating auto-generated tables and manual tables.
Bug: T230428
Bug: T164898
Change-Id: Id7510b80beed7a7297353094a57d5e2d4f12fc64
Previously it would flip based on the chrome, which isn't the way the
legacy parser has been doing it.
The choice of whether .mw-content-$dir are the right selectors can be
cleaned up with T258719. We're already using them elsewhere in the file
so it seems like something that should be done all at once.
Bug: T269704
Change-Id: I1a2cc989c35506172af361cd86a4a378ddf58ecb
Refactor to clarify that the styles for these two groups
are indeed distinct and that sharing code between them
isn't giving any benefit since it's pretty much all overridden
Also address a problem with .mw-halign-none not rendering properly
due to ordering issues
Change-Id: I311bfa6419e493a5b36aeef4433e9730658e328a
Make ApiQueryBase::addOption() annotation consistent with
SelectQueryBuilder::option() since the ApiQueryBase method
is just a wrapper to it.
Change-Id: Ib301bce787c8ba89ae8333eb7cfb8d7d287de20c
Refactor the database setup code to share more code between
ParserTestRunner and MediaWikiIntegrationTestCase. Made
`::setupAllTestDBs` static so it can be reused from
ParserTestRunner.
Made ParserTestRunner::addArticle more like
MediaWikiIntegrationTestCase::addCoreDBData(). Some additional
refactoring work could be done here in the future to share more code.
After the refactoring the ParserTestTables hook is no longer necessary
and so has been (soft) deprecated. MediaWikiIntegrationTestCase
clones all database tables, so ParserTestRunner no longer needs to ask
extensions for a list of specific tables it should clone. Cleaning up
the handful of extensions which define this hook will be left to a
future patch set.
Change-Id: I5124789fac333a664b73b4b4a1e801ecc0a618ca
Uncovered while working on a side project. If the option has been
set, it should be merged with the ResourceLoaderSkinModule property.
It should not replace it.
Change-Id: I413c862afe7e5266ab9f2635211fac635bcd786d
The message cache is originally meant for mw.messages in JS,
which expects non-existent messages to be cleanly omitted.
There is minimal server-side and client-side handling in place for this.
For LESS, however, we were assuming that the blob is complete,
thus not feeding anything to the LESS compiler, thus leading to
a run-time failure where the LESS file can't be parsed at all
due to an undeclared variable.
This could happen sometimes during development or after upgrading
a wiki with a stale LocalisationCache that is still being updated
at that time.
Bug: T267785
Change-Id: I60ff4eb7dce1fee56470acc177afd29ee14b764f
This is sent at the end of the LBFactory::shutdown wrapper, so will
still happen at the same logical point in time.
Use LBFactory->replLogger since that it is also the logger used
by ChronologyProtector.
Bug: T254634
Change-Id: Ic4a9573e6cd3ea00f77b2f44c03453c5b96fa486
These were left behind during the initial sprint (344481f60d) for
UnitTestCase as it used a global variable. Since then, UnitTestCase
has gained support for resetting these automatically for simple
cases like this. No need to bring in IntegrationTestCase for it.
Change-Id: Id8717c1f4148510ae4a67aec7a2dc0d23679a5ac
* Add tests for was untested fallback logic.
* Rename 'hidden' to 'HIDDEN' to make it clearer that this is not a
(dynamic) boolean but a string constant.
* Remove case for msHidden. The best I can tell, this was never a thing
in any version of IE. Similar code in EventLogging, for example, does
not contain this case either. CanIUse and MDN confirm that this is
supported through the standard since IE10+, including IE11.
<https://caniuse.com/mdn-api_document_hidden>
* Document that the 'else' branch for `document[ HIDDEN ]` is
handling both the 'visible' case and the "unsupported API" case.
* Define local functions normally as such. Avoid confusing var assignments
for functions that are not dynamic or conditional.
* Clean up 'init':
- Use under the same name in source and in test.
- Avoid shadowing variable 'document'.
- Move default logic to `init()` so that it must be called before
use, instead of previously where it could work without it.
This also makes it easier to restore, and allows the real global
to be explicitly references as such for improved static analysis.
- Add missing restoration to test suite.
* Remove redundant closure from test suite file.
Change-Id: I6180682f49781e51551048c2d16ca40c044dda98
If a new feature is added, it should be safe for skins to use it
without breaking their backwards compatibility.
For example if the normalize feature in 1.36 is being used a skin
should be able to use it, and then using version_compare add additional
styles for older versions of mediawiki
Bug: T271441
Change-Id: I074415970455ef701b48d11ff97c01af24197eeb