@@ -142,7 +142,7 @@ public function testGetCsvFile()
142
142
->method ('getFields ' )
143
143
->with ($ this ->component )
144
144
->willReturn ([]);
145
- $ this ->metadataProvider ->expects ($ this ->exactly ( 2 ))
145
+ $ this ->metadataProvider ->expects ($ this ->any ( ))
146
146
->method ('getRowData ' )
147
147
->willReturnCallback (
148
148
function ($ arg1 , $ arg2 , $ arg3 ) use ($ document1 , $ document2 , $ data ) {
@@ -153,7 +153,7 @@ function ($arg1, $arg2, $arg3) use ($document1, $document2, $data) {
153
153
}
154
154
}
155
155
);
156
- $ this ->metadataProvider ->expects ($ this ->exactly ( 2 ))
156
+ $ this ->metadataProvider ->expects ($ this ->any ( ))
157
157
->method ('convertDate ' )
158
158
->willReturnCallback (
159
159
function ($ arg1 , $ arg2 ) use ($ document1 , $ document2 , $ componentName ) {
@@ -245,25 +245,25 @@ private function mockComponent(string $componentName, array $page1Items, array $
245
245
->method ('getDataProvider ' )
246
246
->willReturn ($ dataProvider );
247
247
248
- $ dataProvider ->expects ($ this ->exactly (3 ))
248
+ $ dataProvider ->expects ($ this ->exactly (2 ))
249
249
->method ('getSearchResult ' )
250
250
->willReturnOnConsecutiveCalls ($ searchResult0 , $ searchResult1 , $ searchResult2 );
251
251
252
252
$ dataProvider ->expects ($ this ->once ())
253
253
->method ('getSearchCriteria ' )
254
254
->willReturn ($ searchCriteria );
255
255
256
- $ searchResult1 ->expects ($ this ->once ())
256
+ $ searchResult1 ->expects ($ this ->any ())
257
257
->method ('setTotalCount ' );
258
258
259
- $ searchResult2 ->expects ($ this ->once ())
259
+ $ searchResult2 ->expects ($ this ->any ())
260
260
->method ('setTotalCount ' );
261
261
262
- $ searchResult1 ->expects ($ this ->once ())
262
+ $ searchResult1 ->expects ($ this ->any ())
263
263
->method ('getItems ' )
264
264
->willReturn ($ page1Items );
265
265
266
- $ searchResult2 ->expects ($ this ->once ())
266
+ $ searchResult2 ->expects ($ this ->any ())
267
267
->method ('getItems ' )
268
268
->willReturn ($ page2Items );
269
269
0 commit comments