Integrate from ansi branch to mainline.
[p5sagit/p5-mst-13.2.git] / t / TEST
diff --git a/t/TEST b/t/TEST
index 8b34c82..cae8103 100755 (executable)
--- a/t/TEST
+++ b/t/TEST
@@ -41,6 +41,8 @@ else {
 $bad = 0;
 $good = 0;
 $total = @ARGV;
+$files  = 0;
+$totmax = 0;
 while ($test = shift) {
     if ($test =~ /^$/) {
        next;
@@ -49,6 +51,7 @@ while ($test = shift) {
     chop($te);
     print "$te" . '.' x (18 - length($te));
     if ($sharpbang) {
+       -x $test || (print "isn't executable.\n");
        open(RESULTS,"./$test |") || (print "can't run.\n");
     } else {
        open(SCRIPT,"$test") || die "Can't run $test.\n";
@@ -67,8 +70,6 @@ while ($test = shift) {
     }
     $ok = 0;
     $next = 0;
-    $files  = 0;
-    $totmax = 0;
     while (<RESULTS>) {
        if ($verbose) {
            print $_;
@@ -101,7 +102,7 @@ while ($test = shift) {
        }
     } else {
        $next += 1;
-       print "FAILED on test $next\n";
+       print "FAILED at test $next\n";
        $bad = $bad + 1;
        $_ = $test;
        if (/^base/) {
@@ -113,6 +114,7 @@ while ($test = shift) {
 if ($bad == 0) {
     if ($ok) {
        print "All tests successful.\n";
+       # XXX add mention of 'perlbug -ok' ?
     } else {
        die "FAILED--no tests were run for some reason.\n";
     }