@@ -87,8 +87,8 @@ protected function setUp()
87
87
{
88
88
$ this ->collectionFactory =
89
89
$ this ->getMockBuilder (\Magento \Catalog \Model \ResourceModel \Product \CollectionFactory::class)
90
- ->setMethods (['create ' ])
91
- ->disableOriginalConstructor ()->getMock ();
90
+ ->setMethods (['create ' ])
91
+ ->disableOriginalConstructor ()->getMock ();
92
92
$ this ->visibility = $ this ->getMockBuilder (\Magento \Catalog \Model \Product \Visibility::class)
93
93
->setMethods (['getVisibleInCatalogIds ' ])
94
94
->disableOriginalConstructor ()
@@ -144,6 +144,8 @@ public function testGetCacheKeyInfo()
144
144
$ this ->productsList ->setData ('conditions ' , 'some_serialized_conditions ' );
145
145
146
146
$ this ->productsList ->setData ('page_var_name ' , 'page_number ' );
147
+ $ this ->productsList ->setTemplate ('test_template ' );
148
+ $ this ->productsList ->setData ('title ' , 'test_title ' );
147
149
$ this ->request ->expects ($ this ->once ())->method ('getParam ' )->with ('page_number ' )->willReturn (1 );
148
150
149
151
$ this ->request ->expects ($ this ->once ())->method ('getParams ' )->willReturn ('request_params ' );
@@ -166,7 +168,9 @@ public function testGetCacheKeyInfo()
166
168
1 ,
167
169
5 ,
168
170
'some_serialized_conditions ' ,
169
- json_encode ('request_params ' )
171
+ json_encode ('request_params ' ),
172
+ 'test_template ' ,
173
+ 'test_title '
170
174
];
171
175
$ this ->assertEquals ($ cacheKey , $ this ->productsList ->getCacheKeyInfo ());
172
176
}
@@ -251,9 +255,10 @@ public function testGetPagerHtml()
251
255
* Test public `createCollection` method and protected `getPageSize` method via `createCollection`
252
256
*
253
257
* @param bool $pagerEnable
254
- * @param int $productsCount
255
- * @param int $productsPerPage
256
- * @param int $expectedPageSize
258
+ * @param int $productsCount
259
+ * @param int $productsPerPage
260
+ * @param int $expectedPageSize
261
+ *
257
262
* @dataProvider createCollectionDataProvider
258
263
*/
259
264
public function testCreateCollection ($ pagerEnable , $ productsCount , $ productsPerPage , $ expectedPageSize )
@@ -382,6 +387,7 @@ public function testGetIdentities()
382
387
383
388
/**
384
389
* @param $collection
390
+ *
385
391
* @return \PHPUnit_Framework_MockObject_MockObject
386
392
*/
387
393
private function getConditionsForCollection ($ collection )
0 commit comments