File tree Expand file tree Collapse file tree 1 file changed +10
-0
lines changed
src/Symfony/Tests/Bundle/DependencyInjection Expand file tree Collapse file tree 1 file changed +10
-0
lines changed Original file line number Diff line number Diff line change @@ -381,4 +381,14 @@ public function testPaginationMaximumItemsPerPageIsSetWithZero(): void
381381
382382 $ this ->assertSame (0 , $ this ->container ->getParameter ('api_platform.collection.pagination.maximum_items_per_page ' ));
383383 }
384+
385+ public function testPaginationMaximumItemsPerPageWhenDefaultsKeyIsMissing (): void
386+ {
387+ $ config = self ::DEFAULT_CONFIG ;
388+ unset($ config ['api_platform ' ]['defaults ' ]);
389+ (new ApiPlatformExtension ())->load ($ config , $ this ->container );
390+
391+ $ this ->assertTrue ($ this ->container ->hasParameter ('api_platform.collection.pagination.maximum_items_per_page ' ));
392+ $ this ->assertSame (30 , $ this ->container ->getParameter ('api_platform.collection.pagination.maximum_items_per_page ' ));
393+ }
384394}
You can’t perform that action at this time.
0 commit comments