Fix broken test

This commit is contained in:
Eelco Dolstra 2011-12-05 15:21:43 +01:00
parent e9c88783ce
commit 09e26a3011

View file

@ -7,11 +7,13 @@ my $db = openHydraDB;
my @sources = $db->sources;
my $nrtables = scalar(@sources);
use Test::Simple tests => 43;
use Test::Simple tests => 44;
foreach my $source (@sources) {
my $title = "Basic select query for $source";
if( $source !~ m/^(LatestSucceeded|JobStatus|ActiveJobs)/) {
if ($source eq "SchemaVersion") {
ok(scalar($db->resultset($source)->all) == 1, $title);
} elsif( $source !~ m/^(LatestSucceeded|JobStatus|ActiveJobs)/) {
ok(scalar($db->resultset($source)->all) == 0, $title);
}
else {