From 4fcbc3669aa997848e15198cc9fb856287a6788c Mon Sep 17 00:00:00 2001 From: markm Date: Wed, 9 Sep 1998 07:00:04 +0000 Subject: Initial import of Perl5. The king is dead; long live the king! --- contrib/perl5/t/harness | 33 +++++++++++++++++++++++++++++++++ 1 file changed, 33 insertions(+) create mode 100644 contrib/perl5/t/harness (limited to 'contrib/perl5/t/harness') diff --git a/contrib/perl5/t/harness b/contrib/perl5/t/harness new file mode 100644 index 0000000..f6d94de --- /dev/null +++ b/contrib/perl5/t/harness @@ -0,0 +1,33 @@ +#!./perl + +# We suppose that perl _mostly_ works at this moment, so may use +# sophisticated testing. + +BEGIN { + chdir 't' if -d 't'; + @INC = '../lib'; + $ENV{PERL5LIB} = '../lib'; # so children will see it too +} +use lib '../lib'; + +use Test::Harness; + +$Test::Harness::switches = ""; # Too much noise otherwise +$Test::Harness::verbose = shift if @ARGV && $ARGV[0] eq '-v'; + +@tests = @ARGV; +@tests = unless @tests; + +Test::Harness::runtests @tests; + +%infinite = ('comp/require.t', 1, 'op/bop.t', 1, 'lib/hostname.t', 1 ); + +@tests = grep (!$infinite{$_}, @tests); + +if (-e "../testcompile") +{ + print "The tests ", join(' ', keys(%infinite)), + " generate infinite loops! Skipping!\n"; + + $ENV{'COMPILE_TEST'} = 1; Test::Harness::runtests @tests; +} -- cgit v1.1