From 8c168eb370c1224b99a79d65392cd22b0263f4fa Mon Sep 17 00:00:00 2001 From: Javier Eguiluz Date: Thu, 19 Oct 2017 09:46:40 +0200 Subject: [PATCH] Updated bootKernel examples to return the $kernel object --- console.rst | 4 ++-- testing/doctrine.rst | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/console.rst b/console.rst index 37af8d1b040..9fa8cf6c92a 100644 --- a/console.rst +++ b/console.rst @@ -224,8 +224,8 @@ console:: { public function testExecute() { - self::bootKernel(); - $application = new Application(self::$kernel); + $kernel = self::bootKernel(); + $application = new Application($kernel); $application->add(new CreateUserCommand()); diff --git a/testing/doctrine.rst b/testing/doctrine.rst index dc477855b10..f7ab2898f3a 100644 --- a/testing/doctrine.rst +++ b/testing/doctrine.rst @@ -36,9 +36,9 @@ which makes all of this quite easy:: */ protected function setUp() { - self::bootKernel(); + $kernel = self::bootKernel(); - $this->em = static::$kernel->getContainer() + $this->em = $kernel->getContainer() ->get('doctrine') ->getManager(); }