From 1dd0e4c96376f2c28590dad683161ee8c57c0508 Mon Sep 17 00:00:00 2001 From: Thomas Guyot-Sionnest Date: Fri, 31 Jan 2014 08:54:44 -0500 Subject: Enable tests in tests/ subdirs --- test.pl.in | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) (limited to 'test.pl.in') diff --git a/test.pl.in b/test.pl.in index 85ac19da..01a97ec0 100755 --- a/test.pl.in +++ b/test.pl.in @@ -9,9 +9,9 @@ use Getopt::Long; use NPTest qw(DetermineTestHarnessDirectory TestsFrom); -my $tstdir; +my @tstdir; -if ( ! GetOptions( "testdir:s" => \$tstdir ) ) +if ( ! GetOptions( "testdir:s" => \@tstdir ) ) { print "Usage: ${0} [--testdir=] [ ...]\n"; exit 1; @@ -25,15 +25,18 @@ if ( scalar( @ARGV ) ) } else { - my $directory = DetermineTestHarnessDirectory( $tstdir ); + my @directory = DetermineTestHarnessDirectory( @tstdir ); - if ( !defined( $directory ) ) + if ( @directory == 0 ) { print STDERR "$0: Unable to determine the test harness directory - ABORTING\n"; exit 2; } - @tests = TestsFrom( $directory, 1 ); + for my $d ( @directory ) + { + push (@tests, TestsFrom( $d, 1 )); + } } if ( ! scalar( @tests ) ) -- cgit v1.2.3