You are here

public function InputDefinitionTest::testAddDuplicateOption 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::testAddDuplicateOption()

@expectedException \LogicException @expectedExceptionMessage An option named "foo" already exists.

File

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

Class

InputDefinitionTest

Namespace

Symfony\Component\Console\Tests\Input

Code

public function testAddDuplicateOption() {
  $this
    ->initializeOptions();
  $definition = new InputDefinition();
  $definition
    ->addOption($this->foo);
  $definition
    ->addOption($this->foo2);
}