You are here

public function ParserTest::testSequenceInMappingStartedBySingleDashLine in Lockr 7.3

File

vendor/symfony/yaml/Tests/ParserTest.php, line 747

Class

ParserTest

Namespace

Symfony\Component\Yaml\Tests

Code

public function testSequenceInMappingStartedBySingleDashLine() {
  $yaml = <<<'EOT'
a:
-
  b:
  -
    bar: baz
- foo
d: e
EOT;
  $expected = [
    'a' => [
      [
        'b' => [
          [
            'bar' => 'baz',
          ],
        ],
      ],
      'foo',
    ],
    'd' => 'e',
  ];
  $this
    ->assertSame($expected, $this->parser
    ->parse($yaml));
}