summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--ext/IO/t/io_unix.t7
-rw-r--r--lib/ExtUtils/t/eu_command.t1
-rwxr-xr-xlib/Time/Local.t3
-rw-r--r--os2/OS2/ExtAttr/t/os2_ea.t22
-rwxr-xr-xt/io/fs.t2
-rwxr-xr-xt/op/stat.t3
6 files changed, 27 insertions, 11 deletions
diff --git a/ext/IO/t/io_unix.t b/ext/IO/t/io_unix.t
index 6d77062a64..33ee05675b 100644
--- a/ext/IO/t/io_unix.t
+++ b/ext/IO/t/io_unix.t
@@ -38,6 +38,13 @@ BEGIN {
$PATH = "sock-$$";
+if ($^O eq 'os2') { # Can't create sockets with relative path...
+ require Cwd;
+ my $d = Cwd::cwd();
+ $d =~ s/^[a-z]://i;
+ $PATH = "$d/$PATH";
+}
+
# Test if we can create the file within the tmp directory
if (-e $PATH or not open(TEST, ">$PATH") and $^O ne 'os2') {
print "1..0 # Skip: cannot open '$PATH' for write\n";
diff --git a/lib/ExtUtils/t/eu_command.t b/lib/ExtUtils/t/eu_command.t
index f8199cdf62..2d2fdbae22 100644
--- a/lib/ExtUtils/t/eu_command.t
+++ b/lib/ExtUtils/t/eu_command.t
@@ -263,6 +263,7 @@ BEGIN {
{
{ local @ARGV = 'd2utest'; mkpath; }
open(FILE, '>d2utest/foo');
+ binmode(FILE);
print FILE "stuff\015\012and thing\015\012";
close FILE;
diff --git a/lib/Time/Local.t b/lib/Time/Local.t
index a6120e8da2..2ccea67fde 100755
--- a/lib/Time/Local.t
+++ b/lib/Time/Local.t
@@ -55,7 +55,8 @@ my @neg_time =
# Use 3 days before the start of the epoch because with Borland on
# Win32 it will work for -3600 _if_ your time zone is +01:00 (or
# greater).
-my $neg_epoch_ok = defined ((localtime(-259200))[0]) ? 1 : 0;
+my $neg_epoch_ok = # take into account systems with unsigned time too
+ (defined ((localtime(-259200))[0]) and (localtime(-259200))[5] == 69) ? 1 : 0;
# use vmsish 'time' makes for oddness around the Unix epoch
if ($^O eq 'VMS') {
diff --git a/os2/OS2/ExtAttr/t/os2_ea.t b/os2/OS2/ExtAttr/t/os2_ea.t
index a1da398d45..947e2f1916 100644
--- a/os2/OS2/ExtAttr/t/os2_ea.t
+++ b/os2/OS2/ExtAttr/t/os2_ea.t
@@ -37,9 +37,14 @@ system 'cmd', '/c', 'echo OK > t.out';
print "ok 2\n";
keys %a == 0 ? print "ok 3\n" : print "not ok 3\n";
- $a{'++'} = '---';
+# Standard Extended Attributes (SEAs) have a dot (.) as a prefix.
+# This identifies the extended attribute as a SEA. The leading dot is reserved,
+# so applications should not define extended attributes that start with a dot.
+# Also, extended attributes
+# that start with the characters $, @, &, or + are reserved for system use.
+ $a{'X--Y'} = '---'; # '++', -++', '!++', 'X++Y' fail on JFS
print "ok 4\n";
- $a{'AAA'} = 'xyz';
+ $a{'AAA'} = 'xyz'; # Name is going to be uppercased???
print "ok 5\n";
}
@@ -51,10 +56,10 @@ system 'cmd', '/c', 'echo OK > t.out';
my $c = keys %a;
$c == 2 ? print "ok 7\n" : print "not ok 7\n# c=$c\n";
my @b = sort keys %a;
- "@b" eq '++ AAA' ? print "ok 8\n" : print "not ok 8\n# keys=`@b'\n";
- $a{'++'} eq '---' ? print "ok 9\n" : print "not ok 9\n";;
+ "@b" eq 'AAA X--Y' ? print "ok 8\n" : print "not ok 8\n# keys=`@b'\n";
+ $a{'X--Y'} eq '---' ? print "ok 9\n" : print "not ok 9\n";;
$a{'AAA'} eq 'xyz' ? print "ok 10\n" : print "not ok 10\n# aaa->`$a{AAA}'\n";
- $c = delete $a{'++'};
+ $c = delete $a{'X--Y'};
$c eq '---' ? print "ok 11\n" : print "not ok 11\n# deleted->`$c'\n";;
}
@@ -70,10 +75,11 @@ print "ok 12\n";
"@b" eq 'AAA' ? print "ok 15\n" : print "not ok 15\n";
$a{'AAA'} eq 'xyz' ? print "ok 16\n" : print "not ok 16\n";;
! exists $a{'+'} ? print "ok 17\n" : print "not ok 17\n";;
- ! defined $a{'+'} ? print "ok 18\n" : print "not ok 18\n# ->`$a{'++'}'\n";;
- ! exists $a{'++'} ? print "ok 19\n" : print "not ok 19\n";;
- ! defined $a{'++'} ? print "ok 20\n" : print "not ok 20\n# ->`$a{'++'}'\n";;
+ ! defined $a{'+'} ? print "ok 18\n" : print "not ok 18\n# ->`$a{'X--Y'}'\n";;
+ ! exists $a{'X--Y'} ? print "ok 19\n" : print "not ok 19\n";;
+ ! defined $a{'X--Y'} ? print "ok 20\n" : print "not ok 20\n# ->`$a{'X--Y'}'\n";;
}
print "ok 21\n";
unlink 't.out';
+
diff --git a/t/io/fs.t b/t/io/fs.t
index 283a5a82f4..5b2de64846 100755
--- a/t/io/fs.t
+++ b/t/io/fs.t
@@ -203,7 +203,7 @@ SKIP: {
skip "has fchown", 1 if ($Config{d_fchown} || "") eq "define";
open(my $fh, "<", "a");
eval { chown(0, 0, $fh); };
- like($@, qr/^The fchown function is unimplemented at/, "fchown is unimplemented");
+ like($@, qr/^The f?chown function is unimplemented at/, "fchown is unimplemented");
}
is(rename('a','b'), 1, "rename a b");
diff --git a/t/op/stat.t b/t/op/stat.t
index cde2974883..7cb6b1b7b1 100755
--- a/t/op/stat.t
+++ b/t/op/stat.t
@@ -41,7 +41,7 @@ my $Curdir = File::Spec->curdir;
my $tmpfile = 'Op_stat.tmp';
my $tmpfile_link = $tmpfile.'2';
-
+chmod 0666, $tmpfile;
1 while unlink $tmpfile;
open(FOO, ">$tmpfile") || DIE("Can't open temp test file: $!");
close FOO;
@@ -508,5 +508,6 @@ SKIP: {
}
END {
+ chmod 0666, $tmpfile;
1 while unlink $tmpfile;
}