You are here

public function InputDefinitionTest::testAddArguments in Zircon Profile 8

Same name and namespace in other branches
  1. 8.0 vendor/symfony/console/Tests/Input/InputDefinitionTest.php \Symfony\Component\Console\Tests\Input\InputDefinitionTest::testAddArguments()

File

vendor/symfony/console/Tests/Input/InputDefinitionTest.php, line 63

Class

InputDefinitionTest

Namespace

Symfony\Component\Console\Tests\Input

Code

public function testAddArguments() {
  $this
    ->initializeArguments();
  $definition = new InputDefinition();
  $definition
    ->addArguments(array(
    $this->foo,
  ));
  $this
    ->assertEquals(array(
    'foo' => $this->foo,
  ), $definition
    ->getArguments(), '->addArguments() adds an array of InputArgument objects');
  $definition
    ->addArguments(array(
    $this->bar,
  ));
  $this
    ->assertEquals(array(
    'foo' => $this->foo,
    'bar' => $this->bar,
  ), $definition
    ->getArguments(), '->addArguments() does not clear existing InputArgument objects');
}