From d40f7056ae4075339b1adefdadc990fcf4e5f4d0 Mon Sep 17 00:00:00 2001 From: unknown Date: Tue, 24 Jan 2006 08:30:54 +0100 Subject: Make it possible to run mysql-test-run.pl with default test suite in different vardir. mysql-test/include/have_outfile.inc: Use MYSQLTEST_VARDIR mysql-test/include/test_outfile.inc: Use MYSQLTEST_VARDIR mysql-test/mysql-test-run.pl: Create variable $MYSQLTEST_VARDIR that points to the vardir Don't create a symlink from var/ to the physical vardir if it's somewhere else Setup a symlink(or copy dir on windows) for std_data so it is available in the physical vardir Use "../tmp" as slave-load-tmpdir, since the server is started in var/master-data and slave in var/slave-data they will both find the dumps in "../tmp" mysql-test/mysql-test-run.sh: Export MYSQLTEST_VARDIR, always pointing at mysql-test/var mysql-test/r/backup.result: Use MYSQLTEST_VARDIR mysql-test/r/blackhole.result: Use "../std_data_ln" to find std_data files mysql-test/r/loaddata.result: Use "../std_data_ln" to find std_data files mysql-test/r/mysqlbinlog.result: Use "../std_data_ln" to find std_data files mysql-test/r/mysqltest.result: Use MYSQLTEST_VARDIR mysql-test/r/outfile.result: Use MYSQLTEST_VARDIR mysql-test/r/query_cache.result: Add missing drop function mysql-test/r/rpl000001.result: Use "../std_data_ln" to find std_data files mysql-test/r/rpl000004.result: Use "../std_data_ln" to find std_data files mysql-test/r/rpl_innodb.result: Use "../std_data_ln" to find std_data files mysql-test/r/rpl_loaddata.result: Use "../std_data_ln" to find std_data files mysql-test/r/rpl_loaddata_rule_m.result: Use "../std_data_ln" to find std_data files mysql-test/r/rpl_loaddata_rule_s.result: Use "../std_data_ln" to find std_data files mysql-test/r/rpl_loaddatalocal.result: Use MYSQLTEST_VARDIR mysql-test/r/rpl_log.result: Use "../std_data_ln" to find std_data files mysql-test/r/rpl_misc_functions.result: Use MYSQLTEST_VARDIR mysql-test/r/rpl_replicate_do.result: Use "../std_data_ln" to find std_data files mysql-test/r/rpl_rewrite_db.result: Use "../std_data_ln" to find std_data files mysql-test/r/rpl_timezone.result: Use "../std_data_ln" to find std_data files mysql-test/r/symlink.result: Use MYSQLTEST_VARDIR mysql-test/r/trigger.result: Use "../std_data_ln" to find std_data files mysql-test/r/view.result: Use "../std_data_ln" to find std_data files mysql-test/r/warnings.result: Use "../std_data_ln" to find std_data files mysql-test/t/backup-master.sh: Use MYSQLTEST_VARDIR mysql-test/t/backup.test: Use MYSQLTEST_VARDIR mysql-test/t/blackhole.test: Use "../std_data_ln" to find std_data files mysql-test/t/ctype_ucs_binlog.test: Use MYSQLTEST_VARDIR mysql-test/t/im_daemon_life_cycle-im.opt: Use MYSQLTEST_VARDIR mysql-test/t/im_options_set.imtest: Use MYSQLTEST_VARDIR mysql-test/t/im_options_unset.imtest: Use MYSQLTEST_VARDIR mysql-test/t/loaddata.test: Use "../std_data_ln" to find std_data files mysql-test/t/myisam.test: Use MYSQLTEST_VARDIR mysql-test/t/mysqlbinlog.test: Use "../std_data_ln" to find std_data files mysql-test/t/mysqlbinlog2.test: Use MYSQLTEST_VARDIR mysql-test/t/mysqldump.test: Use MYSQLTEST_VARDIR mysql-test/t/mysqltest.test: Use MYSQLTEST_VARDIR mysql-test/t/ndb_autodiscover.test: Use MYSQLTEST_VARDIR mysql-test/t/outfile.test: Use MYSQLTEST_VARDIR mysql-test/t/query_cache.test: Add missing drop function mysql-test/t/repair.test: Use MYSQLTEST_VARDIR mysql-test/t/rpl000001.test: Use "../std_data_ln" to find std_data files mysql-test/t/rpl000004.test: Use "../std_data_ln" to find std_data files mysql-test/t/rpl000009.test: Use MYSQLTEST_VARDIR mysql-test/t/rpl000015-slave.sh: Use MYSQLTEST_VARDIR mysql-test/t/rpl000017-slave.sh: Use MYSQLTEST_VARDIR mysql-test/t/rpl_EE_error.test: Use MYSQLTEST_VARDIR mysql-test/t/rpl_charset.test: Use MYSQLTEST_VARDIR mysql-test/t/rpl_drop_db.test: Use MYSQLTEST_VARDIR mysql-test/t/rpl_flush_log_loop-master.opt: Use MYSQLTEST_VARDIR mysql-test/t/rpl_flush_log_loop-master.sh: Use MYSQLTEST_VARDIR mysql-test/t/rpl_flush_log_loop-slave.opt: Use MYSQLTEST_VARDIR mysql-test/t/rpl_flush_log_loop-slave.sh: Use MYSQLTEST_VARDIR mysql-test/t/rpl_innodb.test: Use "../std_data_ln" to find std_data files mysql-test/t/rpl_loaddata.test: Use "../std_data_ln" to find std_data files mysql-test/t/rpl_loaddata_rule_m.test: Use "../std_data_ln" to find std_data files mysql-test/t/rpl_loaddata_rule_s.test: Use "../std_data_ln" to find std_data files mysql-test/t/rpl_loaddatalocal.test: Use MYSQLTEST_VARDIR mysql-test/t/rpl_log.test: Use "../std_data_ln" to find std_data files mysql-test/t/rpl_misc_functions-slave.sh: Use MYSQLTEST_VARDIR mysql-test/t/rpl_misc_functions.test: Use MYSQLTEST_VARDIR mysql-test/t/rpl_replicate_do.test: Use "../std_data_ln" to find std_data files mysql-test/t/rpl_rewrite_db.test: Use "../std_data_ln" to find std_data files mysql-test/t/rpl_rotate_logs-slave.sh: Use MYSQLTEST_VARDIR mysql-test/t/rpl_rotate_logs.test: Use MYSQLTEST_VARDIR mysql-test/t/rpl_timezone.test: Use MYSQLTEST_VARDIR mysql-test/t/show_check.test: Use MYSQLTEST_VARDIR mysql-test/t/sp-destruct.test: Use MYSQLTEST_VARDIR mysql-test/t/symlink.test: Use MYSQLTEST_VARDIR mysql-test/t/temp_table-master.opt: Use MYSQLTEST_VARDIR mysql-test/t/trigger-compat.test: Use MYSQLTEST_VARDIR mysql-test/t/trigger-grant.test: Use MYSQLTEST_VARDIR mysql-test/t/trigger.test: Use "../std_data_ln" to find std_data files mysql-test/t/type_varchar.test: Use MYSQLTEST_VARDIR mysql-test/t/user_var-binlog.test: Use MYSQLTEST_VARDIR mysql-test/t/view.test: Use "../std_data_ln" to find std_data files mysql-test/t/warnings.test: Use "../std_data_ln" to find std_data files mysql-test/include/sourced.inc: New BitKeeper file ``mysql-test/include/sourced.inc'' mysql-test/include/sourced1.inc: New BitKeeper file ``mysql-test/include/sourced1.inc'' --- mysql-test/t/mysqldump.test | 44 ++++++++++++++++++++++---------------------- 1 file changed, 22 insertions(+), 22 deletions(-) (limited to 'mysql-test/t/mysqldump.test') diff --git a/mysql-test/t/mysqldump.test b/mysql-test/t/mysqldump.test index e54bf6386c5..0d2d46a2819 100644 --- a/mysql-test/t/mysqldump.test +++ b/mysql-test/t/mysqldump.test @@ -125,14 +125,14 @@ drop table t1; create table t1(a int); insert into t1 values (1),(2),(3); ---exec $MYSQL_DUMP --skip-comments --tab=$MYSQL_TEST_DIR/var/tmp/ test ---exec cat $MYSQL_TEST_DIR/var/tmp/t1.sql ---exec cat $MYSQL_TEST_DIR/var/tmp/t1.txt ---exec rm $MYSQL_TEST_DIR/var/tmp/t1.sql ---exec rm $MYSQL_TEST_DIR/var/tmp/t1.txt ---exec $MYSQL_DUMP --tab=$MYSQL_TEST_DIR/var/tmp/ test ---exec rm $MYSQL_TEST_DIR/var/tmp/t1.sql ---exec rm $MYSQL_TEST_DIR/var/tmp/t1.txt +--exec $MYSQL_DUMP --skip-comments --tab=$MYSQLTEST_VARDIR/tmp/ test +--exec cat $MYSQLTEST_VARDIR/tmp/t1.sql +--exec cat $MYSQLTEST_VARDIR/tmp/t1.txt +--exec rm $MYSQLTEST_VARDIR/tmp/t1.sql +--exec rm $MYSQLTEST_VARDIR/tmp/t1.txt +--exec $MYSQL_DUMP --tab=$MYSQLTEST_VARDIR/tmp/ test +--exec rm $MYSQLTEST_VARDIR/tmp/t1.sql +--exec rm $MYSQLTEST_VARDIR/tmp/t1.txt drop table t1; # @@ -587,7 +587,7 @@ create view v1 as select * from t2; create view v2 as select * from t1; # dump tables and view from db2 ---exec $MYSQL_DUMP db2 > var/tmp/bug10713.sql +--exec $MYSQL_DUMP db2 > $MYSQLTEST_VARDIR/tmp/bug10713.sql # drop the db, tables and views drop table t1, t2; @@ -597,7 +597,7 @@ drop database db2; # create db1 and reload dump create database db1; use db1; ---exec $MYSQL db1 < var/tmp/bug10713.sql +--exec $MYSQL db1 < $MYSQLTEST_VARDIR/tmp/bug10713.sql # check that all tables and views could be created show tables; @@ -705,9 +705,9 @@ drop table t1, t2; create table t1 (a text character set utf8, b text character set latin1); insert t1 values (0x4F736E616272C3BC636B, 0x4BF66C6E); select * from t1; ---exec $MYSQL_DUMP --tab=$MYSQL_TEST_DIR/var/tmp/ test ---exec $MYSQL test < $MYSQL_TEST_DIR/var/tmp/t1.sql ---exec $MYSQL_IMPORT test $MYSQL_TEST_DIR/var/tmp/t1.txt +--exec $MYSQL_DUMP --tab=$MYSQLTEST_VARDIR/tmp/ test +--exec $MYSQL test < $MYSQLTEST_VARDIR/tmp/t1.sql +--exec $MYSQL_IMPORT test $MYSQLTEST_VARDIR/tmp/t1.txt select * from t1; drop table t1; @@ -817,9 +817,9 @@ update t1 set a = 4 where a=3; # Skip dumping triggers --exec $MYSQL_DUMP --skip-comments --databases --skip-triggers test # Dump and reload... ---exec $MYSQL_DUMP --skip-comments --databases test > var/tmp/mysqldump.sql +--exec $MYSQL_DUMP --skip-comments --databases test > $MYSQLTEST_VARDIR/tmp/mysqldump.sql drop table t1; ---exec $MYSQL test < var/tmp/mysqldump.sql +--exec $MYSQL test < $MYSQLTEST_VARDIR/tmp/mysqldump.sql # Check that tables have been reloaded show tables; --replace_column 6 # @@ -830,11 +830,11 @@ DROP TABLE t1, t2; # Bugs #9136, #12917: problems with --defaults-extra-file option # ---exec echo "[mysqltest1]" > $MYSQL_TEST_DIR/var/tmp/tmp.cnf ---exec echo "port=1234" >> $MYSQL_TEST_DIR/var/tmp/tmp.cnf ---exec $MYSQL_MY_PRINT_DEFAULTS -c $MYSQL_TEST_DIR/var/tmp/tmp.cnf mysqltest1 ---exec $MYSQL_MY_PRINT_DEFAULTS -e $MYSQL_TEST_DIR/var/tmp/tmp.cnf mysqltest1 mysqltest1 ---exec rm $MYSQL_TEST_DIR/var/tmp/tmp.cnf +--exec echo "[mysqltest1]" > $MYSQLTEST_VARDIR/tmp/tmp.cnf +--exec echo "port=1234" >> $MYSQLTEST_VARDIR/tmp/tmp.cnf +--exec $MYSQL_MY_PRINT_DEFAULTS -c $MYSQLTEST_VARDIR/tmp/tmp.cnf mysqltest1 +--exec $MYSQL_MY_PRINT_DEFAULTS -e $MYSQLTEST_VARDIR/tmp/tmp.cnf mysqltest1 mysqltest1 +--exec rm $MYSQLTEST_VARDIR/tmp/tmp.cnf # # Test of fix to BUG 12597 @@ -859,13 +859,13 @@ INSERT INTO `test1` VALUES (1); SELECT * FROM `test2`; # dump ---exec $MYSQL_DUMP --skip-comments --databases test > var/tmp/mysqldump.sql +--exec $MYSQL_DUMP --skip-comments --databases test > $MYSQLTEST_VARDIR/tmp/mysqldump.sql #DROP TRIGGER testref; #DROP TABLE test1; #DROP TABLE test2; # restore ---exec $MYSQL test < var/tmp/mysqldump.sql +--exec $MYSQL test < $MYSQLTEST_VARDIR/tmp/mysqldump.sql SHOW TRIGGERS; SELECT * FROM `test1`; SELECT * FROM `test2`; -- cgit v1.2.1