You are here

public function KernelTest::testClone in Zircon Profile 8.0

Same name and namespace in other branches
  1. 8 vendor/symfony/http-kernel/Tests/KernelTest.php \Symfony\Component\HttpKernel\Tests\KernelTest::testClone()

File

vendor/symfony/http-kernel/Tests/KernelTest.php, line 40

Class

KernelTest

Namespace

Symfony\Component\HttpKernel\Tests

Code

public function testClone() {
  $env = 'test_env';
  $debug = true;
  $kernel = new KernelForTest($env, $debug);
  $clone = clone $kernel;
  $this
    ->assertEquals($env, $clone
    ->getEnvironment());
  $this
    ->assertEquals($debug, $clone
    ->isDebug());
  $this
    ->assertFalse($clone
    ->isBooted());
  $this
    ->assertLessThanOrEqual(microtime(true), $clone
    ->getStartTime());
  $this
    ->assertNull($clone
    ->getContainer());
}