From: des Date: Mon, 20 Aug 2007 09:42:01 +0000 (+0000) Subject: If the first and only argument is 'list', list all available test cases. X-Git-Url: https://err.no/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=14f1aac18e99342a7474b73f93f01906cb6f0931;p=varnish If the first and only argument is 'list', list all available test cases. git-svn-id: svn+ssh://projects.linpro.no/svn/varnish/trunk@1876 d4fa192b-c00b-0410-8231-f00ffab90ce4 --- diff --git a/varnish-tools/regress/varnish-regress.pl b/varnish-tools/regress/varnish-regress.pl index 5a27cfdb..3d2105b6 100755 --- a/varnish-tools/regress/varnish-regress.pl +++ b/varnish-tools/regress/varnish-regress.pl @@ -62,9 +62,15 @@ MAIN:{ or usage(); my $controller = new Varnish::Test; + my @all_cases = $controller->cases(); + + if (@ARGV == 1 && $ARGV[0] eq 'list') { + print join(' ', @all_cases), "\n"; + exit 0; + } if (!@ARGV) { - @ARGV = $controller->cases(); + @ARGV = @all_cases; } else { map { s/^(\d+)$/sprintf('Ticket%03d', $1)/e } @ARGV; }