You are here

public function ParameterBagTest::testRemove in Zircon Profile 8

Same name in this branch
  1. 8 vendor/symfony/http-foundation/Tests/ParameterBagTest.php \Symfony\Component\HttpFoundation\Tests\ParameterBagTest::testRemove()
  2. 8 vendor/symfony/dependency-injection/Tests/ParameterBag/ParameterBagTest.php \Symfony\Component\DependencyInjection\Tests\ParameterBag\ParameterBagTest::testRemove()
Same name and namespace in other branches
  1. 8.0 vendor/symfony/http-foundation/Tests/ParameterBagTest.php \Symfony\Component\HttpFoundation\Tests\ParameterBagTest::testRemove()

File

vendor/symfony/http-foundation/Tests/ParameterBagTest.php, line 48

Class

ParameterBagTest

Namespace

Symfony\Component\HttpFoundation\Tests

Code

public function testRemove() {
  $bag = new ParameterBag(array(
    'foo' => 'bar',
  ));
  $bag
    ->add(array(
    'bar' => 'bas',
  ));
  $this
    ->assertEquals(array(
    'foo' => 'bar',
    'bar' => 'bas',
  ), $bag
    ->all());
  $bag
    ->remove('bar');
  $this
    ->assertEquals(array(
    'foo' => 'bar',
  ), $bag
    ->all());
}