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2YU27WQS663WSKAL5FHWBSJ5GMM633AC
4OLBA6TUXVXJJVY2ZRO34W2QC7KCZAHL6ZG22DP5562KOJBTSIQQC
NZXX6PLDWEDQHXFF5JCZWGB22VA3WSDYLX65K6BQ5GNWPOE43N7QC
S5NPXZG34PZZ5FIIAQ2IO72G6PAQC4JZ2WS2CVKTO623BNQKGMHAC
my $db = Hydra::Model::DB->new;
hydra_setup($db);
ok(evalSucceeds($jobset), "Evaluating jobs/build-products.nix should exit with return code 0");
is(nrQueuedBuildsForJobset($jobset), 2, "Evaluating jobs/build-products.nix should result in 2 builds");
subtest "For the build job 'simple'" => sub {
my $build = $builds->{"simple"};
is($build->finished, 1, "Build should have finished");
is($build->buildstatus, 0, "Build should have buildstatus 0");
for my $build (queuedBuildsForJobset($jobset)) {
subtest "For the build job '" . $build->job . "'" => sub {
ok(runBuild($build), "Build should exit with return code 0");
my $newbuild = $db->resultset('Builds')->find($build->id);
my $buildproduct = $build->buildproducts->next;
is($buildproduct->name, "text.txt", "We should have \"text.txt\"");
};
if($build->job eq "simple") {
is($buildproduct->name, "text.txt", "We should have \"text.txt\"");
} elsif ($build->job eq "with_spaces") {
is($buildproduct->name, "some text.txt", "We should have: \"some text.txt\"");
}
};
my $buildproduct = $build->buildproducts->next;
is($buildproduct->name, "some text.txt", "We should have: \"some text.txt\"");
};