You are here

public function LintCommandTest::testConstantAsKey in Lockr 7.3

File

vendor/symfony/yaml/Tests/Command/LintCommandTest.php, line 54

Class

LintCommandTest
Tests the YamlLintCommand.

Namespace

Symfony\Component\Yaml\Tests\Command

Code

public function testConstantAsKey() {
  $yaml = <<<YAML
!php/const 'Symfony\\Component\\Yaml\\Tests\\Command\\Foo::TEST': bar
YAML;
  $ret = $this
    ->createCommandTester()
    ->execute([
    'filename' => $this
      ->createFile($yaml),
  ], [
    'verbosity' => OutputInterface::VERBOSITY_VERBOSE,
    'decorated' => false,
  ]);
  $this
    ->assertSame(0, $ret, 'lint:yaml exits with code 0 in case of success');
}