summaryrefslogtreecommitdiff
path: root/mysql-test/suite/wsrep/t/variables.test
diff options
context:
space:
mode:
authorNirbhay Choubey <nirbhay@skysql.com>2014-02-14 11:38:46 -0500
committerNirbhay Choubey <nirbhay@skysql.com>2014-02-14 11:38:46 -0500
commit8e476e6cbe313fadb6e0cd4402ff8c9d2d487406 (patch)
tree9c3d55cd08893b821c355fded3d962bb79a0e67c /mysql-test/suite/wsrep/t/variables.test
parente0f0f5f6d0b983619a67725c6a3351c31a547852 (diff)
downloadmariadb-git-8e476e6cbe313fadb6e0cd4402ff8c9d2d487406.tar.gz
MDEV#5534: mysql_tzinfo_to_sql generates wrong query
mysql_tzinfo_to_sql tries to set wsrep_replicate_myisam as SESSION variable, while its a GLOBAL-only system variable, and thus the resulting sql would fail to load. Fixed by changing the scope to GLOBAL in the SET command. Also added following include files to facilitate testing : * include/have_wsrep.inc * include/not_wsrep.inc * include/have_wsrep_enabled.inc
Diffstat (limited to 'mysql-test/suite/wsrep/t/variables.test')
-rw-r--r--mysql-test/suite/wsrep/t/variables.test19
1 files changed, 19 insertions, 0 deletions
diff --git a/mysql-test/suite/wsrep/t/variables.test b/mysql-test/suite/wsrep/t/variables.test
new file mode 100644
index 00000000000..306cdf9b2c9
--- /dev/null
+++ b/mysql-test/suite/wsrep/t/variables.test
@@ -0,0 +1,19 @@
+--source include/have_wsrep.inc
+
+--echo
+--echo # MDEV#5534: mysql_tzinfo_to_sql generates wrong query
+--echo #
+--echo # Testing wsrep_replicate_myisam variable.
+
+--error ER_INCORRECT_GLOBAL_LOCAL_VAR
+SELECT @@session.wsrep_replicate_myisam;
+SELECT @@global.wsrep_replicate_myisam;
+
+--error ER_GLOBAL_VARIABLE
+SET SESSION wsrep_replicate_myisam= ON;
+SET GLOBAL wsrep_replicate_myisam= ON;
+
+# Reset it back.
+SET GLOBAL wsrep_replicate_myisam= OFF;
+
+--echo # End of test.