This repository was archived by the owner on Apr 29, 2019. It is now read-only.
File tree 1 file changed +4
-3
lines changed
lib/internal/Magento/Framework/View/Test/Unit/Element/Html
1 file changed +4
-3
lines changed Original file line number Diff line number Diff line change @@ -11,6 +11,7 @@ class LinkTest extends \PHPUnit\Framework\TestCase
11
11
* @var array
12
12
*/
13
13
protected $ allowedAttributes = [
14
+ 'href ' ,
14
15
'shape ' ,
15
16
'tabindex ' ,
16
17
'onfocus ' ,
@@ -51,7 +52,7 @@ public function getLinkAttributesDataProvider()
51
52
52
53
$ urlBuilderMock ->expects ($ this ->any ())
53
54
->method ('getUrl ' )
54
- ->will ($ this ->returnArgument ('http://site.com/link.html ' ));
55
+ ->will ($ this ->returnValue ('http://site.com/link.html ' ));
55
56
56
57
$ validtorMock = $ this ->getMockBuilder (\Magento \Framework \View \Element \Template \File \Validator::class)
57
58
->setMethods (['isValid ' ])->disableOriginalConstructor ()->getMock ();
@@ -105,11 +106,11 @@ public function getLinkAttributesDataProvider()
105
106
return [
106
107
'full ' => [
107
108
'link ' => $ linkWithAttributes ,
108
- 'expected ' => 'shape="shape" tabindex="tabindex" onfocus="onfocus" onblur="onblur" id="id" ' ,
109
+ 'expected ' => 'href="http://site.com/link.html" shape="shape" tabindex="tabindex" onfocus="onfocus" onblur="onblur" id="id" ' ,
109
110
],
110
111
'empty ' => [
111
112
'link ' => $ linkWithoutAttributes ,
112
- 'expected ' => '' ,
113
+ 'expected ' => 'href="http://site.com/link.html" ' ,
113
114
],
114
115
];
115
116
}
You can’t perform that action at this time.
0 commit comments