Subject: | Trailing whitespace at first EOL when dumping a hash |
When dumping a hash, YAML::Syck outputs a trailing whitespace at the end
of the first line, so that the first line is "--- \n".
This causes various problems: trailing whitespace is invisible in most
text editors; other text editors trim trailing whitespace; which ends up
in tests that fail even though the output appears identical.
Test file attached.
Subject: | yaml-no-trailing-whitespace.t |
use strict;
use Test::More tests => 1;
use YAML::Syck;
# http://rt.cpan.org/Public/Bug/Display.html?id=46983
unlike( Dump({lou => 'is my cat'}), qr/^--- /, "no trailing whitespace after the leading '---'" );