Skip to content

Commit 1a74a75

Browse files
committed
autodie/t/mkdir.t: escape build dir path
This test file creates a regex which includes the path of the build directory. If that path includes regex metachars (e.g. blead_g++_quick) then the test fails. Easily fixed with \Q...\E. Monkey-patching here rather than waiting for upstream, since this is currently breaking blead g++ smokes.
1 parent 047c3ca commit 1a74a75

File tree

3 files changed

+5
-2
lines changed

3 files changed

+5
-2
lines changed

Porting/Maintainers.pl

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -156,6 +156,8 @@ package Maintainers;
156156
t/system.t
157157
)
158158
],
159+
# CPAN RT 105344
160+
'CUSTOMIZED' => [ qw[ t/mkdir.t ] ],
159161
},
160162

161163
'AutoLoader' => {

cpan/autodie/t/mkdir.t

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,8 @@ use strict;
33
use Test::More;
44
use FindBin qw($Bin);
55
use constant TMPDIR => "$Bin/mkdir_test_delete_me";
6-
use constant ERROR_REGEXP => qr{Can't mkdir\('${\(TMPDIR)}', 0777\):};
7-
use constant SINGLE_DIGIT_ERROR_REGEXP => qr{Can't mkdir\('${\(TMPDIR)}', 0010\):};
6+
use constant ERROR_REGEXP => qr{Can't mkdir\('\Q${\(TMPDIR)}\E', 0777\):};
7+
use constant SINGLE_DIGIT_ERROR_REGEXP => qr{Can't mkdir\('\Q${\(TMPDIR)}\E', 0010\):};
88

99
# Delete our directory if it's there
1010
rmdir TMPDIR;

t/porting/customized.dat

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -49,6 +49,7 @@ Win32API::File cpan/Win32API-File/Makefile.PL 605d0aee31aebe84a99408f9ab5f644db5
4949
Win32API::File cpan/Win32API-File/t/file.t 124e64aa77e755235eb297644a87fac5388d3d78
5050
Win32API::File cpan/Win32API-File/t/tie.t 712ea7edd0cc805ce1c0b8172c01b03dd19b583d
5151
Win32API::File cpan/Win32API-File/typemap 24bff088babeadac0873e8df390d1666d9d9db4a
52+
autodie cpan/autodie/t/mkdir.t 9e70d2282a3cc7d76a78bf8144fccba20fb37dac
5253
podlators cpan/podlators/scripts/pod2man.PL f81acf53f3ff46cdcc5ebdd661c5d13eb35d20d6
5354
podlators cpan/podlators/scripts/pod2text.PL b4693fcfe4a0a1b38a215cfb8985a65d5d025d69
5455
version cpan/version/lib/version.pm d0923b895d57f1d669ae36fcf85c87b16db341d1

0 commit comments

Comments
 (0)