#At file:///mnt/raid/alik/MySQL/bzr/6.0/
2690 Alexander Nozdrin 2008-08-04
Add a test case for Bug#31302: USE information_schema disables DROP tablespace.
modified:
mysql-test/suite/falcon/r/falcon_tablespace_priv.result
mysql-test/suite/falcon/t/falcon_tablespace_priv.test
=== modified file 'mysql-test/suite/falcon/r/falcon_tablespace_priv.result'
--- a/mysql-test/suite/falcon/r/falcon_tablespace_priv.result 2008-07-25 18:44:20 +0000
+++ b/mysql-test/suite/falcon/r/falcon_tablespace_priv.result 2008-08-04 06:58:12 +0000
@@ -42,3 +42,29 @@ ERROR 42000: Access denied; you need the
DROP USER mysqltest_u1@localhost;
DROP USER mysqltest_u2@localhost;
+# --
+# -- Bug#31302: USE information_schema disables DROP tablespace
+# --
+GRANT CREATE TABLESPACE ON *.* TO mysqltest_u1@localhost;
+
+# -- Connection: mysqltest_u1@localhost
+
+# -- Grants for mysqltest_u1@localhost:
+SHOW GRANTS;
+Grants for mysqltest_u1@localhost
+GRANT CREATE TABLESPACE ON *.* TO 'mysqltest_u1'@'localhost'
+
+# -- CREATE TABLESPACE...
+CREATE TABLESPACE ts1
+ADD DATAFILE 'datafile.dat'
+ENGINE = Falcon;
+
+use INFORMATION_SCHEMA;
+
+# -- DROP TABLESPACE...
+DROP TABLESPACE ts1
+ENGINE = Falcon;
+
+# -- Connection: root@localhost
+
+DROP USER mysqltest_u1@localhost;
=== modified file 'mysql-test/suite/falcon/t/falcon_tablespace_priv.test'
--- a/mysql-test/suite/falcon/t/falcon_tablespace_priv.test 2008-07-25 18:44:20 +0000
+++ b/mysql-test/suite/falcon/t/falcon_tablespace_priv.test 2008-08-04 06:58:12 +0000
@@ -56,3 +56,39 @@ ENGINE = Falcon;
DROP USER mysqltest_u1@localhost;
DROP USER mysqltest_u2@localhost;
+
+--echo # --
+--echo # -- Bug#31302: USE information_schema disables DROP tablespace
+--echo # --
+
+GRANT CREATE TABLESPACE ON *.* TO mysqltest_u1@localhost;
+
+--echo
+--echo # -- Connection: mysqltest_u1@localhost
+--echo
+--connect(con1, localhost, mysqltest_u1,,)
+
+--echo # -- Grants for mysqltest_u1@localhost:
+SHOW GRANTS;
+
+--echo
+--echo # -- CREATE TABLESPACE...
+CREATE TABLESPACE ts1
+ADD DATAFILE 'datafile.dat'
+ENGINE = Falcon;
+
+--echo
+use INFORMATION_SCHEMA;
+
+--echo
+--echo # -- DROP TABLESPACE...
+DROP TABLESPACE ts1
+ENGINE = Falcon;
+
+--echo
+--echo # -- Connection: root@localhost
+--echo
+--connection default
+--disconnect con1
+
+DROP USER mysqltest_u1@localhost;
| Thread |
|---|
| • bzr commit into mysql-6.0 branch (alik:2690) Bug#31302 | Alexander Nozdrin | 4 Aug |