mirror of
https://gerrit.wikimedia.org/r/mediawiki/skins/MinervaNeue
synced 2024-12-19 17:21:07 +00:00
a6ab8d6da3
Change-Id: I52b2feacd6216e99e04f193ba963e897b3e1a771
19 lines
670 B
JavaScript
19 lines
670 B
JavaScript
/*!
|
|
* Minerva integration tests.
|
|
*
|
|
* This should only be used to test APIs that Minerva depends on to work.
|
|
* For unit tests please see tests/jest.
|
|
*/
|
|
QUnit.module( 'Minerva (integration)', () => {
|
|
QUnit.test( '[T356653] Client preferences: Check assumptions about the cookie it writes to', function ( assert ) {
|
|
mw.cookie.set( 'mwclientpreferences', '' );
|
|
this.sandbox.stub( mw.user, 'isAnon' ).returns( true );
|
|
document.documentElement.setAttribute( 'class', 'skin-theme-clientpref-day' );
|
|
mw.user.clientPrefs.set( 'skin-theme', 'night' );
|
|
assert.strictEqual(
|
|
mw.cookie.get( 'mwclientpreferences' ),
|
|
'skin-theme-clientpref-night'
|
|
);
|
|
} );
|
|
} );
|