Subject: | t/all_pod_files.t failure on Win32 |
D:\Test-Pod-1.24>perl -T t\all_pod_files.t
1..2
ok 1 - use Test::Pod;
not ok 2 - Got all the distro files
# Failed test 'Got all the distro files'
# in t\all_pod_files.t at line 32.
# Structures begin differing at:
# $got->[0] = 'blib\lib\test\pod.pm'
# $expected->[0] = 'blib/lib/test/pod.pm'
# Looks like you failed 1 test of 2.
Is there in a typo in the assignment to @expected for VMS ?
I suspect that:
File::Spec->catfile( 't', 'pod', 'good-pod-script.' ),
should really be:
File::Spec->catfile( 't', 'pod', 'good-pod-script' ),
If that suspicion is correct, then all you really need to do is fix
that typo and replace:
if($^O eq "VMS")
with:
if($^O eq "VMS" || $^O =~ /MSWin32/i)
Otherwise you could give Win32 its own elsif block:
elsif($^O =~ /MSWin32/i) {
@expected = (
File::Spec->catfile( 'blib', 'lib', 'Test', 'Pod.pm' ),
File::Spec->catfile( 't', 'pod', 'good-pod-script' ),
File::Spec->catfile( 't', 'pod', 'good.pod' ),
File::Spec->catfile( 't', 'pod', 'no_pod.pod' ),
);
}
I did it by adding that elsif block - which works fine for both my gcc-
built and msvc-built perls.
I'm using Windows 2000 with perl(s)-5.8.8.
Cheers,
Rob