You are here

public function ParserTest::testCommentAtTheRootIndent in Database Sanitize 7

File

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

Class

ParserTest

Namespace

Symfony\Component\Yaml\Tests

Code

public function testCommentAtTheRootIndent() {
  $this
    ->assertEquals(array(
    'services' => array(
      'app.foo_service' => array(
        'class' => 'Foo',
      ),
      'app/bar_service' => array(
        'class' => 'Bar',
      ),
    ),
  ), Yaml::parse(<<<'EOF'
# comment 1
services:
# comment 2
    # comment 3
    app.foo_service:
        class: Foo
# comment 4
    # comment 5
    app/bar_service:
        class: Bar
EOF
));
}