forked from lix-project/hydra
Fix broken test
This commit is contained in:
parent
e9c88783ce
commit
09e26a3011
|
@ -7,15 +7,17 @@ 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)/) {
|
||||
ok(scalar($db->resultset($source)->all) == 0, $title);
|
||||
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 {
|
||||
ok(scalar($db->resultset($source)->search({},{ bind => ["", "", ""] })) == 0, $title);
|
||||
ok(scalar($db->resultset($source)->search({},{ bind => ["", "", ""] })) == 0, $title);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue