summaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorJim Meyering <jim@meyering.net>1997-01-30 03:38:07 +0000
committerJim Meyering <jim@meyering.net>1997-01-30 03:38:07 +0000
commit307b54a27373b353e833d467dba434881e3200d0 (patch)
treeac618b14c8290e8bd7a7655b04a84ba68eb3f70c /tests
parent795162649b3121c50460d66780e5d52bf48aaad5 (diff)
downloadcoreutils-307b54a27373b353e833d467dba434881e3200d0.tar.xz
(test_vector): Do each (non-stdin-requiring) test three times.
Diffstat (limited to 'tests')
-rwxr-xr-xtests/tail/Test.pm18
1 files changed, 16 insertions, 2 deletions
diff --git a/tests/tail/Test.pm b/tests/tail/Test.pm
index 4ec332b7b..79d361beb 100755
--- a/tests/tail/Test.pm
+++ b/tests/tail/Test.pm
@@ -2,8 +2,6 @@ package Test;
require 5.002;
use strict;
-$Test::input_via_stdin = 1;
-
my @tv = (
# test name, options, input, expected output, expected return code
#
@@ -72,6 +70,22 @@ my @tv = (
sub test_vector
{
+ my $t;
+ foreach $t (@tv)
+ {
+ my ($test_name, $flags, $in, $exp, $ret) = @$t;
+
+ # If you run the minus* tests with a FILE arg they'd hang.
+ if ($test_name =~ /^minus/)
+ {
+ $Test::input_via{$test_name} = {REDIR => 0, PIPE => 0};
+ }
+ else
+ {
+ $Test::input_via{$test_name} = {REDIR => 0, FILE => 0, PIPE => 0}
+ }
+ }
+
return @tv;
}