mirror of
https://gerrit.wikimedia.org/r/mediawiki/skins/Vector.git
synced 2024-12-18 19:00:50 +00:00
Merge "tests: Remove unused private method"
This commit is contained in:
commit
c761944d6e
|
@ -34,25 +34,6 @@ class SkinVectorTest extends MediaWikiIntegrationTestCase {
|
||||||
return $template;
|
return $template;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
* @param string $nodeString an HTML of the node we want to verify
|
|
||||||
* @param string $tag Tag of the element we want to check
|
|
||||||
* @param string $attribute Attribute of the element we want to check
|
|
||||||
* @param string $search Value of the attribute we want to verify
|
|
||||||
* @return bool
|
|
||||||
*/
|
|
||||||
private function expectNodeAttribute( $nodeString, $tag, $attribute, $search ) {
|
|
||||||
$node = new \DOMDocument();
|
|
||||||
$node->loadHTML( $nodeString );
|
|
||||||
$element = $node->getElementsByTagName( $tag )->item( 0 );
|
|
||||||
if ( !$element ) {
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
|
|
||||||
$values = explode( ' ', $element->getAttribute( $attribute ) );
|
|
||||||
return in_array( $search, $values );
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @covers \MediaWiki\Skins\Vector\SkinVectorLegacy::getTemplateData
|
* @covers \MediaWiki\Skins\Vector\SkinVectorLegacy::getTemplateData
|
||||||
*/
|
*/
|
||||||
|
|
Loading…
Reference in a new issue