Subject: | Bad tests causes install failure on Win32 |
Test 26 fails on Windows.
It doesn't make sense to sysread to obey PerlIO layers :crlf and :encoding. So it doesn't. :crlf is automatically added to file handles on Windows (unless you use something like :raw when creating the handle), so while
6F.6B.20.33.A.6F.6B.20.35.A.6F.6B.20.37.A.6F.6B.20.39.A
is written to file test.5, it actually contains
6F.6B.20.33.D.A.6F.6B.20.35.D.A.6F.6B.20.37.D.A.6F.6B.20.39.D.A
This is read back as
6F.6B.20.33.A.6F.6B.20.35.A.6F.6B.20.37.A.6F.6B.20.39.A
by various tests. But test 26 uses sysread which ignores the :crlf, so it reads back
6F.6B.20.33.D.A.6F.6B.20.35.D.A.6F.6B.20.37.D.A.6F.6B.20.39.D.A
The solution is to add the following before test 26.
$expected =~ s/\n/\r\n/g if $^O =~ /Win32/;