mirror of
https://gerrit.wikimedia.org/r/mediawiki/skins/Vector.git
synced 2024-11-24 07:43:47 +00:00
Update tests for default Menu template value
Change-Id: I32586a379cbacaad5cfb361facf79c01e982818a
This commit is contained in:
parent
99a201d5b9
commit
0fc7be61c1
|
@ -59,6 +59,7 @@
|
|||
* @property {string} [class] of menu
|
||||
* @property {string} [html-user-language-attributes]
|
||||
* @property {boolean} [is-dropdown]
|
||||
* @property {string} [html-before-portal] Additional HTML specific to portal menus.
|
||||
* @property {string} [html-after-portal] Additional HTML specific to portal menus.
|
||||
*/
|
||||
|
||||
|
|
|
@ -80,6 +80,11 @@ class SkinVectorTest extends MediaWikiIntegrationTestCase {
|
|||
$views = $props['data-views'];
|
||||
$namespaces = $props['data-namespaces'];
|
||||
|
||||
// Can be removed when https://gerrit.wikimedia.org/r/c/mediawiki/core/+/699446 is merged.
|
||||
if ( !array_key_exists( 'html-before-portal', $views ) ) {
|
||||
$views = wfArrayInsertAfter( $views, [ 'html-before-portal' => '' ], 'html-after-portal' );
|
||||
}
|
||||
|
||||
$this->assertSame(
|
||||
[
|
||||
// Provided by core
|
||||
|
@ -88,11 +93,14 @@ class SkinVectorTest extends MediaWikiIntegrationTestCase {
|
|||
'html-tooltip' => '',
|
||||
'html-items' => '',
|
||||
'html-after-portal' => '',
|
||||
'html-before-portal' => '',
|
||||
'label' => $context->msg( 'views' )->text(),
|
||||
'heading-class' => 'vector-menu-heading',
|
||||
'is-dropdown' => false,
|
||||
],
|
||||
$views
|
||||
$views,
|
||||
0,
|
||||
true
|
||||
);
|
||||
|
||||
$variants = $props['data-variants'];
|
||||
|
|
Loading…
Reference in a new issue