~drizzle-trunk/drizzle/development

« back to all changes in this revision

Viewing changes to runall.pl

provide textual exit codes for various scripts and not jus numbers

Show diffs side-by-side

added added

removed removed

Lines of Context:
107
107
    'testname=s' => \$testname
108
108
);
109
109
 
 
110
$ENV{RQG_DEBUG} = 1 if defined $debug;
 
111
 
110
112
$validators = join(',', @$validators) if defined $validators;
111
113
$reporters = join(',', @$reporters) if defined $reporters;
112
114
 
365
367
# lib/GenTest/Generator/FromGrammar.pm will generate a corresponding grammar element.
366
368
$ENV{RQG_THREADS}= $threads;
367
369
 
368
 
my $gentest_result = system("perl $ENV{RQG_HOME}gentest.pl ".join(' ', @gentest_options));
369
 
say("gentest.pl exited with exit status ".($gentest_result >> 8));
370
 
exit_test($gentest_result >> 8) if $gentest_result > 0;
 
370
my $gentest_result = system("perl $ENV{RQG_HOME}gentest.pl ".join(' ', @gentest_options)) >> 8;
 
371
say("gentest.pl exited with exit status ".status2text($gentest_result). " ($gentest_result)");
 
372
exit_test($gentest_result) if $gentest_result > 0;
371
373
 
372
374
if ($rpl_mode) {
373
375
        my ($file, $pos) = $master_dbh->selectrow_array("SHOW MASTER STATUS");
493
495
sub exit_test {
494
496
        my $status = shift;
495
497
 
496
 
        print isoTimestamp()." [$$] $0 will exit with exit status $status\n";
 
498
        print isoTimestamp()." [$$] $0 will exit with exit status ".status2text($status)." ($status)\n";
497
499
        safe_exit($status);
498
500
}