You are here

public function ContainerTest::testIsFrozen in Zircon Profile 8

Same name and namespace in other branches
  1. 8.0 vendor/symfony/dependency-injection/Tests/ContainerTest.php \Symfony\Component\DependencyInjection\Tests\ContainerTest::testIsFrozen()

@covers Symfony\Component\DependencyInjection\Container::isFrozen

File

vendor/symfony/dependency-injection/Tests/ContainerTest.php, line 94

Class

ContainerTest

Namespace

Symfony\Component\DependencyInjection\Tests

Code

public function testIsFrozen() {
  $sc = new Container(new ParameterBag(array(
    'foo' => 'bar',
  )));
  $this
    ->assertFalse($sc
    ->isFrozen(), '->isFrozen() returns false if the parameters are not frozen');
  $sc
    ->compile();
  $this
    ->assertTrue($sc
    ->isFrozen(), '->isFrozen() returns true if the parameters are frozen');
}