Change 34065 by [EMAIL PROTECTED] on 2008/06/16 15:41:01
Integrate:
[ 33979]
Probably startirng with the changes in change #33897,
t/run/exit.t has been failing on Win32. Update the skipping
mechanism to do more that check for the definition of
POSIX::WIFEXITED.
[ 33982]
Subject: Re: [perl #55160] perlbug AutoReply: Fix cygwin mount test
From: "Reini Urban" <[EMAIL PROTECTED]>
Date: Sun, 1 Jun 2008 14:51:59 +0200
Message-ID: <[EMAIL PROTECTED]>
[ 34024]
Subject: Fwd: [PATCH-2] Re: testing $/ with in memory files
From: Bram <[EMAIL PROTECTED]>
Date: Mon, 26 May 2008 09:12:58 +0200
Message-ID: <[EMAIL PROTECTED]>
[ 34054]
Subject: [PATCH] Re: testing $/ with in memory files
From: Bram <[EMAIL PROTECTED]>
Date: Sat, 14 Jun 2008 18:20:05 +0200
Message-ID: <[EMAIL PROTECTED]>
[ 34056]
Subject: [perl #47746] Not OK: perl 5.10.0 +RC1 on ia64-linux
2.4.21-sgi302r24
From: "John P. Linderman" <[EMAIL PROTECTED]>
Date: Tue, 27 Nov 2007 13:50:14 -0500 (EST)
Message-Id: <[EMAIL PROTECTED]>
[ 34060]
Make lib/open.t under -Duseperlio
Affected files ...
... //depot/maint-5.10/perl/lib/open.t#3 integrate
... //depot/maint-5.10/perl/t/base/rs.t#3 integrate
... //depot/maint-5.10/perl/t/lib/cygwin.t#2 integrate
... //depot/maint-5.10/perl/t/op/stat.t#2 integrate
... //depot/maint-5.10/perl/t/run/exit.t#2 integrate
Differences ...
==== //depot/maint-5.10/perl/lib/open.t#3 (text) ====
Index: perl/lib/open.t
--- perl/lib/open.t#2~33525~ 2008-03-14 03:11:45.000000000 -0700
+++ perl/lib/open.t 2008-06-16 08:41:01.000000000 -0700
@@ -180,14 +180,12 @@
"checking syswrite() output on :utf8 streams by reading it back in");
}
}
+SKIP: {
+ skip("no perlio", 2) unless (find PerlIO::Layer 'perlio');
-{
eval q[use Encode::Alias;use open ":std", ":locale"];
is($@, '', 'can use :std and :locale');
-}
-SKIP: {
- skip("no perlio", 1) unless (find PerlIO::Layer 'perlio');
use open IN => ':non-existent';
eval {
require Symbol; # Anything that exists but we havn't loaded
==== //depot/maint-5.10/perl/t/base/rs.t#3 (xtext) ====
Index: perl/t/base/rs.t
--- perl/t/base/rs.t#2~33823~ 2008-05-12 03:24:27.000000000 -0700
+++ perl/t/base/rs.t 2008-06-16 08:41:01.000000000 -0700
@@ -115,13 +115,16 @@
}
-if ($ENV{PERL_CORE_MINITEST} or $ENV{_} =~ m/miniperl/) {
+if (not eval q/use PerlIO::scalar; use PerlIO::via::scalar; 1/) {
# In-memory files necessitate PerlIO::via::scalar, thus a perl with
# perlio and dynaloading enabled. miniperl won't be able to run this
# test, so skip it
+ # PerlIO::via::scalar has to be tested as well.
+ # use PerlIO::scalar succeeds with ./TEST and with ./perl harness but not
with ./perl
+
for $test ($test_count .. $test_count + ($test_count_end - $test_count_start
- 1)) {
- print "ok $test # skipped - Can't test in memory file with miniperl\n";
+ print "ok $test # skipped - Can't test in memory file with
miniperl/without PerlIO::Scalar\n";
$test_count++;
}
}
==== //depot/maint-5.10/perl/t/lib/cygwin.t#2 (text) ====
Index: perl/t/lib/cygwin.t
--- perl/t/lib/cygwin.t#1~32694~ 2007-12-22 01:23:09.000000000 -0800
+++ perl/t/lib/cygwin.t 2008-06-16 08:41:01.000000000 -0700
@@ -43,7 +43,7 @@
is(Cygwin::win_to_posix_path($winpath, 1), "/", "win to absolute posix path");
my $mount = join '', `/usr/bin/mount`;
-$mount =~ m|on /usr/bin type .+ \((\w+mode)\)|m;
+$mount =~ m|on /usr/bin type .+ \((\w+mode)[,\)]|m;
my $binmode = $1 eq 'binmode';
is(Cygwin::is_binmount("/"), $binmode ? 1 : '', "check / for binmount");
==== //depot/maint-5.10/perl/t/op/stat.t#2 (xtext) ====
Index: perl/t/op/stat.t
--- perl/t/op/stat.t#1~32694~ 2007-12-22 01:23:09.000000000 -0800
+++ perl/t/op/stat.t 2008-06-16 08:41:01.000000000 -0700
@@ -50,6 +50,10 @@
my($nlink, $mtime, $ctime) = (stat(FOO))[$NLINK, $MTIME, $CTIME];
+# The clock on a network filesystem might be different from the
+# system clock.
+my $Filesystem_Time_Offset = abs($mtime - time);
+
#nlink should if link support configured in Perl.
SKIP: {
skip "No link count - Hard link support not built in.", 1
@@ -453,20 +457,24 @@
unlink $linkname or print "# unlink $linkname failed: $!\n";
}
-print "# Zzz...\n";
-sleep(3);
-my $f = 'tstamp.tmp';
-unlink $f;
-ok (open(S, "> $f"), 'can create tmp file');
-close S or die;
-my @a = stat $f;
-print "# time=$^T, stat=(@a)\n";
-my @b = (-M _, -A _, -C _);
-print "# -MAC=(@b)\n";
-ok( (-M _) < 0, 'negative -M works');
-ok( (-A _) < 0, 'negative -A works');
-ok( (-C _) < 0, 'negative -C works');
-ok(unlink($f), 'unlink tmp file');
+SKIP: {
+ skip "Too much clock skew between system and filesystem", 5
+ if ($Filesystem_Time_Offset > 5);
+ print "# Zzz...\n";
+ sleep($Filesystem_Time_Offset+1);
+ my $f = 'tstamp.tmp';
+ unlink $f;
+ ok (open(S, "> $f"), 'can create tmp file');
+ close S or die;
+ my @a = stat $f;
+ print "# time=$^T, stat=(@a)\n";
+ my @b = (-M _, -A _, -C _);
+ print "# -MAC=(@b)\n";
+ ok( (-M _) < 0, 'negative -M works');
+ ok( (-A _) < 0, 'negative -A works');
+ ok( (-C _) < 0, 'negative -C works');
+ ok(unlink($f), 'unlink tmp file');
+}
{
ok(open(F, ">", $tmpfile), 'can create temp file');
==== //depot/maint-5.10/perl/t/run/exit.t#2 (text) ====
Index: perl/t/run/exit.t
--- perl/t/run/exit.t#1~32694~ 2007-12-22 01:23:09.000000000 -0800
+++ perl/t/run/exit.t 2008-06-16 08:41:01.000000000 -0700
@@ -37,7 +37,8 @@
if ($^O ne 'VMS') {
my $posix_ok = eval { require POSIX; };
my $wait_macros_ok = defined &POSIX::WIFEXITED;
-
+ eval { POSIX::WIFEXITED() };
+ $wait_macros_ok = 0 if $@;
$exit = run('exit 42');
is( $exit >> 8, 42, 'Non-zero exit' );
is( $exit, $?, 'Non-zero exit $?' );
End of Patch.