mediawiki-skins-MinervaNeue/resources
Timo Tijhof 548e94da98 tests: Adopt private require() for skins.minerva.scripts
Added to MediaWiki core last year with I9fca9fdf9b7623b1.

This fixes a confusing assertion in page-issues/index.test.js,
where for "insertBannersOrNotice()" it was asserting that the HTML
contain "⧼skin-minerva-issue-learn-more⧽", where the ⧼ character
indicates the message is not found (i.e. an error).

The test had to be written this way in order to pass, because
the skins.minerva.scripts module was not actually loaded, and thus
its templates and messages are not present either. This lack was
filled in by index.js for mw.templates, but not mw.messages.

By adopting private require(), these workarounds can all be removed.

== Motivation ==

In change I3a4024ccf90e505581, I'm working on improving the testrunner
config to enforce uselang=qqx on all tests. This is passing except
for GrowthExperiments and Minerva, both of which have the above
workarounds in place that caused a message to be undefined, and then
kept in the assertion expectation. When using uselang=qqx, values are
returned as (key) instead of ⧼key⧽, which exposes these message
existence errors.

By removing this workaround, the test will simply import the module
in the test as normal, thus the messages will exist, and thus it
will expect (key), and thus it will continue to pass even after
enforcing uselang=qqx.

Change-Id: Ib68f45d93a7054ed8bd35fc5644e2852f2f90248
2024-08-23 19:04:36 +00:00
..
mediawiki.less Update Minerva to get Codex CSS vars from default files 2024-05-01 00:00:42 +00:00
skins.minerva.amc.styles (Almost) no more CSS variables in minerva 2024-06-11 11:44:47 -07:00
skins.minerva.base.styles Prevent dark-mode styles from affecting print media 2024-08-08 14:27:30 -04:00
skins.minerva.content.styles.images styles: Update color in SVG from #d33 to #d73333 2024-03-13 15:00:37 -04:00
skins.minerva.DarkModeLaunchBanner Migrate bare division math to parens division 2024-08-02 13:33:00 -05:00
skins.minerva.loggedin.styles (Almost) no more CSS variables in minerva 2024-06-11 11:44:47 -07:00
skins.minerva.mainMenu.styles (Almost) no more CSS variables in minerva 2024-06-11 11:44:47 -07:00
skins.minerva.mainPage.styles styles: Stop using SkinModule in skins.minerva.mainPage.styles 2024-05-15 14:49:37 +00:00
skins.minerva.scripts tests: Adopt private require() for skins.minerva.scripts 2024-08-23 19:04:36 +00:00
skins.minerva.userpage.styles styles: Stop using SkinModule in skins.minerva.mainPage.styles 2024-05-15 14:49:37 +00:00
.eslintrc.json ESLint: Enforce no-underscore-dangle 2024-06-03 12:59:48 +01:00
mobile.startup.stub.js Make MobileFrontend dependency a soft one 2020-01-17 14:02:23 -08:00