Commit 76f7efc5 authored by unknown's avatar unknown

Remove warnings

Set comment properly before calling mtr_report_test failed and report_failure_restart 


mysql-test/lib/mtr_report.pl:
  Remove warnings
  No need to check ndb installed ok here, when that is detected comment is set to indicate the problem
parent f3531e90
......@@ -130,16 +130,11 @@ sub mtr_report_test_failed ($) {
my $tinfo= shift;
$tinfo->{'result'}= 'MTR_RES_FAILED';
if ( $tinfo->{'timeout'} )
if ( defined $tinfo->{'timeout'} )
{
print "[ fail ] timeout\n";
return;
}
elsif ( $tinfo->{'ndb_test'} and $::cluster->[0]->{'installed_ok'} eq "NO")
{
print "[ fail ] ndbcluster start failure\n";
return;
}
else
{
print "[ fail ]\n";
......
......@@ -2755,10 +2755,9 @@ sub run_testcase_check_skip_test($)
# If test needs this cluster, check it was installed ok
if ( !$cluster->{'installed_ok'} )
{
mtr_tofile($path_timefile,
"Test marked as failed because $cluster->{'name'} " .
"was not installed ok!");
mtr_report_test_name($tinfo);
$tinfo->{comment}=
"Cluster $cluster->{'name'} was not installed ok";
mtr_report_test_failed($tinfo);
return 1;
}
......@@ -2881,10 +2880,8 @@ sub run_testcase ($) {
# Can't restart a running server that may be in use
if ( $glob_use_running_server )
{
$tinfo->{'skip'}= 1;
$tinfo->{'comment'}= "Can't restart a running server";
mtr_report_test_name($tinfo);
$tinfo->{comment}= "Can't restart a running server";
mtr_report_test_skipped($tinfo);
return;
}
......@@ -2934,16 +2931,16 @@ sub run_testcase ($) {
$tinfo->{'timeout'}= 1; # Mark as timeout
report_failure_and_restart($tinfo);
}
elsif ( $res == 1 )
{
# Test case failure reported by mysqltest
report_failure_and_restart($tinfo);
}
else
{
# Test case failed, if in control mysqltest returns 1
if ( $res != 1 )
{
mtr_tofile($path_timefile,
"mysqltest returned unexpected code $res, " .
"it has probably crashed");
}
# mysqltest failed, probably crashed
$tinfo->{comment}=
"mysqltest returned unexpected code $res, it has probably crashed";
report_failure_and_restart($tinfo);
}
......
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