# YAML Test Matrix

--- &test-4ABK
  Title: Flow Mapping Separate Values
  Tags: [ flow, mapping ]

YAML

{
unquoted : "separate",
http://foo.com,
omitted value:,
}

Expected Events

+STR
+DOC
+MAP
=VAL :unquoted
=VAL "separate
=VAL :http://foo.com
=VAL :
=VAL :omitted value
=VAL :
-MAP
-DOC
-STR

Expected JSON



c-libfyaml-event

 ok

cpp-yamlcpp-event

 ok

dotnet-yamldotnet-event

 ok

hs-hsyaml-event

 ok

java-snakeyaml-event

 ok

js-yaml-event

 ok

nim-nimyaml-event

 ok

perl-pp-event

 ok

py-pyyaml-event

 ok

py-ruamel-event

 diff
Got Events:
+STR
+DOC
+MAP
=VAL :unquoted
=VAL "separate
=VAL :http://foo.com
=VAL :
=VAL :omitted value:
=VAL :
-MAP
-DOC
-STR

c-libyaml-event

 error
+STR
+DOC
+MAP
=VAL :unquoted
=VAL "separate
=VAL :http://foo.com
=VAL :
Parse error: found unexpected ':'

perl-pplibyaml-event

 error
YAML::PP::LibYAML Error: The problem:

    found unexpected ':'

was found at , line: 4, column: 14
while scanning a plain scalar at line: 4, column: 1

perl-pplibyaml-perl

 error
YAML::PP::LibYAML Error: The problem:

    found unexpected ':'

was found at , line: 4, column: 14
while scanning a plain scalar at line: 4, column: 1

perl-syck-perl

 error
Syck parser (line 5, column 1): syntax error at /perl5/lib/perl5/x86_64-linux-thread-multi/YAML/Syck.pm line 60, <> line 1.

perl-xs-perl

 error
YAML::XS::Load Error: The problem:

    found unexpected ':'

was found at document: 1, line: 4, column: 14
while scanning a plain scalar at line: 4, column: 1

perl-yaml-perl

 error
YAML Error: Expected separator '---'
   Code: YAML_PARSE_ERR_NO_SEPARATOR
   Line: 1
   Document: 2
 at /perl5/lib/perl5/YAML/Loader.pm line 88.

c-libfyaml-json

 na
{
  "unquoted": "separate",
  "http://foo.com": null,
  "omitted value": null
}

dotnet-yamldotnet-json

 na
{"unquoted": "separate", "http://foo.com": null, "omitted value": null}

hs-hsyaml-json

 na
{"http://foo.com":null,"omitted value":null,"unquoted":"separate"}

java-snakeyaml-json

 na
{
  "unquoted": "separate"
}

js-jsyaml-json

 na
{"unquoted":"separate","http://foo.com":null,"omitted value":null}

js-yaml-json

 na
{
  "unquoted": "separate",
  "http://foo.com": null,
  "omitted value": null
}

lua-lyaml-json

 na
luajit: 3:15: found unexpected ':'
stack traceback:
	[C]: in function 'error'
	/usr/local/share/lua/5.1/lyaml/init.lua:291: in function 'error'
	/usr/local/share/lua/5.1/lyaml/init.lua:310: in function 'parse'
	/usr/local/share/lua/5.1/lyaml/init.lua:428: in function 'load_node'
	/usr/local/share/lua/5.1/lyaml/init.lua:325: in function 'load_node'
	/usr/local/share/lua/5.1/lyaml/init.lua:482: in function 'load'
	/yaml/bin/lua-lyaml-json:6: in main chunk
	[C]: at 0x55d30b5b9f97

perl-pp-json

 na
{
   "http://foo.com" : null,
   "omitted value" : null,
   "unquoted" : "separate"
}

perl-pp-perl

 na
{
  'http://foo.com' => undef,
  'omitted value' => undef,
  'unquoted' => 'separate'
}

perl-pplibyaml-json

 na
YAML::PP::LibYAML Error: The problem:

    found unexpected ':'

was found at , line: 4, column: 14
while scanning a plain scalar at line: 4, column: 1

perl-syck-json

 na
Syck parser (line 5, column 1): syntax error at /perl5/lib/perl5/x86_64-linux-thread-multi/YAML/Syck.pm line 60, <> line 1.

perl-tiny-json

 na
YAML::Tiny failed to classify line '{' at /yaml/bin/perl-tiny-json line 12.

perl-xs-json

 na
YAML::XS::Load Error: The problem:

    found unexpected ':'

was found at document: 1, line: 4, column: 14
while scanning a plain scalar at line: 4, column: 1

perl-yaml-json

 na
YAML Error: Expected separator '---'
   Code: YAML_PARSE_ERR_NO_SEPARATOR
   Line: 1
   Document: 2
 at /perl5/lib/perl5/YAML/Loader.pm line 88.

py-pyyaml-json

 na
{
  "http://foo.com": null,
  "omitted value": null,
  "unquoted": "separate"
}

py-pyyaml-py

 na
{'http://foo.com': None, 'omitted value': None, 'unquoted': 'separate'}

py-ruamel-json

 na
{
  "http://foo.com": null,
  "omitted value:": null,
  "unquoted": "separate"
}

py-ruamel-py

 na
{'http://foo.com': None, 'omitted value:': None, 'unquoted': 'separate'}

ruby-psych-json

 na
/usr/lib/ruby/2.5.0/psych.rb:405:in `parse': (<unknown>): found unexpected ':' while scanning a plain scalar at line 4 column 1 (Psych::SyntaxError)
	from /usr/lib/ruby/2.5.0/psych.rb:405:in `parse_stream'
	from /usr/lib/ruby/2.5.0/psych.rb:488:in `load_stream'
	from /yaml/bin/ruby-psych-json:6:in `<main>'

perl-tiny-perl

 ni
YAML::Tiny failed to classify line '{' at /yaml/bin/perl-tiny-perl line 15.