From 85baf8ceec93389fd054a1bf454897f4a1e895f4 Mon Sep 17 00:00:00 2001 From: Evan Giles Date: Mon, 6 May 2024 09:02:54 +1200 Subject: [PATCH] Fix CPANTESTERS errors Tests are failing on all MSWin32 computers, because windows uses a backslash (not a slash) to separate file paths --- Changes | 3 +++ lib/Test/Compile.pm | 2 +- lib/Test/Compile/Internal.pm | 2 +- t/100-internal--default_locations.t | 4 +++- 4 files changed, 8 insertions(+), 3 deletions(-) diff --git a/Changes b/Changes index ce9c6ac..c8aaeb7 100644 --- a/Changes +++ b/Changes @@ -1,5 +1,8 @@ Revision history for Perl extension Test-Compile +v3.3.3 2024-05-06 + - Be more careful about windows filenames + v3.3.2 2024-05-03 - Require a newer version of Test::More (fix CPAN testing failure?) - Don't add an unnecassary "./" to the start of filepaths (CPAN-RT 151090) diff --git a/lib/Test/Compile.pm b/lib/Test/Compile.pm index ad14fbc..7ff2a0f 100644 --- a/lib/Test/Compile.pm +++ b/lib/Test/Compile.pm @@ -3,7 +3,7 @@ package Test::Compile; use warnings; use strict; -use version; our $VERSION = version->declare("v3.3.2"); +use version; our $VERSION = version->declare("v3.3.3"); use parent 'Exporter'; use Test::Compile::Internal; diff --git a/lib/Test/Compile/Internal.pm b/lib/Test/Compile/Internal.pm index 30b1a97..162fe4a 100644 --- a/lib/Test/Compile/Internal.pm +++ b/lib/Test/Compile/Internal.pm @@ -3,7 +3,7 @@ package Test::Compile::Internal; use warnings; use strict; -use version; our $VERSION = version->declare("v3.3.2"); +use version; our $VERSION = version->declare("v3.3.3"); use File::Find; use File::Spec; use Test::Builder; diff --git a/t/100-internal--default_locations.t b/t/100-internal--default_locations.t index c01c232..a52ba4f 100644 --- a/t/100-internal--default_locations.t +++ b/t/100-internal--default_locations.t @@ -5,6 +5,7 @@ use warnings; use Test::More; use Test::Compile::Internal; +use File::Spec; my $internal = Test::Compile::Internal->new(); my @locations; @@ -33,7 +34,8 @@ if ( -e 'blib' ) { @locations = $internal->_default_locations("lib"); # Then - is($locations[0], "blib/lib", "prefer to look in blib if it's available"); + my $expected = File::Spec->catfile("blib", "lib"); + is($locations[0], $expected, "prefer to look in blib if it's available"); }