summaryrefslogtreecommitdiff
path: root/mysql-test/suite/galera
diff options
context:
space:
mode:
authorOleksandr Byelkin <sanja@mariadb.com>2022-06-13 14:37:59 +0200
committerSergei Golubchik <serg@mariadb.org>2022-11-01 16:33:00 +0100
commit594bed9b427704001fc4beca9943006a605305f4 (patch)
tree62fe26dcdaded3b8b05ccf1ad9afaee2f1bdf035 /mysql-test/suite/galera
parent749c12782298dce721656cd357e339643a7d8af4 (diff)
downloadmariadb-git-594bed9b427704001fc4beca9943006a605305f4.tar.gz
MDEV-5215 prerequisite: remove test and test_* database hacks in the test suite
Diffstat (limited to 'mysql-test/suite/galera')
-rw-r--r--mysql-test/suite/galera/r/galera_create_procedure.result1
-rw-r--r--mysql-test/suite/galera/r/galera_create_trigger.result1
-rw-r--r--mysql-test/suite/galera/r/galera_read_only.result1
-rw-r--r--mysql-test/suite/galera/r/galera_roles.result4
-rw-r--r--mysql-test/suite/galera/t/galera_create_procedure.test1
-rw-r--r--mysql-test/suite/galera/t/galera_create_trigger.test1
-rw-r--r--mysql-test/suite/galera/t/galera_read_only.test1
-rw-r--r--mysql-test/suite/galera/t/galera_roles.test4
8 files changed, 10 insertions, 4 deletions
diff --git a/mysql-test/suite/galera/r/galera_create_procedure.result b/mysql-test/suite/galera/r/galera_create_procedure.result
index 24a0bd66b39..27bdf19f256 100644
--- a/mysql-test/suite/galera/r/galera_create_procedure.result
+++ b/mysql-test/suite/galera/r/galera_create_procedure.result
@@ -2,6 +2,7 @@ connection node_2;
connection node_1;
connection node_1;
CREATE USER 'user1';
+GRANT ALL ON test.* to 'user1';
CREATE TABLE t1 (f1 INTEGER);
CREATE
DEFINER = 'user1'
diff --git a/mysql-test/suite/galera/r/galera_create_trigger.result b/mysql-test/suite/galera/r/galera_create_trigger.result
index 56b35150d87..4244e4c85ad 100644
--- a/mysql-test/suite/galera/r/galera_create_trigger.result
+++ b/mysql-test/suite/galera/r/galera_create_trigger.result
@@ -5,6 +5,7 @@ CREATE TABLE definer_user (f1 INTEGER, trigger_user VARCHAR(100)) ENGINE=InnoDB;
CREATE TABLE definer_current_user (f1 INTEGER, trigger_user VARCHAR(100)) ENGINE=InnoDB;
CREATE TABLE definer_default (f1 INTEGER, trigger_user VARCHAR(100)) ENGINE=InnoDB;
CREATE USER 'user1';
+GRANT ALL ON test.* to 'user1';
CREATE DEFINER=root@localhost TRIGGER definer_root BEFORE INSERT ON definer_root FOR EACH ROW SET NEW.trigger_user = CURRENT_USER();
CREATE DEFINER=user1 TRIGGER definer_user BEFORE INSERT ON definer_user FOR EACH ROW SET NEW.trigger_user = CURRENT_USER();
CREATE DEFINER=current_user TRIGGER definer_current_user BEFORE INSERT ON definer_current_user FOR EACH ROW SET NEW.trigger_user = CURRENT_USER();
diff --git a/mysql-test/suite/galera/r/galera_read_only.result b/mysql-test/suite/galera/r/galera_read_only.result
index e7e18ca8145..0928c62f23b 100644
--- a/mysql-test/suite/galera/r/galera_read_only.result
+++ b/mysql-test/suite/galera/r/galera_read_only.result
@@ -10,6 +10,7 @@ SELECT COUNT(*) = 1 FROM t1;
COUNT(*) = 1
1
CREATE USER foo@localhost;
+GRANT ALL ON test.* to foo@localhost;
# Open connection to node 2 using 'foo' user.
connect foo_node_2,127.0.0.1,foo,,test,$port_2,;
diff --git a/mysql-test/suite/galera/r/galera_roles.result b/mysql-test/suite/galera/r/galera_roles.result
index 19bc9be62b0..fccef1637f6 100644
--- a/mysql-test/suite/galera/r/galera_roles.result
+++ b/mysql-test/suite/galera/r/galera_roles.result
@@ -21,8 +21,8 @@ GRANT EXECUTE ON PROCEDURE test1.pr1 TO role1;
GRANT SELECT ON test1.t1 TO role1;
GRANT SELECT (a) ON test1.t2 TO role1;
# Open connections to the 2 nodes using 'foo' user.
-connect foo_node_1,127.0.0.1,foo,,test,$port_1,;
-connect foo_node_2,127.0.0.1,foo,,test,$port_2,;
+connect foo_node_1,127.0.0.1,foo,,"*NO-ONE*",$port_1,;
+connect foo_node_2,127.0.0.1,foo,,"*NO-ONE*",$port_2,;
# Connect with foo_node_1
connection foo_node_1;
diff --git a/mysql-test/suite/galera/t/galera_create_procedure.test b/mysql-test/suite/galera/t/galera_create_procedure.test
index 30bc85fcea0..4947a446e9e 100644
--- a/mysql-test/suite/galera/t/galera_create_procedure.test
+++ b/mysql-test/suite/galera/t/galera_create_procedure.test
@@ -7,6 +7,7 @@
--connection node_1
CREATE USER 'user1';
+GRANT ALL ON test.* to 'user1';
CREATE TABLE t1 (f1 INTEGER);
CREATE
diff --git a/mysql-test/suite/galera/t/galera_create_trigger.test b/mysql-test/suite/galera/t/galera_create_trigger.test
index 6708e30bf0f..c76981aae29 100644
--- a/mysql-test/suite/galera/t/galera_create_trigger.test
+++ b/mysql-test/suite/galera/t/galera_create_trigger.test
@@ -11,6 +11,7 @@ CREATE TABLE definer_current_user (f1 INTEGER, trigger_user VARCHAR(100)) ENGINE
CREATE TABLE definer_default (f1 INTEGER, trigger_user VARCHAR(100)) ENGINE=InnoDB;
CREATE USER 'user1';
+GRANT ALL ON test.* to 'user1';
CREATE DEFINER=root@localhost TRIGGER definer_root BEFORE INSERT ON definer_root FOR EACH ROW SET NEW.trigger_user = CURRENT_USER();
CREATE DEFINER=user1 TRIGGER definer_user BEFORE INSERT ON definer_user FOR EACH ROW SET NEW.trigger_user = CURRENT_USER();
CREATE DEFINER=current_user TRIGGER definer_current_user BEFORE INSERT ON definer_current_user FOR EACH ROW SET NEW.trigger_user = CURRENT_USER();
diff --git a/mysql-test/suite/galera/t/galera_read_only.test b/mysql-test/suite/galera/t/galera_read_only.test
index 56fe2fdd910..8d8a8cf88aa 100644
--- a/mysql-test/suite/galera/t/galera_read_only.test
+++ b/mysql-test/suite/galera/t/galera_read_only.test
@@ -18,6 +18,7 @@ INSERT INTO t1 VALUES (1);
SELECT COUNT(*) = 1 FROM t1;
CREATE USER foo@localhost;
+GRANT ALL ON test.* to foo@localhost;
--echo # Open connection to node 2 using 'foo' user.
--let $port_2= \$NODE_MYPORT_2
diff --git a/mysql-test/suite/galera/t/galera_roles.test b/mysql-test/suite/galera/t/galera_roles.test
index 3005562db9c..e71ca42f2d8 100644
--- a/mysql-test/suite/galera/t/galera_roles.test
+++ b/mysql-test/suite/galera/t/galera_roles.test
@@ -33,11 +33,11 @@ GRANT SELECT (a) ON test1.t2 TO role1;
--echo # Open connections to the 2 nodes using 'foo' user.
--let $port_1= \$NODE_MYPORT_1
---connect(foo_node_1,127.0.0.1,foo,,test,$port_1,)
+--connect(foo_node_1,127.0.0.1,foo,,"*NO-ONE*",$port_1,)
--let $port_2= \$NODE_MYPORT_2
--sleep 1
---connect(foo_node_2,127.0.0.1,foo,,test,$port_2,)
+--connect(foo_node_2,127.0.0.1,foo,,"*NO-ONE*",$port_2,)
--echo
--echo # Connect with foo_node_1