File tree Expand file tree Collapse file tree 1 file changed +8
-2
lines changed
app/code/Magento/Backend/Test/Unit/Model/Session Expand file tree Collapse file tree 1 file changed +8
-2
lines changed Original file line number Diff line number Diff line change @@ -106,11 +106,12 @@ public function testSetCookiePathNonDefault()
106
106
107
107
/**
108
108
* Test for setting session name and secure_cookie for admin
109
+ * @dataProvider requestSecureDataProvider
110
+ * @param $secureRequest
109
111
*/
110
- public function testSetSessionSettingsByConstructor ()
112
+ public function testSetSessionSettingsByConstructor ($ secureRequest )
111
113
{
112
114
$ sessionName = 'admin ' ;
113
- $ secureRequest = true ;
114
115
$ this ->requestMock ->expects ($ this ->once ())->method ('isSecure ' )->willReturn ($ secureRequest );
115
116
116
117
$ validatorMock = $ this ->getMockBuilder ('Magento\Framework\Validator\ValidatorInterface ' )
@@ -139,4 +140,9 @@ public function testSetSessionSettingsByConstructor()
139
140
$ this ->assertSame ($ sessionName , $ adminConfig ->getName ());
140
141
$ this ->assertSame ($ secureRequest , $ adminConfig ->getCookieSecure ());
141
142
}
143
+
144
+ public function requestSecureDataProvider ()
145
+ {
146
+ return [[true ], [false ]];
147
+ }
142
148
}
You can’t perform that action at this time.
0 commit comments