diff options
author | Ed Peschko <epeschko@den-mdev1> | 1999-05-31 12:18:13 -0600 |
---|---|---|
committer | Gurusamy Sarathy <gsar@cpan.org> | 1999-07-05 02:38:03 +0000 |
commit | c16fc93b64aeb43562d33bf99116124dba27029a (patch) | |
tree | 2a3ef2871bf67a1db9813472acd7e5016e8c9c2e /t/harness | |
parent | 30757defed607b3d1bf57e18644f51c517bdb6fd (diff) | |
download | perl-c16fc93b64aeb43562d33bf99116124dba27029a.tar.gz |
[ PATCH perl5.005_57 ] new perlcc + regression tests
Message-ID: <19990601001813.AAA17834@csgsystems.com>
p4raw-id: //depot/perl@3580
Diffstat (limited to 't/harness')
-rw-r--r-- | t/harness | 59 |
1 files changed, 32 insertions, 27 deletions
@@ -6,13 +6,13 @@ BEGIN { chdir 't' if -d 't'; unshift @INC, '../lib'; - $ENV{PERL5LIB} = '../lib'; # so children will see it too + $ENV{PERL5LIB} = '../lib'; # so children will see it too } use lib '../lib'; use Test::Harness; -$Test::Harness::switches = ""; # Too much noise otherwise +$Test::Harness::switches = ""; # Too much noise otherwise $Test::Harness::verbose = shift if @ARGV && $ARGV[0] eq '-v'; @tests = @ARGV; @@ -21,17 +21,18 @@ $Test::Harness::verbose = shift if @ARGV && $ARGV[0] eq '-v'; Test::Harness::runtests @tests; exit(0) unless -e "../testcompile"; -%infinite = qw( - op/bop.t 1 - lib/hostname.t 1 - ); #fudge DATA for now. +%infinite = qw ( + op/bop.t 1 + lib/hostname.t 1 + ); + %datahandle = qw( - lib/bigint.t 1 - lib/bigintpm.t 1 - lib/bigfloat.t 1 - lib/bigfloatpm.t 1 - ); + lib/bigint.t 1 + lib/bigintpm.t 1 + lib/bigfloat.t 1 + lib/bigfloatpm.t 1 + ); my $dhwrapper = <<'EOT'; open DATA,"<".__FILE__; @@ -40,22 +41,26 @@ EOT @tests = grep (!$infinite{$_}, @tests); @tests = map { - my $new = $_; - if ($datahandle{$_}) { - $new .= '.t'; - local(*F, *T); - open(F,"<$_") or die "Can't open $_: $!"; - open(T,">$new") or die "Can't open $new: $!"; - print T $dhwrapper, <F>; - close F; - close T; - } - $new; - } @tests; - -print "The tests ", join(' ', keys(%infinite)), - " generate infinite loops! Skipping!\n"; -$ENV{'COMPILE_TEST'} = 1; Test::Harness::runtests @tests; + my $new = $_; + if ($datahandle{$_}) { + $new .= '.t'; + local(*F, *T); + open(F,"<$_") or die "Can't open $_: $!"; + open(T,">$new") or die "Can't open $new: $!"; + print T $dhwrapper, <F>; + close F; + close T; + } + $new; + } @tests; + +print "The tests ", join(' ', keys(%infinite)), + " generate infinite loops! Skipping!\n"; + +$ENV{'COMPILE_TEST'} = 1; +$ENV{'COMPILE_TIMEOUT'} = 120 unless $ENV{'COMPILE_TIMEOUT'}; + +Test::Harness::runtests @tests; foreach (keys %datahandle) { unlink "$_.t"; } |