@@ -424,6 +424,14 @@ public function testGetResult()
424
424
$ this ->assertInstanceOf (PaginatorInterface::class, $ result );
425
425
}
426
426
427
+ public function testGetResultWithoutFetchJoinCollection ()
428
+ {
429
+ $ result = $ this ->getPaginationExtensionResult (false , false , false );
430
+
431
+ $ this ->assertInstanceOf (PartialPaginatorInterface::class, $ result );
432
+ $ this ->assertInstanceOf (PaginatorInterface::class, $ result );
433
+ }
434
+
427
435
public function testGetResultWithPartial ()
428
436
{
429
437
$ result = $ this ->getPaginationExtensionResult (true );
@@ -440,15 +448,15 @@ public function testSimpleGetResult()
440
448
$ this ->assertInstanceOf (PaginatorInterface::class, $ result );
441
449
}
442
450
443
- private function getPaginationExtensionResult (bool $ partial = false , bool $ legacy = false )
451
+ private function getPaginationExtensionResult (bool $ partial = false , bool $ legacy = false , bool $ fetchJoinCollection = true )
444
452
{
445
453
$ requestStack = new RequestStack ();
446
454
$ requestStack ->push (new Request (['partial ' => $ partial ]));
447
455
448
456
$ resourceMetadataFactoryProphecy = $ this ->prophesize (ResourceMetadataFactoryInterface::class);
449
457
450
458
if (!$ legacy ) {
451
- $ resourceMetadataFactoryProphecy ->create ('Foo ' )->willReturn (new ResourceMetadata (null , null , null , [], [], ['pagination_partial ' => false , 'pagination_client_partial ' => true ]))->shouldBeCalled ();
459
+ $ resourceMetadataFactoryProphecy ->create ('Foo ' )->willReturn (new ResourceMetadata (null , null , null , [], [], ['pagination_partial ' => false , 'pagination_client_partial ' => true , ' pagination_fetch_join_collection ' => $ fetchJoinCollection ]))->shouldBeCalled ();
452
460
}
453
461
454
462
$ configuration = new Configuration ();
0 commit comments