test: 🚨 fix test

This commit is contained in:
alistair3149 2024-05-15 01:17:39 -04:00
parent d8afbf55fc
commit e2cc430ffa
No known key found for this signature in database
2 changed files with 3 additions and 2 deletions

View file

@ -58,6 +58,7 @@ class CitizenComponentLink implements CitizenComponent {
} }
} }
return [ return [
'href' => $this->href,
'icon' => $this->icon, 'icon' => $this->icon,
'text' => $this->text, 'text' => $this->text,
'array-attributes' => [ 'array-attributes' => [

View file

@ -20,7 +20,7 @@ class CitizenComponentLinkTest extends MediaWikiUnitTestCase {
* @covers ::getTemplateData * @covers ::getTemplateData
*/ */
public function testGetTemplateData() { public function testGetTemplateData() {
//$href = '/mock-link'; $href = '/mock-link';
$text = 'Mock Text'; $text = 'Mock Text';
$icon = 'mock-icon'; $icon = 'mock-icon';
$accessKeyHint = 'sample-accesskey'; $accessKeyHint = 'sample-accesskey';
@ -45,7 +45,7 @@ class CitizenComponentLinkTest extends MediaWikiUnitTestCase {
// Assert the expected values // Assert the expected values
$this->assertEquals( $icon, $actual['icon'] ); $this->assertEquals( $icon, $actual['icon'] );
$this->assertEquals( $text, $actual['text'] ); $this->assertEquals( $text, $actual['text'] );
//$this->assertEquals( $href, $actual['href'] ); $this->assertEquals( $href, $actual['href'] );
// New assertions for HTML attributes // New assertions for HTML attributes
$expectedTitle = "tooltip-sample-accesskeyword-separatorbrackets"; $expectedTitle = "tooltip-sample-accesskeyword-separatorbrackets";