From: mike Date: Thu, 21 Jun 2007 14:54:32 +0000 (+0000) Subject: Failure to compile a query counts as a failed test! X-Git-Tag: v1.5~126 X-Git-Url: http://sru.miketaylor.org.uk/cgi-bin?a=commitdiff_plain;h=5ec1bd19b223ae4980d46c737bb20af68ef17e8f;p=cql-java-moved-to-github.git Failure to compile a query counts as a failed test! --- diff --git a/test/regression/runtests b/test/regression/runtests index 008c271..070a921 100755 --- a/test/regression/runtests +++ b/test/regression/runtests @@ -1,6 +1,6 @@ #!/usr/bin/perl -w -# $Id: runtests,v 1.9 2007-06-21 10:10:32 mike Exp $ +# $Id: runtests,v 1.10 2007-06-21 14:54:32 mike Exp $ use IO::File; use strict; @@ -28,11 +28,12 @@ while () { my $afile = $qfile; $afile =~ s/\.cql$/.xcql/; print " query $_ - $query "; - my $correct = read_file("$norman < $afile |"); - my $tested = read_file("$compiler < $qfile | $norman |") - or print "\n *** test compiler exited non-zero\n"; $ntests++; - if ($tested eq $correct) { + my $correct = read_file("$norman < $afile |"); + my $tested = read_file("$compiler < $qfile | $norman |"); + if (!$tested) { + print "\n *** test compiler exited non-zero\n"; + } elsif ($tested eq $correct) { print "OK\n"; $ncorrect++; } else {