diff options
author | Sergei Golubchik <sergii@pisem.net> | 2013-09-06 22:31:30 +0200 |
---|---|---|
committer | Sergei Golubchik <sergii@pisem.net> | 2013-09-06 22:31:30 +0200 |
commit | b838d081ad346e52787753b1799c627922c4a6c7 (patch) | |
tree | dc8f1e21e6b40d5b72668571c570c9a3214fbf32 /mysql-test/t | |
parent | 824db55ce53963a64fcf648b54500df22c57e9b2 (diff) | |
parent | 72c36f4415815d55ddb82b23682f3c549906c00e (diff) | |
download | mariadb-git-b838d081ad346e52787753b1799c627922c4a6c7.tar.gz |
mysql-5.5.33 merge
Diffstat (limited to 'mysql-test/t')
-rw-r--r-- | mysql-test/t/client_xml.test | 2 | ||||
-rw-r--r-- | mysql-test/t/func_str.test | 8 | ||||
-rw-r--r-- | mysql-test/t/group_min_max.test | 2 | ||||
-rw-r--r-- | mysql-test/t/mysqldump.test | 22 | ||||
-rw-r--r-- | mysql-test/t/openssl_1.test | 8 | ||||
-rw-r--r-- | mysql-test/t/partition_myisam.test | 5 | ||||
-rw-r--r-- | mysql-test/t/plugin.test | 52 |
7 files changed, 76 insertions, 23 deletions
diff --git a/mysql-test/t/client_xml.test b/mysql-test/t/client_xml.test index 0847e2b366b..86ca0a920ad 100644 --- a/mysql-test/t/client_xml.test +++ b/mysql-test/t/client_xml.test @@ -23,7 +23,7 @@ insert into t1 values (1, 2, 'a&b a<b a>b'); --source include/count_sessions.inc --exec $MYSQL --xml test -e "select * from t1" ---exec $MYSQL_DUMP --xml --skip-create test +--exec $MYSQL_DUMP --xml --skip-create-options test --exec $MYSQL --xml test -e "select count(*) from t1" --exec $MYSQL --xml test -e "select 1 < 2 from dual" diff --git a/mysql-test/t/func_str.test b/mysql-test/t/func_str.test index 239317ae717..0715fca7d96 100644 --- a/mysql-test/t/func_str.test +++ b/mysql-test/t/func_str.test @@ -1381,14 +1381,14 @@ SELECT CONVERT(('' IN (REVERSE(CAST(('') AS DECIMAL)), '')), CHAR(3)); --echo # and other crashes --echo # CREATE TABLE t1 ( a TEXT ); -SELECT 'aaaaaaaaaaaaaa' INTO OUTFILE 'bug58165.txt'; +--replace_result $MYSQLTEST_VARDIR MYSQLTEST_VARDIR +--eval SELECT 'aaaaaaaaaaaaaa' INTO OUTFILE '$MYSQLTEST_VARDIR/tmp/bug58165.txt'; SELECT insert( substring_index( 'a', 'a', 'b' ), 1, 0, 'x' ); -LOAD DATA INFILE 'bug58165.txt' INTO TABLE t1; +--replace_result $MYSQLTEST_VARDIR MYSQLTEST_VARDIR +--eval LOAD DATA INFILE '$MYSQLTEST_VARDIR/tmp/bug58165.txt' INTO TABLE t1; SELECT * FROM t1; DROP TABLE t1; ---remove_file $mysqld_datadir/test/bug58165.txt - # # MDEV-759 lp:998340 - Valgrind complains on simple selects containing expression DAY(FROM_UNIXTIME(-1)) # diff --git a/mysql-test/t/group_min_max.test b/mysql-test/t/group_min_max.test index 034da4eb925..85559afb7b3 100644 --- a/mysql-test/t/group_min_max.test +++ b/mysql-test/t/group_min_max.test @@ -1367,6 +1367,8 @@ EXPLAIN SELECT a, COUNT(DISTINCT a), SUM(DISTINCT a) FROM t2 SELECT a, COUNT(DISTINCT a), SUM(DISTINCT a) FROM t2 WHERE b = 13 AND c = 42 GROUP BY a; +# This query could have been resolved using loose index scan since the second +# part of count(..) is defined by a constant predicate EXPLAIN SELECT COUNT(DISTINCT a, b), SUM(DISTINCT a) FROM t2 WHERE b = 42; SELECT COUNT(DISTINCT a, b), SUM(DISTINCT a) FROM t2 WHERE b = 42; diff --git a/mysql-test/t/mysqldump.test b/mysql-test/t/mysqldump.test index eaa2e7a8840..5af27607483 100644 --- a/mysql-test/t/mysqldump.test +++ b/mysql-test/t/mysqldump.test @@ -36,7 +36,7 @@ drop view if exists v1, v2, v3; CREATE TABLE t1(a INT, KEY (a)) KEY_BLOCK_SIZE=1024; INSERT INTO t1 VALUES (1), (2); ---exec $MYSQL_DUMP --skip-create --skip-comments -X test t1 +--exec $MYSQL_DUMP --skip-create-options --skip-comments -X test t1 DROP TABLE t1; --echo # @@ -79,14 +79,14 @@ SET SQL_MODE=@OLD_SQL_MODE; # check how mysqldump make quoting --exec $MYSQL_DUMP --compact test t1 ---exec $MYSQL_DUMP --compact --skip-create test t1 ---exec $MYSQL_DUMP --skip-create --skip-comments test t1 +--exec $MYSQL_DUMP --compact --skip-create-options test t1 +--exec $MYSQL_DUMP --skip-create-options --skip-comments test t1 --exec $MYSQL_DUMP --skip-opt --extended-insert --skip-comments test t1 DROP TABLE t1; CREATE TABLE t1(a int, b text, c varchar(3)); INSERT INTO t1 VALUES (1, "test", "tes"), (2, "TEST", "TES"); ---exec $MYSQL_DUMP --skip-create --compact -X test t1 +--exec $MYSQL_DUMP --skip-create-options --compact -X test t1 DROP TABLE t1; --echo # @@ -95,7 +95,7 @@ DROP TABLE t1; CREATE TABLE t1 (`a"b"` char(2)); INSERT INTO t1 VALUES ("1\""), ("\"2"); ---exec $MYSQL_DUMP --compact --skip-create -X test t1 +--exec $MYSQL_DUMP --compact --skip-create-options -X test t1 DROP TABLE t1; --echo # @@ -582,8 +582,8 @@ INSERT INTO t1 VALUES (1), (2); INSERT INTO t2 VALUES (1), (2); --exec $MYSQL_DUMP --skip-comments --no-data mysqldump_test_db --exec $MYSQL_DUMP --skip-comments --no-data mysqldump_test_db t1 t2 ---exec $MYSQL_DUMP --skip-comments --skip-create --xml --no-data mysqldump_test_db ---exec $MYSQL_DUMP --skip-comments --skip-create --xml --no-data mysqldump_test_db t1 t2 +--exec $MYSQL_DUMP --skip-comments --skip-create-options --xml --no-data mysqldump_test_db +--exec $MYSQL_DUMP --skip-comments --skip-create-options --xml --no-data mysqldump_test_db t1 t2 DROP TABLE t1, t2; DROP DATABASE mysqldump_test_db; @@ -1634,7 +1634,7 @@ drop database mysqldump_test_db; CREATE TABLE t1 (c1 INT, c2 LONGBLOB); INSERT INTO t1 SET c1=11, c2=REPEAT('q',509); ---exec $MYSQL_DUMP --skip-create --compact --hex-blob test t1 +--exec $MYSQL_DUMP --skip-create-options --compact --hex-blob test t1 DROP TABLE t1; --echo # @@ -2216,7 +2216,7 @@ DROP TABLE t1, t2; --echo # CREATE TABLE `comment_table` (i INT COMMENT 'FIELD COMMENT') COMMENT = 'TABLE COMMENT'; ---exec $MYSQL_DUMP --compact --skip-create --xml test +--exec $MYSQL_DUMP --compact --skip-create-options --xml test DROP TABLE `comment_table`; --echo # @@ -2385,7 +2385,7 @@ CREATE TABLE b12809202_db.t2 (c1 INT); INSERT INTO b12809202_db.t1 VALUES (1), (2), (3); INSERT INTO b12809202_db.t2 VALUES (1), (2), (3); ---echo # Starting mysqldump with --single-transaction & --flush-log options.. +--echo # Starting mysqldump with --single-transaction & --flush-logs options.. --echo # Note : In the following dump the transaction --echo # should start only after the logs are --echo # flushed, as 'flush logs' causes implicit @@ -2397,7 +2397,7 @@ INSERT INTO b12809202_db.t2 VALUES (1), (2), (3); # mixing of normal (stdout) and --verbose (stderr) output will happen in random # order depending on stdio internal buffer size. --replace_regex /-- Server version.*// /-- MySQL dump .*// /-- Dump completed on .*/-- Dump completed/ ---exec $MYSQL_DUMP --verbose --single-transaction --flush-log b12809202_db 2>&1 > $MYSQLTEST_VARDIR/tmp/bug61854.sql +--exec $MYSQL_DUMP --verbose --single-transaction --flush-logs b12809202_db 2>&1 > $MYSQLTEST_VARDIR/tmp/bug61854.sql --echo --echo #### Dump ends here #### diff --git a/mysql-test/t/openssl_1.test b/mysql-test/t/openssl_1.test index 61e0dcc7197..0c8f81e4712 100644 --- a/mysql-test/t/openssl_1.test +++ b/mysql-test/t/openssl_1.test @@ -196,16 +196,16 @@ CREATE TABLE t1(a int); INSERT INTO t1 VALUES (1), (2); # Run mysqldump ---exec $MYSQL_DUMP --skip-create --skip-comments --ssl-key=$MYSQL_TEST_DIR/std_data/client-key.pem --ssl-cert=$MYSQL_TEST_DIR/std_data/client-cert.pem test t1 +--exec $MYSQL_DUMP --skip-create-options --skip-comments --ssl-key=$MYSQL_TEST_DIR/std_data/client-key.pem --ssl-cert=$MYSQL_TEST_DIR/std_data/client-cert.pem test t1 ---exec $MYSQL_DUMP --skip-create --skip-comments --ssl-ca=$MYSQL_TEST_DIR/std_data/cacert.pem --ssl-key=$MYSQL_TEST_DIR/std_data/client-key.pem --ssl-cert=$MYSQL_TEST_DIR/std_data/client-cert.pem test +--exec $MYSQL_DUMP --skip-create-options --skip-comments --ssl-ca=$MYSQL_TEST_DIR/std_data/cacert.pem --ssl-key=$MYSQL_TEST_DIR/std_data/client-key.pem --ssl-cert=$MYSQL_TEST_DIR/std_data/client-cert.pem test ---exec $MYSQL_DUMP --skip-create --skip-comments --ssl --ssl-ca=$MYSQL_TEST_DIR/std_data/cacert.pem --ssl-key=$MYSQL_TEST_DIR/std_data/client-key.pem --ssl-cert=$MYSQL_TEST_DIR/std_data/client-cert.pem test +--exec $MYSQL_DUMP --skip-create-options --skip-comments --ssl --ssl-ca=$MYSQL_TEST_DIR/std_data/cacert.pem --ssl-key=$MYSQL_TEST_DIR/std_data/client-key.pem --ssl-cert=$MYSQL_TEST_DIR/std_data/client-cert.pem test # With wrong parameters --replace_result $MYSQL_TEST_DIR MYSQL_TEST_DIR mysqldump.exe mysqldump --error 2 ---exec $MYSQL_DUMP --skip-create --skip-comments --ssl --ssl-cert=$MYSQL_TEST_DIR/std_data/client-cert.pem test 2>&1 +--exec $MYSQL_DUMP --skip-create-options --skip-comments --ssl --ssl-cert=$MYSQL_TEST_DIR/std_data/client-cert.pem test 2>&1 DROP TABLE t1; --remove_file $MYSQLTEST_VARDIR/tmp/test.sql diff --git a/mysql-test/t/partition_myisam.test b/mysql-test/t/partition_myisam.test index 49c5d793169..0fdd351c714 100644 --- a/mysql-test/t/partition_myisam.test +++ b/mysql-test/t/partition_myisam.test @@ -87,11 +87,10 @@ FLUSH TABLES; CHECK TABLE t1; --error ER_FAILED_READ_FROM_PAR_FILE SELECT * FROM t1; ---echo # Note that it is currently impossible to drop a partitioned table ---echo # without the .par file +--echo # Note that we will remove the frm file when we detect that +--echo # .par file has been deleted. --error ER_BAD_TABLE_ERROR DROP TABLE t1; ---remove_file $MYSQLD_DATADIR/test/t1.frm --remove_file $MYSQLD_DATADIR/test/t1#P#p0.MYI --remove_file $MYSQLD_DATADIR/test/t1#P#p0.MYD diff --git a/mysql-test/t/plugin.test b/mysql-test/t/plugin.test index 18a928a9260..49f4ae9f1c3 100644 --- a/mysql-test/t/plugin.test +++ b/mysql-test/t/plugin.test @@ -149,6 +149,58 @@ SET @@SQL_MODE=@OLD_SQL_MODE; select 1; UNINSTALL PLUGIN example; +--echo # +--echo # Bug #16194302 SUPPORT FOR FLOATING-POINT SYSTEM +--echo # VARIABLES USING THE PLUGIN INTERFACE. +--echo # + +--replace_regex /\.dll/.so/ +eval INSTALL PLUGIN example SONAME 'ha_example'; + +SET GLOBAL example_double_var = -0.1; +SELECT @@GLOBAL.example_double_var; + +SET GLOBAL example_double_var = 0.000001; +SELECT @@GLOBAL.example_double_var; + +SET GLOBAL example_double_var = 0.4; +SELECT @@GLOBAL.example_double_var; + +SET GLOBAL example_double_var = 123.456789; +SELECT @@GLOBAL.example_double_var; + +SET GLOBAL example_double_var = 500; +SELECT @@GLOBAL.example_double_var; + +SET GLOBAL example_double_var = 999.999999; +SELECT @@GLOBAL.example_double_var; + +SET GLOBAL example_double_var = 1000.51; +SELECT @@GLOBAL.example_double_var; + +SET SESSION example_double_thdvar = -0.1; +SELECT @@SESSION.example_double_thdvar; + +SET SESSION example_double_thdvar = 0.000001; +SELECT @@SESSION.example_double_thdvar; + +SET SESSION example_double_thdvar = 0.4; +SELECT @@SESSION.example_double_thdvar; + +SET SESSION example_double_thdvar = 123.456789; +SELECT @@SESSION.example_double_thdvar; + +SET SESSION example_double_thdvar = 500; +SELECT @@SESSION.example_double_thdvar; + +SET SESSION example_double_thdvar = 999.999999; +SELECT @@SESSION.example_double_thdvar; + +SET SESSION example_double_thdvar = 1000.51; +SELECT @@SESSION.example_double_thdvar; + +UNINSTALL PLUGIN example; + # # MDEV-4573 UNINSTALL PLUGIN misleading error message for non-dynamic plugins # |