Merge "Tests: Limit testGetTemplateData to current values to allow expansion"

This commit is contained in:
jenkins-bot 2022-01-31 20:26:49 +00:00 committed by Gerrit Code Review
commit 44e6289f8d

View file

@ -86,6 +86,18 @@ class SkinVectorTest extends MediaWikiIntegrationTestCase {
$views = $props['data-views'];
$namespaces = $props['data-namespaces'];
// The mediawiki core specification might change at any time
// so let's limit the values we test to those we are aware of.
$keysToTest = [
'id', 'class', 'html-tooltip', 'html-items',
'html-after-portal', 'html-before-portal',
'label', 'heading-class', 'is-dropdown'
];
foreach ( $views as $key => $value ) {
if ( !in_array( $key, $keysToTest ) ) {
unset( $views[ $key] );
}
}
$this->assertSame(
[
// Provided by core