Bug #16190704: MTR STILL LOSES THE FAILED RUN LOGS AT RETRY-FAIL

parent 2993c299
...@@ -617,9 +617,11 @@ sub run_test_server ($$$) { ...@@ -617,9 +617,11 @@ sub run_test_server ($$$) {
mtr_report("\nRetrying test $tname, ". mtr_report("\nRetrying test $tname, ".
"attempt($retries/$opt_retry)...\n"); "attempt($retries/$opt_retry)...\n");
#saving the log file as filename.failed in case of retry #saving the log file as filename.failed in case of retry
my $worker_logdir= $result->{savedir}; if ( $result->is_failed() ) {
my $log_file_name=dirname($worker_logdir)."/".$result->{shortname}.".log"; my $worker_logdir= $result->{savedir};
rename $log_file_name,$log_file_name.".failed"; my $log_file_name=dirname($worker_logdir)."/".$result->{shortname}.".log";
rename $log_file_name,$log_file_name.".failed";
}
delete($result->{result}); delete($result->{result});
$result->{retries}= $retries+1; $result->{retries}= $retries+1;
$result->write_test($sock, 'TESTCASE'); $result->write_test($sock, 'TESTCASE');
......
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