From 849b1c1357ca06a56ff9cd82adf67fd67c8878cb Mon Sep 17 00:00:00 2001 From: "wurblzap%gmail.com" <> Date: Tue, 18 Mar 2008 22:30:02 +0000 Subject: Bug 416047 – Test 1 fails in compiling Bugzilla::Install::CPAN and install-module.pl when Cygwin is installed. Patch by Marc Schumann ; r=LpSolit; a=LpSolit MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- t/001compile.t | 14 ++++++++++++-- 1 file changed, 12 insertions(+), 2 deletions(-) (limited to 't') diff --git a/t/001compile.t b/t/001compile.t index fdbe875e3..78fc6a684 100644 --- a/t/001compile.t +++ b/t/001compile.t @@ -91,13 +91,23 @@ foreach my $file (@testitems) { my $loginfo=`$command`; #print '@@'.$loginfo.'##'; if ($loginfo =~ /syntax ok$/im) { + # Special hack due to CPAN.pm on Windows with Cygwin installed throwing + # strings of the form "Set up gcc environment - 3.4.4 (cygming special, + # gdc 0.12, using dmd 0.125)". See bug 416047 for details. + if ($^O =~ /MSWin32/i + && grep($_ eq $file, 'install-module.pl', 'Bugzilla/Install/CPAN.pm')) + { + $loginfo =~ s/^Set up gcc environment.*?\n//; + } if ($loginfo ne "$file syntax OK\n") { ok(0,$file." --WARNING"); print $fh $loginfo; - } else { + } + else { ok(1,$file); } - } else { + } + else { ok(0,$file." --ERROR"); print $fh $loginfo; } -- cgit v1.2.3-24-g4f1b