فهرست منبع

fixed unit tests

Fabien Potencier 14 سال پیش
والد
کامیت
e684a81b96
1فایلهای تغییر یافته به همراه18 افزوده شده و 0 حذف شده
  1. 18 0
      src/Symfony/Bundle/FrameworkBundle/Tests/Kernel.php

+ 18 - 0
src/Symfony/Bundle/FrameworkBundle/Tests/Kernel.php

@@ -78,4 +78,22 @@ class Kernel extends BaseKernel
             $container->setParameter('kernel.compiled_classes', array());
         });
     }
+
+    public function boot()
+    {
+        if (true === $this->booted) {
+            throw new \LogicException('The kernel is already booted.');
+        }
+
+        $this->bundles = $this->registerBundles();
+        $this->bundleDirs = $this->registerBundleDirs();
+        $this->container = $this->initializeContainer();
+
+        foreach ($this->bundles as $bundle) {
+            $bundle->setContainer($this->container);
+            $bundle->boot();
+        }
+
+        $this->booted = true;
+    }
 }