Commit 91b504f8 authored by Magnus Svensson's avatar Magnus Svensson

BUG#39011 mtr reports test failure without any message or log - part 1

parent 037751e8
...@@ -3508,12 +3508,21 @@ sub report_failure_and_restart ($) { ...@@ -3508,12 +3508,21 @@ sub report_failure_and_restart ($) {
if ( !defined $tinfo->{logfile} ) if ( !defined $tinfo->{logfile} )
{ {
my $logfile= $path_current_testlog; my $logfile= $path_current_testlog;
if ( defined $logfile and -f $logfile ) if ( defined $logfile )
{ {
# Test failure was detected by test tool and its report if ( -f $logfile )
# about what failed has been saved to file. Save the report {
# in tinfo # Test failure was detected by test tool and its report
$tinfo->{logfile}= mtr_fromfile($logfile); # about what failed has been saved to file. Save the report
# in tinfo
$tinfo->{logfile}= mtr_fromfile($logfile);
}
else
{
# The test tool report didn't exist, display an
# error message
$tinfo->{logfile}= "Could not open test tool report '$logfile'";
}
} }
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment