# YAML Test Matrix

--- &test-93JH
  Title: Block Mappings in Block Sequence
  Tags: [ mapping, sequence ]

YAML

 - key: value
   key2: value2
 -
   key3: value3

Expected Events

+STR
+DOC
+SEQ
+MAP
=VAL :key
=VAL :value
=VAL :key2
=VAL :value2
-MAP
+MAP
=VAL :key3
=VAL :value3
-MAP
-SEQ
-DOC
-STR

Expected JSON

[
{
"key": "value",
"key2": "value2"
},
{
"key3": "value3"
}
]

c-libfyaml-event

 ok

c-libyaml-event

 ok

cpp-rapidyaml-event

 ok

cpp-yamlcpp-event

 ok

dotnet-yamldotnet-event

 ok

hs-hsyaml-event

 ok

js-yaml-event

 ok

nim-nimyaml-event

 ok

perl-pp-event

 ok

perl-refparser-event

 ok

py-pyyaml-event

 ok

py-ruamel-event

 ok

rust-yamlrust-event

 ok

c-libfyaml-json

 json_ok

dotnet-yamldotnet-json

 json_ok

go-yaml-json

 json_ok

hs-hsyaml-json

 json_ok

js-jsyaml-json

 json_ok

js-yaml-json

 json_ok

lua-lyaml-json

 json_ok

perl-pp-json

 json_ok

perl-pplibyaml-json

 json_ok

perl-syck-json

 json_ok

perl-xs-json

 json_ok

perl-yaml-json

 json_ok

py-pyyaml-json

 json_ok

py-ruamel-json

 json_ok

ruby-psych-json

 json_ok

perl-tiny-json

 error
YAML::Tiny found bad indenting in line ' - key: value' at /yaml/bin/perl-tiny-json line 12.

perl-tiny-perl

 error
YAML::Tiny found bad indenting in line ' - key: value' at /yaml/bin/perl-tiny-perl line 15.

hs-reference-yeast

 na
Line  Col Char Byte Token|Content
   1    0    0    0 +DOC |
   1    0    0    0 +NODE|
   1    0    0    0 +SEQ |
   1    0    0    0 =DENT|.
   1    1    1    1 =SYNX|-
   1    2    2    2 =DENT|.
   1    3    3    3 +NODE|
   1    3    3    3 +MAP |
   1    3    3    3 +PAIR|
   1    3    3    3 +NODE|
   1    3    3    3 +VAL |
   1    3    3    3 =TEXT|key
   1    6    6    6 -VAL |
   1    6    6    6 -NODE|
   1    6    6    6 =SYNX|:
   1    7    7    7 =WSPC|.
   1    8    8    8 +NODE|
   1    8    8    8 +VAL |
   1    8    8    8 =TEXT|value
   1   13   13   13 -VAL |
   1   13   13   13 -NODE|
   1   13   13   13 =EOL |\x0a
   2    0   14   14 -PAIR|
   2    0   14   14 =DENT|...
   2    3   17   17 +PAIR|
   2    3   17   17 +NODE|
   2    3   17   17 +VAL |
   2    3   17   17 =TEXT|key2
   2    7   21   21 -VAL |
   2    7   21   21 -NODE|
   2    7   21   21 =SYNX|:
   2    8   22   22 =WSPC|.
   2    9   23   23 +NODE|
   2    9   23   23 +VAL |
   2    9   23   23 =TEXT|value2
   2   15   29   29 -VAL |
   2   15   29   29 -NODE|
   2   15   29   29 =EOL |\x0a
   3    0   30   30 -PAIR|
   3    0   30   30 -MAP |
   3    0   30   30 -NODE|
   3    0   30   30 =DENT|.
   3    1   31   31 =SYNX|-
   3    2   32   32 +NODE|
   3    2   32   32 =EOL |\x0a
   4    0   33   33 +MAP |
   4    0   33   33 =DENT|...
   4    3   36   36 +PAIR|
   4    3   36   36 +NODE|
   4    3   36   36 +VAL |
   4    3   36   36 =TEXT|key3
   4    7   40   40 -VAL |
   4    7   40   40 -NODE|
   4    7   40   40 =SYNX|:
   4    8   41   41 =WSPC|.
   4    9   42   42 +NODE|
   4    9   42   42 +VAL |
   4    9   42   42 =TEXT|value3
   4   15   48   48 -VAL |
   4   15   48   48 -NODE|
   4   15   48   48 =EOL |\x0a
   5    0   49   49 -PAIR|
   5    0   49   49 -MAP |
   5    0   49   49 -NODE|
   5    0   49   49 -SEQ |
   5    0   49   49 -NODE|
   5    0   49   49 -DOC |

perl-pp-perl

 na
[
  {
    'key' => 'value',
    'key2' => 'value2'
  },
  {
    'key3' => 'value3'
  }
]

perl-pplibyaml-perl

 na
[
  {
    'key' => 'value',
    'key2' => 'value2'
  },
  {
    'key3' => 'value3'
  }
]

perl-syck-perl

 na
[
  {
    'key' => 'value',
    'key2' => 'value2'
  },
  {
    'key3' => 'value3'
  }
]

perl-xs-perl

 na
[
  {
    'key' => 'value',
    'key2' => 'value2'
  },
  {
    'key3' => 'value3'
  }
]

perl-yaml-perl

 na
[
  {
    'key' => 'value',
    'key2' => 'value2'
  },
  {
    'key3' => 'value3'
  }
]

py-pyyaml-py

 na
[{'key': 'value', 'key2': 'value2'}, {'key3': 'value3'}]

py-ruamel-py

 na
[{'key': 'value', 'key2': 'value2'}, {'key3': 'value3'}]