From: Steve Hay Date: Fri, 19 Dec 2008 14:58:20 +0000 (+0000) Subject: Fix new Module-Load-Conditional test, which otherwise fails on Win32. X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=687d0cf84a5d65b31d19c4471515acd393337a48;p=p5sagit%2Fp5-mst-13.2.git Fix new Module-Load-Conditional test, which otherwise fails on Win32. --- diff --git a/lib/Module/Load/Conditional.pm b/lib/Module/Load/Conditional.pm index 4fba341..c9fe15d 100644 --- a/lib/Module/Load/Conditional.pm +++ b/lib/Module/Load/Conditional.pm @@ -18,7 +18,7 @@ BEGIN { $FIND_VERSION $ERROR $CHECK_INC_HASH]; use Exporter; @ISA = qw[Exporter]; - $VERSION = '0.28'; + $VERSION = '0.28_01'; $VERBOSE = 0; $FIND_VERSION = 1; $CHECK_INC_HASH = 0; diff --git a/lib/Module/Load/Conditional/t/01_Module_Load_Conditional.t b/lib/Module/Load/Conditional/t/01_Module_Load_Conditional.t index dbd5ecd..6972c1b 100644 --- a/lib/Module/Load/Conditional/t/01_Module_Load_Conditional.t +++ b/lib/Module/Load/Conditional/t/01_Module_Load_Conditional.t @@ -48,8 +48,9 @@ use_ok( 'Module::Load::Conditional' ); q[ Found proper version] ); ok( $rv->{dir}, q[ Found directory information] ); - { my $dir_re = qr/^$rv->{dir}/i; - like( $rv->{file}, $dir_re, + { my $dir = File::Spec->canonpath( $rv->{dir} ); + my $dir_re = qr/^\Q$dir\E/i; + like( File::Spec->canonpath( $rv->{file} ), $dir_re, q[ Dir subset of file path] ); }