summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorunknown <sven@riska.(none)>2008-02-15 12:54:04 +0000
committerunknown <sven@riska.(none)>2008-02-15 12:54:04 +0000
commit3f0a603c9619f8cc45b8261d65ca737507212da0 (patch)
tree5019acdcc963db6a98566a892567c88e4f6a8762
parentdcb1b60b5d046338ccaef0722a57ac6d743c0d63 (diff)
downloadmariadb-git-3f0a603c9619f8cc45b8261d65ca737507212da0.tar.gz
Problem: After I moved rpl/t/rpl_variables.test into t/variables.test,
t/variables.test fails on embedded server. Moved out that part again, to a new test called t/variables-notembedded.test. mysql-test/t/variables-notembedded.test: BitKeeper file /home/sven/bk/debug-max/5.1-new-rpl/mysql-test/t/variables-notembedded.test mysql-test/r/variables-notembedded.result: Add -master.opt file to have a list of variables for slave_skip_errors. mysql-test/r/variables.result: Variable variables not available in embedded mode to a new test, variables-notembedded.test mysql-test/t/variables-notembedded-master.opt: Add --loose before --slave-skip-errors, so that it works if mtr is run with --embedded mysql-test/t/variables.test: Variable variables not available in embedded mode to a new test, variables-notembedded.test. Result file updated accordingly.
-rw-r--r--mysql-test/r/variables-notembedded.result17
-rw-r--r--mysql-test/r/variables.result14
-rw-r--r--mysql-test/t/variables-master.opt1
-rw-r--r--mysql-test/t/variables-notembedded-master.opt1
-rw-r--r--mysql-test/t/variables-notembedded.test30
-rw-r--r--mysql-test/t/variables.test19
6 files changed, 48 insertions, 34 deletions
diff --git a/mysql-test/r/variables-notembedded.result b/mysql-test/r/variables-notembedded.result
new file mode 100644
index 00000000000..48a1719e2c7
--- /dev/null
+++ b/mysql-test/r/variables-notembedded.result
@@ -0,0 +1,17 @@
+---- Init ----
+set @my_slave_net_timeout =@@global.slave_net_timeout;
+---- Test ----
+set global slave_net_timeout=100;
+set global sql_slave_skip_counter=100;
+show variables like 'slave_compressed_protocol';
+Variable_name Value
+slave_compressed_protocol OFF
+show variables like 'slave_load_tmpdir';
+Variable_name Value
+slave_load_tmpdir SLAVE_LOAD_TMPDIR
+show variables like 'slave_skip_errors';
+Variable_name Value
+slave_skip_errors 3,100,137,643,1752
+---- Clean Up ----
+set global slave_net_timeout=default;
+set global sql_slave_skip_counter= 0;
diff --git a/mysql-test/r/variables.result b/mysql-test/r/variables.result
index 395ba0eab48..e5c3c860c93 100644
--- a/mysql-test/r/variables.result
+++ b/mysql-test/r/variables.result
@@ -22,7 +22,6 @@ set @my_query_cache_limit =@@global.query_cache_limit;
set @my_query_cache_type =@@global.query_cache_type;
set @my_rpl_recovery_rank =@@global.rpl_recovery_rank;
set @my_server_id =@@global.server_id;
-set @my_slave_net_timeout =@@global.slave_net_timeout;
set @my_slow_launch_time =@@global.slow_launch_time;
set @my_storage_engine =@@global.storage_engine;
set @my_thread_cache_size =@@global.thread_cache_size;
@@ -982,17 +981,6 @@ show variables like 'hostname';
Variable_name Value
hostname #
End of 5.0 tests
-set global slave_net_timeout=100;
-set global sql_slave_skip_counter=100;
-show variables like 'slave_compressed_protocol';
-Variable_name Value
-slave_compressed_protocol OFF
-show variables like 'slave_load_tmpdir';
-Variable_name Value
-slave_load_tmpdir SLAVE_LOAD_TMPDIR
-show variables like 'slave_skip_errors';
-Variable_name Value
-slave_skip_errors 3,100,137,643,1752
set global binlog_cache_size =@my_binlog_cache_size;
set global connect_timeout =@my_connect_timeout;
set global delayed_insert_timeout =@my_delayed_insert_timeout;
@@ -1018,9 +1006,7 @@ set global query_cache_limit =@my_query_cache_limit;
set global query_cache_type =@my_query_cache_type;
set global rpl_recovery_rank =@my_rpl_recovery_rank;
set global server_id =@my_server_id;
-set global slave_net_timeout =@my_slave_net_timeout;
set global slow_launch_time =@my_slow_launch_time;
-set global sql_slave_skip_counter =0;
set global storage_engine =@my_storage_engine;
set global thread_cache_size =@my_thread_cache_size;
show global variables where Variable_name='table_definition_cache' or
diff --git a/mysql-test/t/variables-master.opt b/mysql-test/t/variables-master.opt
deleted file mode 100644
index a668c6bfbe8..00000000000
--- a/mysql-test/t/variables-master.opt
+++ /dev/null
@@ -1 +0,0 @@
---slave-skip-errors=3,100,137,643,1752
diff --git a/mysql-test/t/variables-notembedded-master.opt b/mysql-test/t/variables-notembedded-master.opt
new file mode 100644
index 00000000000..a684e591d10
--- /dev/null
+++ b/mysql-test/t/variables-notembedded-master.opt
@@ -0,0 +1 @@
+--loose-slave-skip-errors=3,100,137,643,1752
diff --git a/mysql-test/t/variables-notembedded.test b/mysql-test/t/variables-notembedded.test
new file mode 100644
index 00000000000..79011a89b36
--- /dev/null
+++ b/mysql-test/t/variables-notembedded.test
@@ -0,0 +1,30 @@
+# Tests that variables work correctly (setting and showing). This
+# test is like the main.variables test, but for variables not
+# available in embedded mode.
+
+source include/not_embedded.inc;
+
+--echo ---- Init ----
+# Backup global variables so they can be restored at end of test.
+set @my_slave_net_timeout =@@global.slave_net_timeout;
+
+--echo ---- Test ----
+set global slave_net_timeout=100;
+set global sql_slave_skip_counter=100;
+
+# End of 4.1 tests
+
+# BUG #7800: Add various-slave related variables to SHOW VARIABLES
+show variables like 'slave_compressed_protocol';
+--replace_column 2 SLAVE_LOAD_TMPDIR
+show variables like 'slave_load_tmpdir';
+# We just set some arbitrary values in variables-master.opt so we can test
+# that a list of values works correctly
+show variables like 'slave_skip_errors';
+
+--echo ---- Clean Up ----
+
+set global slave_net_timeout=default;
+# sql_slave_skip_counter is write-only, so we can't save previous
+# value and restore it here. That's ok, because it's normally 0.
+set global sql_slave_skip_counter= 0;
diff --git a/mysql-test/t/variables.test b/mysql-test/t/variables.test
index 404a98d1827..51f8d6db1db 100644
--- a/mysql-test/t/variables.test
+++ b/mysql-test/t/variables.test
@@ -31,7 +31,6 @@ set @my_query_cache_limit =@@global.query_cache_limit;
set @my_query_cache_type =@@global.query_cache_type;
set @my_rpl_recovery_rank =@@global.rpl_recovery_rank;
set @my_server_id =@@global.server_id;
-set @my_slave_net_timeout =@@global.slave_net_timeout;
set @my_slow_launch_time =@@global.slow_launch_time;
set @my_storage_engine =@@global.storage_engine;
set @my_thread_cache_size =@@global.thread_cache_size;
@@ -738,20 +737,6 @@ show variables like 'hostname';
--echo End of 5.0 tests
-#
-# BUG #7800: SHOW VARIABLES does not show slave-related configuration
-#
-set global slave_net_timeout=100;
-set global sql_slave_skip_counter=100;
-
-show variables like 'slave_compressed_protocol';
---replace_column 2 SLAVE_LOAD_TMPDIR
-show variables like 'slave_load_tmpdir';
-# We just set some arbitrary values in variables-master.opt so we can test
-# that a list of values is printed correctly.
-show variables like 'slave_skip_errors';
-
-#
# This is at the very after the versioned tests, since it involves doing
# cleanup
#
@@ -783,11 +768,7 @@ set global query_cache_limit =@my_query_cache_limit;
set global query_cache_type =@my_query_cache_type;
set global rpl_recovery_rank =@my_rpl_recovery_rank;
set global server_id =@my_server_id;
-set global slave_net_timeout =@my_slave_net_timeout;
set global slow_launch_time =@my_slow_launch_time;
-# sql_slave_skip_counter is write-only, so we can't save previous
-# value and restore it here. That's ok, because it's normally 0.
-set global sql_slave_skip_counter =0;
set global storage_engine =@my_storage_engine;
set global thread_cache_size =@my_thread_cache_size;