diff options
author | Marko Mäkelä <marko.makela@mariadb.com> | 2019-07-02 21:44:58 +0300 |
---|---|---|
committer | Marko Mäkelä <marko.makela@mariadb.com> | 2019-07-02 21:44:58 +0300 |
commit | 7a3d34d6456ed719da62a896e5ac6e983b72f3d8 (patch) | |
tree | 38dc1133cd53a366e7a851cfba6dad1269dcd5a1 /plugin/disks/mysql-test | |
parent | faeaf978b8c1deaa61d7d408fa6cb4ed03bfcfa3 (diff) | |
parent | 1d45b3b055511d58c1e820ad497793f30871586e (diff) | |
download | mariadb-git-7a3d34d6456ed719da62a896e5ac6e983b72f3d8.tar.gz |
Merge 10.3 into 10.4
Diffstat (limited to 'plugin/disks/mysql-test')
-rw-r--r-- | plugin/disks/mysql-test/disks/disks_notembedded.result | 22 | ||||
-rw-r--r-- | plugin/disks/mysql-test/disks/disks_notembedded.test | 25 |
2 files changed, 47 insertions, 0 deletions
diff --git a/plugin/disks/mysql-test/disks/disks_notembedded.result b/plugin/disks/mysql-test/disks/disks_notembedded.result new file mode 100644 index 00000000000..974294744cc --- /dev/null +++ b/plugin/disks/mysql-test/disks/disks_notembedded.result @@ -0,0 +1,22 @@ +# +# MDEV-18328: Make DISKS plugin check some privilege to access +# information_schema.DISKS table +# +CREATE USER user1@localhost; +GRANT SELECT ON *.* TO user1@localhost; +connect con1,localhost,user1,,; +connection con1; +select sum(Total) > sum(Available), sum(Total)>sum(Used) from information_schema.disks; +sum(Total) > sum(Available) sum(Total)>sum(Used) +NULL NULL +disconnect con1; +connection default; +GRANT FILE ON *.* TO user1@localhost; +connect con1,localhost,user1,,; +connection con1; +select sum(Total) > sum(Available), sum(Total)>sum(Used) from information_schema.disks; +sum(Total) > sum(Available) sum(Total)>sum(Used) +1 1 +connection default; +DROP USER user1@localhost; +# End of 10.1 tests diff --git a/plugin/disks/mysql-test/disks/disks_notembedded.test b/plugin/disks/mysql-test/disks/disks_notembedded.test new file mode 100644 index 00000000000..a0f6c2e5887 --- /dev/null +++ b/plugin/disks/mysql-test/disks/disks_notembedded.test @@ -0,0 +1,25 @@ +source include/not_embedded.inc; + +--echo # +--echo # MDEV-18328: Make DISKS plugin check some privilege to access +--echo # information_schema.DISKS table +--echo # + +CREATE USER user1@localhost; +GRANT SELECT ON *.* TO user1@localhost; + +connect (con1,localhost,user1,,); +connection con1; +select sum(Total) > sum(Available), sum(Total)>sum(Used) from information_schema.disks; +disconnect con1; + +connection default; +GRANT FILE ON *.* TO user1@localhost; + +connect (con1,localhost,user1,,); +connection con1; +select sum(Total) > sum(Available), sum(Total)>sum(Used) from information_schema.disks; +connection default; +DROP USER user1@localhost; + +--echo # End of 10.1 tests |