In case of a build error the TestUnits check must be skipped on Wine VMs since the test units list is built from the test reports.
Signed-off-by: Francois Gouget fgouget@codeweavers.com --- testbot/tests/TestWTBS | 8 ++++++++ 1 file changed, 8 insertions(+)
diff --git a/testbot/tests/TestWTBS b/testbot/tests/TestWTBS index cc3037fb7..01f46bfde 100755 --- a/testbot/tests/TestWTBS +++ b/testbot/tests/TestWTBS @@ -514,6 +514,12 @@ sub CheckTask($$$$) { is($Task->Status, $TaskInfo->{Status}, "Check Status of task ". TaskKeyStr($Task)); } + if ($Task->Status =~ /^bad/) + { + # It makes no sense to check which test units were run in case of a build + # error. + $TestUnits->{$TaskType}->{"*skipped*"} = 1; + }
my $ReportCount = 0; foreach my $LogName (@{GetLogFileNames($Task->GetDir())}) @@ -670,6 +676,8 @@ sub CheckJobTree($) $HasTask->{$Type} ||= 0; is($HasTask->{$Type}, $TypeInfo->{HasTask}, "Check the presence of $Type tasks for job ". $Job->Id); } + + next if ($TestUnits->{$Type}->{"*skipped*"}); if (CheckValue($TypeInfo->{TestUnits})) { foreach my $TestUnit (split / +/, $TypeInfo->{TestUnits})