From 3141c3f8b5fd1a45d337c1f5540cb715a5a7dbbf Mon Sep 17 00:00:00 2001 From: Igor Scheller Date: Wed, 20 Sep 2017 01:21:36 +0200 Subject: Fixed Container test --- tests/Unit/Container/ContainerTest.php | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'tests/Unit') diff --git a/tests/Unit/Container/ContainerTest.php b/tests/Unit/Container/ContainerTest.php index f0ba24e7..89c34209 100644 --- a/tests/Unit/Container/ContainerTest.php +++ b/tests/Unit/Container/ContainerTest.php @@ -85,6 +85,12 @@ class ContainerTest extends TestCase */ public function testContainerSingleton() { + // Ensure that no container has been initialized + $reflection = new \ReflectionProperty(Container::class, 'instance'); + $reflection->setAccessible(true); + $reflection->setValue(null, null); + $reflection->setAccessible(false); + $container0 = new Container(); $container = Container::getInstance(); -- cgit v1.2.3-54-g00ecf