diff --git a/tests/Functional/Parameters/UriVariableParameterProviderTest.php b/tests/Functional/Parameters/UriVariableParameterProviderTest.php index b7307a9cc2..b1d019461c 100644 --- a/tests/Functional/Parameters/UriVariableParameterProviderTest.php +++ b/tests/Functional/Parameters/UriVariableParameterProviderTest.php @@ -37,6 +37,10 @@ public static function getResources(): array protected function setUp(): void { + if ('mongodb' === static::getContainer()->getParameter('kernel.environment')) { + $this->markTestSkipped(); + } + $this->recreateSchema([Base64UriVariableDummy::class, Dummy::class]); } @@ -45,11 +49,6 @@ protected function setUp(): void */ public function testLinkParameterProviderDecodesUriVariableBeforeQuery(): void { - $container = static::getContainer(); - if ('mongodb' === $container->getParameter('kernel.environment')) { - $this->markTestSkipped(); - } - $manager = $this->getManager(); $dummy = new Base64UriVariableDummy(); $dummy->name = 'Blip'; @@ -63,11 +62,6 @@ public function testLinkParameterProviderDecodesUriVariableBeforeQuery(): void public function testReadLinkParameterProviderWritesResolvedResourceWhenOptedIn(): void { - $container = static::getContainer(); - if ('mongodb' === $container->getParameter('kernel.environment')) { - $this->markTestSkipped(); - } - $manager = $this->getManager(); $dummy = new Dummy(); $dummy->setName('hi');