You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
* Gets the path to the bundles configuration file.
98
+
*/
99
+
privatefunctiongetBundlesPath(): string
100
+
{
101
+
return$this->getConfigDir().'/bundles.php';
102
+
}
65
103
66
104
/**
67
105
* {@inheritdoc}
@@ -126,23 +164,18 @@ public function registerContainerConfiguration(LoaderInterface $loader)
126
164
$container->addObjectResource($this);
127
165
$container->fileExists($this->getBundlesPath());
128
166
129
-
try {
130
-
$configureContainer = new \ReflectionMethod($this, 'configureContainer');
131
-
} catch (\ReflectionException$e) {
132
-
thrownew \LogicException(sprintf('"%s" uses "%s", but does not implement the required method "protected function configureContainer(ContainerConfigurator $container): void".', get_debug_type($this), MicroKernelTrait::class), 0, $e);
133
-
}
134
-
167
+
$configureContainer = new \ReflectionMethod($this, 'configureContainer');
@@ -174,12 +207,7 @@ public function loadRoutes(LoaderInterface $loader): RouteCollection
174
207
$kernelLoader->setCurrentDir(\dirname($file));
175
208
$collection = newRouteCollection();
176
209
177
-
try {
178
-
$configureRoutes = new \ReflectionMethod($this, 'configureRoutes');
179
-
} catch (\ReflectionException$e) {
180
-
thrownew \LogicException(sprintf('"%s" uses "%s", but does not implement the required method "protected function configureRoutes(RoutingConfigurator $routes): void".', get_debug_type($this), MicroKernelTrait::class), 0, $e);
181
-
}
182
-
210
+
$configureRoutes = new \ReflectionMethod($this, 'configureRoutes');
$this->expectExceptionMessage('"Symfony\Bundle\FrameworkBundle\Tests\Kernel\MinimalKernel@anonymous" uses "Symfony\Bundle\FrameworkBundle\Kernel\MicroKernelTrait", but does not implement the required method "protected function configureContainer(ContainerConfigurator $container): void".');
$this->expectExceptionMessage('"Symfony\Bundle\FrameworkBundle\Tests\Kernel\MinimalKernel@anonymous" uses "Symfony\Bundle\FrameworkBundle\Kernel\MicroKernelTrait", but does not implement the required method "protected function configureRoutes(RoutingConfigurator $routes): void".');
0 commit comments