# YAML Test Matrix

--- &test-H2RW
  Title: Blank lines
  Tags: [ comment, scalar ]

YAML

foo: 1

bar: 2
    
text: |
  a
    
  b

  c
 
  d

Expected Events

+STR
+DOC
+MAP
=VAL :foo
=VAL :1
=VAL :bar
=VAL :2
=VAL :text
=VAL |a\n  \nb\n\nc\n\nd\n
-MAP
-DOC
-STR

Expected JSON

{
"foo": 1,
"bar": 2,
"text": "a\n \nb\n\nc\n\nd\n"
}

cpp-event

 ok

hs-yaml-event

 ok

java-event

 ok

libyaml-event

 ok

nimyaml-event

 ok

perl5-pegex-event

 ok

perl5-pp-event

 ok

pyyaml-event

 ok

ruamel-event

 ok

hs-yaml-json

 json_ok

java-json

 json_ok

js-yaml-json

 json_ok

luajit-json

 json_ok

perl5-pm-json

 json_ok

perl5-pp-json

 json_ok

perl5-xs-json

 json_ok

pyyaml-json

 json_ok

ruamel-json

 json_ok

ruby-json

 json_ok

perl5-syck-json

 json_diff
{
  "bar": 2,
  "foo": 1,
  "text": "a\n\nb\n\nc\n\nd\n"
}

perl5-tiny-json

 json_diff
{
  "bar": "2",
  "foo": "1",
  "text": "a\nb\nc\nd\n"
}

perl5-pm-pl

 na
{
  'bar' => 2,
  'foo' => 1,
  'text' => 'a
  
b

c

d
'
}

perl5-pp-pl

 na
{
  'bar' => 2,
  'foo' => 1,
  'text' => 'a
  
b

c

d
'
}

perl5-syck-pl

 na
{
  'bar' => 2,
  'foo' => 1,
  'text' => 'a

b

c

d
'
}

perl5-tiny-pl

 na
{
  'bar' => '2',
  'foo' => '1',
  'text' => 'a
b
c
d
'
}

perl5-xs-pl

 na
{
  'bar' => 2,
  'foo' => 1,
  'text' => 'a
  
b

c

d
'
}

pyyaml-py

 na
{'bar': 2, 'foo': 1, 'text': 'a\n  \nb\n\nc\n\nd\n'}

ruamel-py

 na
{'bar': 2, 'foo': 1, 'text': 'a\n  \nb\n\nc\n\nd\n'}