Subject: | failed tests due to non-portability practices during testing |
Microsoft (R) Program Maintenance Utility Version 6.00.8168.0
Copyright (C) Microsoft Corp 1988-1998. All rights reserved.
cp lib/CGI/Untaint/integer.pm blib\lib\CGI/Untaint/integer.pm
cp lib/CGI/Untaint.pm blib\lib\CGI/Untaint.pm
cp lib/CGI/Untaint/hex.pm blib\lib\CGI/Untaint/hex.pm
cp lib/CGI/Untaint/object.pm blib\lib\CGI/Untaint/object.pm
cp lib/CGI/Untaint/printable.pm blib\lib\CGI/Untaint/printable.pm
C:\Perl\bin\perl.exe "-MExtUtils::Command::MM" "-e" "test_harness(0, 'blib\lib', 'blib\arch')" t\01.t t\mypath.t t\printable.t
t\01...........ok
t\mypath.......NOK 2# Failed test (t\mypath.t at line 28)
# got: 'C:\DOCUME~1\_\LOCALS~1\Temp\L8ofsR6YnG/CGI/Untaint/TesttEo2.pm'
# expected: 'C:\DOCUME~1\_\LOCALS~1\Temp\L8ofsR6YnG\CGI\Untaint\TesttEo2.pm'
t\mypath.......ok 12/12# Looks like you failed 1 tests of 12.
t\mypath.......dubious
Test returned status 1 (wstat 256, 0x100)
DIED. FAILED test 2
Failed 1/12 tests, 91.67% okay
t\printable....ok
Failed Test Stat Wstat Total Fail Failed List of Failed
-------------------------------------------------------------------------------
t\mypath.t 1 256 12 1 8.33% 2
Failed 1/3 test scripts, 66.67% okay. 1/36 subtests failed, 97.22% okay.
NMAKE : fatal error U1077: 'C:\Perl\bin\perl.exe' : return code '0xff'
Stop.
This is the test that's causing it:
is ("$loc/$package.pm", $filename, "Package $loc/$package.pm OK");
and it really isn't a good idea.
You should read `perldoc perlport' and use File::Spec;
Something like the following should suffice
is(
File::Spec->catfile( $loc, "$package.pm" ),
File::Spec->canonpath( $file ),
"Package $loc/$package.pm OK",
);