File tree Expand file tree Collapse file tree 1 file changed +8
-14
lines changed
app/code/Magento/Store/Test/Unit/Controller/Store Expand file tree Collapse file tree 1 file changed +8
-14
lines changed Original file line number Diff line number Diff line change @@ -146,20 +146,14 @@ protected function setUp()
146
146
public function testRedirect (string $ defaultStoreViewCode , string $ storeCode ): void
147
147
{
148
148
$ this ->requestMock
149
- ->expects ($ this ->at (0 ))
150
- ->method ('getParam ' )
151
- ->with (StoreResolver::PARAM_NAME )
152
- ->willReturn ($ storeCode );
153
- $ this ->requestMock
154
- ->expects ($ this ->at (1 ))
155
- ->method ('getParam ' )
156
- ->with ('___from_store ' )
157
- ->willReturn ($ defaultStoreViewCode );
158
- $ this ->requestMock
159
- ->expects ($ this ->at (2 ))
160
- ->method ('getParam ' )
161
- ->with (ActionInterface::PARAM_NAME_URL_ENCODED )
162
- ->willReturn ($ defaultStoreViewCode );
149
+ ->expects ($ this ->any ())
150
+ ->method ('getParam ' )->willReturnMap (
151
+ [
152
+ [StoreResolver::PARAM_NAME , null , $ storeCode ],
153
+ ['___from_store ' , null , $ defaultStoreViewCode ],
154
+ [ActionInterface::PARAM_NAME_URL_ENCODED , null , $ defaultStoreViewCode ]
155
+ ]
156
+ );
163
157
$ this ->storeRepositoryMock
164
158
->expects ($ this ->once ())
165
159
->method ('get ' )
You can’t perform that action at this time.
0 commit comments