summaryrefslogtreecommitdiff
path: root/mysql-test/t/rpl_reset_slave.test
diff options
context:
space:
mode:
Diffstat (limited to 'mysql-test/t/rpl_reset_slave.test')
-rw-r--r--mysql-test/t/rpl_reset_slave.test26
1 files changed, 26 insertions, 0 deletions
diff --git a/mysql-test/t/rpl_reset_slave.test b/mysql-test/t/rpl_reset_slave.test
new file mode 100644
index 00000000000..9c58ac0c787
--- /dev/null
+++ b/mysql-test/t/rpl_reset_slave.test
@@ -0,0 +1,26 @@
+# See SHOW SLAVE STATUS displays well after RESET SLAVE (it should display the
+# --master-* options from mysqld, as this is what is going to be used next time
+# slave threads will be started). In bug 985, it displayed old values (of before
+# RESET SLAVE).
+
+source include/master-slave.inc;
+connection master;
+save_master_pos;
+connection slave;
+sync_with_master;
+--replace_result $MASTER_MYPORT MASTER_PORT
+show slave status;
+
+stop slave;
+change master to master_user='test';
+--replace_result $MASTER_MYPORT MASTER_PORT
+show slave status;
+
+reset slave;
+--replace_result $MASTER_MYPORT MASTER_PORT
+show slave status;
+
+start slave;
+sync_with_master;
+--replace_result $MASTER_MYPORT MASTER_PORT
+show slave status;