# YAML Test Matrix

--- &test-K858
  Title: Spec Example 8.6. Empty Scalar Chomping
  Tags: [ folded, literal, spec, whitespace ]

YAML

strip: >-

clip: >

keep: |+

Expected Events

+STR
+DOC
+MAP
=VAL :strip
=VAL >
=VAL :clip
=VAL >
=VAL :keep
=VAL |\n
-MAP
-DOC
-STR

Expected JSON

{
"clip": "",
"keep": "\n",
"strip": ""
}

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-xs-json

 json_ok

py-pyyaml-json

 json_ok

py-ruamel-json

 json_ok

ruby-psych-json

 json_ok

perl-syck-json

 json_diff
{
  "clip": "",
  "keep": "",
  "strip": ""
}

perl-yaml-json

 json_diff
{
  "clip": "\n",
  "keep": "\n",
  "strip": ""
}

perl-tiny-json

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

perl-tiny-perl

 error
YAML::Tiny found bad indenting in line 'clip: >' 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 +MAP |
   1    0    0    0 +PAIR|
   1    0    0    0 +NODE|
   1    0    0    0 +VAL |
   1    0    0    0 =TEXT|strip
   1    5    5    5 -VAL |
   1    5    5    5 -NODE|
   1    5    5    5 =SYNX|:
   1    6    6    6 +NODE|
   1    6    6    6 =WSPC|.
   1    7    7    7 +VAL |
   1    7    7    7 =SYNX|>
   1    8    8    8 =SYNX|-
   1    9    9    9 =EOL |\x0a
   2    0   10   10 -VAL |
   2    0   10   10 =EOL |\x0a
   3    0   11   11 -NODE|
   3    0   11   11 -PAIR|
   3    0   11   11 +PAIR|
   3    0   11   11 +NODE|
   3    0   11   11 +VAL |
   3    0   11   11 =TEXT|clip
   3    4   15   15 -VAL |
   3    4   15   15 -NODE|
   3    4   15   15 =SYNX|:
   3    5   16   16 +NODE|
   3    5   16   16 =WSPC|.
   3    6   17   17 +VAL |
   3    6   17   17 =SYNX|>
   3    7   18   18 =EOL |\x0a
   4    0   19   19 -VAL |
   4    0   19   19 =EOL |\x0a
   5    0   20   20 -NODE|
   5    0   20   20 -PAIR|
   5    0   20   20 +PAIR|
   5    0   20   20 +NODE|
   5    0   20   20 +VAL |
   5    0   20   20 =TEXT|keep
   5    4   24   24 -VAL |
   5    4   24   24 -NODE|
   5    4   24   24 =SYNX|:
   5    5   25   25 +NODE|
   5    5   25   25 =WSPC|.
   5    6   26   26 +VAL |
   5    6   26   26 =SYNX||
   5    7   27   27 =SYNX|+
   5    8   28   28 =EOL |\x0a
   6    0   29   29 =NEWL|\x0a
   7    0   30   30 -VAL |
   7    0   30   30 -NODE|
   7    0   30   30 -PAIR|
   7    0   30   30 -MAP |
   7    0   30   30 -NODE|
   7    0   30   30 -DOC |

perl-pp-perl

 na
{
  'clip' => '',
  'keep' => '
',
  'strip' => ''
}

perl-pplibyaml-perl

 na
{
  'clip' => '',
  'keep' => '
',
  'strip' => ''
}

perl-syck-perl

 na
{
  'clip' => '',
  'keep' => '',
  'strip' => ''
}

perl-xs-perl

 na
{
  'clip' => '',
  'keep' => '
',
  'strip' => ''
}

perl-yaml-perl

 na
{
  'clip' => '
',
  'keep' => '
',
  'strip' => ''
}

py-pyyaml-py

 na
{'clip': '', 'keep': '\n', 'strip': ''}

py-ruamel-py

 na
{'clip': '', 'keep': '\n', 'strip': ''}