diff options
author | Mattias Jonsson <mattias.jonsson@oracle.com> | 2011-01-18 23:55:39 +0100 |
---|---|---|
committer | Mattias Jonsson <mattias.jonsson@oracle.com> | 2011-01-18 23:55:39 +0100 |
commit | d33fbe44ffed64c54203aece512a7c2c6a7abece (patch) | |
tree | 01a378502502166da8beb1131415a6ae2e0b2c23 /mysql-test/suite/parts/inc/partition_layout_check1.inc | |
parent | 06e21d5cd9aa70dae4a2a8779f87cc378796d466 (diff) | |
download | mariadb-git-d33fbe44ffed64c54203aece512a7c2c6a7abece.tar.gz |
Bug#59418: parts suite have several failures with --embedded-server
The test were using external tools not available for embedded.
Fixed by rewriting the test to not rely on external tools like the mysql-client
Also fixed some non portable --exec commands and replaced #p# to #P# to pass
on windows.
Diffstat (limited to 'mysql-test/suite/parts/inc/partition_layout_check1.inc')
-rw-r--r-- | mysql-test/suite/parts/inc/partition_layout_check1.inc | 13 |
1 files changed, 5 insertions, 8 deletions
diff --git a/mysql-test/suite/parts/inc/partition_layout_check1.inc b/mysql-test/suite/parts/inc/partition_layout_check1.inc index bca41b6f9c7..66a93d5d8d7 100644 --- a/mysql-test/suite/parts/inc/partition_layout_check1.inc +++ b/mysql-test/suite/parts/inc/partition_layout_check1.inc @@ -29,14 +29,10 @@ DELETE FROM t0_definition; let $MYSQLD_DATADIR= `select LEFT(@@datadir, LENGTH(@@datadir)-1)`; #echo MYSQLD_DATADIR: $MYSQLD_DATADIR; -# Dump the current definition of the table t1 to tmp1 -# This complicated method - let another mysqltest collect the output - is used -# because of two reasons +# Save the current definition of the table t1 # - SHOW CREATE TABLE t1 is at least currently most probably more reliable than # the corresponding SELECT on the INFORMATION_SCHEMA -# - SHOW CREATE TABLE .. cannot write its out put into a file like SELECT -let $show_file= $MYSQLD_DATADIR/test/tmp1; ---exec echo "SHOW CREATE TABLE t1; exit; " | $MYSQL_TEST > $show_file 2>&1 +let $show_create= `SHOW CREATE TABLE t1`; if ($do_file_tests) { # List the files belonging to the table t1 @@ -57,12 +53,13 @@ if (!$do_file_tests) # Insert the current definition of the table t1 into t0_definition eval INSERT INTO t0_definition SET state = 'old', - create_command = load_file('$show_file'), + create_command = "$show_create", file_list = @aux; # Print the create table statement into the protocol +# Added the concat to avoid changing the result files --replace_result $MYSQLTEST_VARDIR MYSQLTEST_VARDIR '\r' '' -SELECT create_command FROM t0_definition WHERE state = 'old'; +SELECT concat('SHOW CREATE TABLE t1;\nTable\tCreate Table\n',create_command,'\n') as `create_command` FROM t0_definition WHERE state = 'old'; if ($do_file_tests) { # We stored the list of files, therefore printing the content makes sense |