You are here

public function ArrayInputTest::provideOptions in Zircon Profile 8

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

File

vendor/symfony/console/Tests/Input/ArrayInputTest.php, line 67

Class

ArrayInputTest

Namespace

Symfony\Component\Console\Tests\Input

Code

public function provideOptions() {
  return array(
    array(
      array(
        '--foo' => 'bar',
      ),
      array(
        new InputOption('foo'),
      ),
      array(
        'foo' => 'bar',
      ),
      '->parse() parses long options',
    ),
    array(
      array(
        '--foo' => 'bar',
      ),
      array(
        new InputOption('foo', 'f', InputOption::VALUE_OPTIONAL, '', 'default'),
      ),
      array(
        'foo' => 'bar',
      ),
      '->parse() parses long options with a default value',
    ),
    array(
      array(
        '--foo' => null,
      ),
      array(
        new InputOption('foo', 'f', InputOption::VALUE_OPTIONAL, '', 'default'),
      ),
      array(
        'foo' => 'default',
      ),
      '->parse() parses long options with a default value',
    ),
    array(
      array(
        '-f' => 'bar',
      ),
      array(
        new InputOption('foo', 'f'),
      ),
      array(
        'foo' => 'bar',
      ),
      '->parse() parses short options',
    ),
  );
}