diff options
author | Bjorn Munch <Bjorn.Munch@sun.com> | 2009-06-03 12:46:04 +0200 |
---|---|---|
committer | Bjorn Munch <Bjorn.Munch@sun.com> | 2009-06-03 12:46:04 +0200 |
commit | 912f9718492061c4e07fc5173f87e26c0457fa36 (patch) | |
tree | ef05a919b7c76898c7f366c15403137670080df2 /mysql-test/mysql-test-run.pl | |
parent | 5ce3d7a202b3eb16a12b6a98939b7b33a3cb984d (diff) | |
download | mariadb-git-912f9718492061c4e07fc5173f87e26c0457fa36.tar.gz |
Bug #45256 Enable 'auto' for mtr --parallel
Let the user specify 'auto' for parallel value
Also set --parallel=auto in default.push so we can get this tested.
Diffstat (limited to 'mysql-test/mysql-test-run.pl')
-rwxr-xr-x | mysql-test/mysql-test-run.pl | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/mysql-test/mysql-test-run.pl b/mysql-test/mysql-test-run.pl index 68c32e8c0bb..2a6a069d81c 100755 --- a/mysql-test/mysql-test-run.pl +++ b/mysql-test/mysql-test-run.pl @@ -313,7 +313,7 @@ sub main { ####################################################################### my $num_tests= @$tests; - if ( not defined $opt_parallel ) { + if ( $opt_parallel eq "auto" ) { # Try to find a suitable value for number of workers my $sys_info= My::SysInfo->new(); @@ -795,7 +795,7 @@ sub command_line_setup { 'vs-config' => \$opt_vs_config, # Max number of parallel threads to use - 'parallel=i' => \$opt_parallel, + 'parallel=s' => \$opt_parallel, # Config file to use as template for all tests 'defaults-file=s' => \&collect_option, @@ -1135,9 +1135,9 @@ sub command_line_setup { # -------------------------------------------------------------------------- # Check parallel value # -------------------------------------------------------------------------- - if ($opt_parallel < 1) + if ($opt_parallel ne "auto" && $opt_parallel < 1) { - mtr_error("0 or negative parallel value makes no sense, use positive number"); + mtr_error("0 or negative parallel value makes no sense, use 'auto' or positive number"); } # -------------------------------------------------------------------------- @@ -5202,6 +5202,7 @@ Misc options fast Run as fast as possible, dont't wait for servers to shutdown etc. parallel=N Run tests in N parallel threads (default=1) + Use parallel=auto for auto-setting of N repeat=N Run each test N number of times retry=N Retry tests that fail N times, limit number of failures to $opt_retry_failure |