diff options
author | unknown <ranger@regul.home.lan> | 2005-12-16 00:23:55 +0200 |
---|---|---|
committer | unknown <ranger@regul.home.lan> | 2005-12-16 00:23:55 +0200 |
commit | 10aaad659be6777b38e1e81195e36a98b02a72cc (patch) | |
tree | 41e4e7b78d6423f361de0d384d9606ab90cd6c77 | |
parent | bf4b5b39102e9502d97330c65a664762366d01e3 (diff) | |
download | mariadb-git-10aaad659be6777b38e1e81195e36a98b02a72cc.tar.gz |
Fixed stress parts in shell and perl versions of mysql-test-run script to limit stress testing
with 20 test loops in case when any limit parameter was specified
mysql-test/lib/mtr_stress.pl:
Limit stress testing with 20 test loops in case when any limit parameter was specified
mysql-test/mysql-test-run.pl:
Limit stress testing with 20 test loops in case when any limit parameter was specified
mysql-test/mysql-test-run.sh:
Limit stress testing with 20 test loops in case when any limit parameter was specified
-rw-r--r-- | mysql-test/lib/mtr_stress.pl | 8 | ||||
-rwxr-xr-x | mysql-test/mysql-test-run.pl | 2 | ||||
-rw-r--r-- | mysql-test/mysql-test-run.sh | 12 |
3 files changed, 19 insertions, 3 deletions
diff --git a/mysql-test/lib/mtr_stress.pl b/mysql-test/lib/mtr_stress.pl index a57d94e8043..d3ed24db545 100644 --- a/mysql-test/lib/mtr_stress.pl +++ b/mysql-test/lib/mtr_stress.pl @@ -145,6 +145,14 @@ sub run_stress_test () mtr_add_arg($args, "--stress-init-file=%", $::opt_stress_init_file); } + if ( !$::opt_stress_loop_count && !$::opt_stress_test_count && + !$::opt_stress_test_duration ) + { + #Limit stress testing with 20 loops in case when any limit parameter + #was specified + $::opt_stress_test_count=20; + } + if ( $::opt_stress_loop_count ) { mtr_add_arg($args, "--loop-count=%s", $::opt_stress_loop_count); diff --git a/mysql-test/mysql-test-run.pl b/mysql-test/mysql-test-run.pl index 8ccd87fc7a8..0513d3d4a1a 100755 --- a/mysql-test/mysql-test-run.pl +++ b/mysql-test/mysql-test-run.pl @@ -276,7 +276,7 @@ our $opt_stress= ""; our $opt_stress_suite= "main"; our $opt_stress_mode= "random"; our $opt_stress_threads= 5; -our $opt_stress_test_count= 20; +our $opt_stress_test_count= ""; our $opt_stress_loop_count= ""; our $opt_stress_test_duration= ""; our $opt_stress_init_file= ""; diff --git a/mysql-test/mysql-test-run.sh b/mysql-test/mysql-test-run.sh index c84763713e1..a115a82a6a4 100644 --- a/mysql-test/mysql-test-run.sh +++ b/mysql-test/mysql-test-run.sh @@ -279,7 +279,7 @@ DO_STRESS="" STRESS_SUITE="main" STRESS_MODE="random" STRESS_THREADS=5 -STRESS_TEST_COUNT=20 +STRESS_TEST_COUNT="" STRESS_LOOP_COUNT="" STRESS_TEST_DURATION="" STRESS_INIT_FILE="" @@ -1906,7 +1906,7 @@ run_stress_test() --stress-basedir=$STRESS_BASEDIR \ --server-logs-dir=$STRESS_BASEDIR \ --stress-mode=$STRESS_MODE \ - --mysqltest=$BASEDIR/client/mysqltest \ + --mysqltest=$CLIENT_BINDIR/mysqltest \ --threads=$STRESS_THREADS \ --verbose \ --cleanup \ @@ -1917,6 +1917,14 @@ run_stress_test() STRESS_TEST_ARGS="$STRESS_TEST_ARGS --stress-init-file=$STRESS_INIT_FILE" fi + if [ -z "$STRESS_LOOP_COUNT" -a -z "$STRESS_TEST_COUNT" -a + -z "$STRESS_TEST_DURATION" ] ; then + + #Limit stress testing with 20 loops in case when any limit parameter + #was specified + STRESS_TEST_COUNT=20 + fi + if [ -n "$STRESS_LOOP_COUNT" ] ; then STRESS_TEST_ARGS="$STRESS_TEST_ARGS --loop-count=$STRESS_LOOP_COUNT" fi |