summaryrefslogtreecommitdiff
path: root/mysql-test/t/mysqldump.test
diff options
context:
space:
mode:
authorAkhila Maddukuri <akhila.x.maddukuri@oracle.com>2012-12-07 18:26:02 +0530
committerAkhila Maddukuri <akhila.x.maddukuri@oracle.com>2012-12-07 18:26:02 +0530
commit459bee9cad314ef713d9a640782b05a3c9356b04 (patch)
treee3cdb84aecc4546e1f5cba653b208fd8e99ac352 /mysql-test/t/mysqldump.test
parent54324117b302adae5c54832fa87139f68223995b (diff)
downloadmariadb-git-459bee9cad314ef713d9a640782b05a3c9356b04.tar.gz
Bug #15930494 MYSQLDUMP TEST SOMETIMES FAILS DUE TO MIXING STDOUT AND
STDERR Fix: Added a destination file to mysqldump.
Diffstat (limited to 'mysql-test/t/mysqldump.test')
-rw-r--r--mysql-test/t/mysqldump.test11
1 files changed, 9 insertions, 2 deletions
diff --git a/mysql-test/t/mysqldump.test b/mysql-test/t/mysqldump.test
index 6d136c0f00a..b6af97c6f41 100644
--- a/mysql-test/t/mysqldump.test
+++ b/mysql-test/t/mysqldump.test
@@ -2347,11 +2347,17 @@ INSERT INTO b12809202_db.t2 VALUES (1), (2), (3);
--echo # Note : In the following dump the transaction
--echo # should start only after the logs are
--echo # flushed, as 'flush logs' causes implicit
---echo # commit starting 5.5.
+--echo # commit starting 5.5.Also, as stderr is
+--echo # unbuffered, it is redirected to a different
+--echo # file to avoid diffs due to bad stdout/stderr
+--echo # order in the output.
--echo
--echo #### Dump starts here ####
--replace_regex /-- Server version.*// /-- MySQL dump .*// /-- Dump completed on .*/-- Dump completed/
---exec $MYSQL_DUMP --verbose --single-transaction --flush-log b12809202_db 2>&1
+--exec $MYSQL_DUMP --verbose --single-transaction --flush-log b12809202_db 2>$MYSQLTEST_VARDIR/tmp/b12809202_stderr.sql
+--echo
+--echo ## stderr ##
+--cat_file $MYSQLTEST_VARDIR/tmp/b12809202_stderr.sql
--echo
--echo #### Dump ends here ####
@@ -2359,6 +2365,7 @@ INSERT INTO b12809202_db.t2 VALUES (1), (2), (3);
DROP TABLE b12809202_db.t1;
DROP TABLE b12809202_db.t2;
DROP DATABASE b12809202_db;
+--remove_file $MYSQLTEST_VARDIR/tmp/b12809202_stderr.sql
--echo #
--echo # Delete all existing binary logs.