File tree Expand file tree Collapse file tree 1 file changed +6
-2
lines changed
Expand file tree Collapse file tree 1 file changed +6
-2
lines changed Original file line number Diff line number Diff line change 1717use Symfony \Cmf \Component \Testing \Functional \DbManager \PhpcrDecorator ;
1818use Symfony \Component \DependencyInjection \ContainerInterface ;
1919use Symfony \Component \HttpFoundation \Response ;
20+ use Symfony \Component \HttpKernel \KernelInterface ;
2021
2122/**
2223 * The base class for Functional and Web tests.
@@ -80,12 +81,15 @@ public function getContainer()
8081 /**
8182 * Ensures the kernel is available.
8283 *
83- * @return \Symfony\Component\HttpKernel\ KernelInterface
84+ * @return KernelInterface
8485 */
8586 public function getKernel ()
8687 {
8788 if (null === self ::$ kernel ) {
88- self ::$ kernel = parent ::bootKernel ();
89+ $ kernel = parent ::bootKernel ();
90+ if ($ kernel instanceof KernelInterface) {
91+ self ::$ kernel = $ kernel ;
92+ }
8993 }
9094 if (!self ::$ kernel ->getContainer ()) {
9195 self ::$ kernel ->boot ();
You can’t perform that action at this time.
0 commit comments