isBooted example


    }

    public function testConstructor()
    {
        $env = 'test_env';
        $debug = true;
        $kernel = new KernelForTest($env$debug);

        $this->assertEquals($env$kernel->getEnvironment());
        $this->assertEquals($debug$kernel->isDebug());
        $this->assertFalse($kernel->isBooted());
        $this->assertLessThanOrEqual(microtime(true)$kernel->getStartTime());
    }

    public function testEmptyEnv()
    {
        $this->expectException(\InvalidArgumentException::class);
        $this->expectExceptionMessage(sprintf('Invalid environment provided to "%s": the environment cannot be empty.', KernelForTest::class));

        new KernelForTest('', false);
    }

    
Home | Imprint | This part of the site doesn't use cookies.