Re: forwarded you a test result
[p5sagit/p5-mst-13.2.git] / t / op / pack.t
index af54fdc..0c7d51d 100755 (executable)
@@ -6,7 +6,7 @@ BEGIN {
     require './test.pl';
 }
 
-plan tests => 5849;
+plan tests => 5852;
 
 use strict;
 use warnings;
@@ -184,8 +184,12 @@ sub list_eq ($$) {
     skip "Couldn't generate infinity - got error '$@'"
       unless defined $inf and $inf == $inf / 2 and $inf + 1 == $inf;
 
+    local our $TODO;
+    $TODO = "VOS needs a fix for posix-1022 to pass this test."
+      if ($^O eq 'vos');
+
     eval { $x = pack 'w', $inf };
-    like ($@, qr/^Cannot compress integer/);
+    like ($@, qr/^Cannot compress integer/, "Cannot compress integer");
   }
 
  SKIP: {
@@ -1096,3 +1100,11 @@ ok(pack('u2', 'AA'), "[perl #8026]"); # used to hang and eat RAM in perl 5.7.2
 
 $_ = pack('c', 65); # 'A' would not be EBCDIC-friendly
 is(unpack('c'), 65, "one-arg unpack (change #18751)"); # defaulting to $_
+
+{
+    my $a = "X\t01234567\n" x 100;
+    my @a = unpack("(a1 c/a)*", $a);
+    is(scalar @a, 200,       "[perl #15288]");
+    is($a[-1], "01234567\n", "[perl #15288]");
+    is($a[-2], "X",          "[perl #15288]");
+}