summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMarko Mäkelä <marko.makela@mariadb.com>2020-01-24 12:59:56 +0200
committerMarko Mäkelä <marko.makela@mariadb.com>2020-01-24 12:59:56 +0200
commit6af00b2cc620a96372541447cca7134f2d051b19 (patch)
tree2a23365a55bc57aab154fc5f9a050d23e6d97276
parent34dafb7e3a857b368323c7d1cd6966188cc1c977 (diff)
downloadmariadb-git-6af00b2cc620a96372541447cca7134f2d051b19.tar.gz
MDEV-16678: Ignore #sql-ib tables in --suite=parts
We missed these in commit 89633995e4962a7ad4a241cdf62ee637990d6787 and commit ccd87d34a404fba3431dd7ef09f8a98a5874040f.
-rw-r--r--mysql-test/suite/parts/r/partition_basic_symlink_innodb.result6
-rw-r--r--mysql-test/suite/parts/t/partition_basic_symlink_innodb.test56
-rw-r--r--mysql-test/suite/parts/t/partition_debug_sync_innodb.test6
3 files changed, 42 insertions, 26 deletions
diff --git a/mysql-test/suite/parts/r/partition_basic_symlink_innodb.result b/mysql-test/suite/parts/r/partition_basic_symlink_innodb.result
index 65a5edba254..33dcad91ff6 100644
--- a/mysql-test/suite/parts/r/partition_basic_symlink_innodb.result
+++ b/mysql-test/suite/parts/r/partition_basic_symlink_innodb.result
@@ -1,7 +1,8 @@
#
# Verify that the DATA/INDEX DIR is stored and used if ALTER to MyISAM.
#
-DROP TABLE IF EXISTS t1;
+SET @file_per_table= @@GLOBAL.innodb_file_per_table;
+SET @strict_mode= @@SESSION.innodb_strict_mode;
SET SESSION innodb_strict_mode = ON;
#
# InnoDB only supports DATA DIRECTORY with innodb_file_per_table=ON
@@ -88,7 +89,6 @@ t1 CREATE TABLE `t1` (
(PARTITION `p0` DATA DIRECTORY = 'MYSQLTEST_VARDIR/mysql-test-data-dir' ENGINE = MyISAM,
PARTITION `p1` DATA DIRECTORY = 'MYSQLTEST_VARDIR/mysql-test-data-dir' ENGINE = MyISAM)
# Verifying .frm, .par and MyISAM files (.MYD, MYI)
----- MYSQLD_DATADIR/test
db.opt
t1#P#p0.MYD
t1#P#p0.MYI
@@ -325,3 +325,5 @@ DROP TABLE t1, t2;
#
# Cleanup
#
+SET GLOBAL innodb_file_per_table=@file_per_table;
+SET SESSION innodb_strict_mode=@strict_mode;
diff --git a/mysql-test/suite/parts/t/partition_basic_symlink_innodb.test b/mysql-test/suite/parts/t/partition_basic_symlink_innodb.test
index 31448c7a9fe..e6b2f4300cc 100644
--- a/mysql-test/suite/parts/t/partition_basic_symlink_innodb.test
+++ b/mysql-test/suite/parts/t/partition_basic_symlink_innodb.test
@@ -39,17 +39,11 @@
# Does not work with --embedded
--source include/not_embedded.inc
---disable_query_log
let $MYSQLD_DATADIR= `select @@datadir`;
# These values can change during the test
-LET $innodb_file_per_table_orig=`select @@innodb_file_per_table`;
-LET $innodb_strict_mode_orig=`select @@session.innodb_strict_mode`;
---enable_query_log
-
---disable_warnings
-DROP TABLE IF EXISTS t1;
---enable_warnings
+SET @file_per_table= @@GLOBAL.innodb_file_per_table;
+SET @strict_mode= @@SESSION.innodb_strict_mode;
--mkdir $MYSQLTEST_VARDIR/mysql-test-data-dir
--mkdir $MYSQLTEST_VARDIR/mysql-test-idx-dir
@@ -99,9 +93,17 @@ SHOW WARNINGS;
--echo # Verifying .frm, .par, .isl & .ibd files
--echo ---- MYSQLD_DATADIR/test
---list_files $MYSQLD_DATADIR/test
+--let $regexp=/#sql-ib[0-9a-f]+\.ibd\n//
+--list_files_write_file $MYSQLD_DATADIR.files.txt $MYSQLD_DATADIR/test
+--replace_regex $regexp
+--cat_file $MYSQLD_DATADIR.files.txt
+--remove_file $MYSQLD_DATADIR.files.txt
--echo ---- MYSQLTEST_VARDIR/mysql-test-data-dir/test
---list_files $MYSQLTEST_VARDIR/mysql-test-data-dir/test
+--let $regexp=/#sql-ib[0-9a-f]+\.ibd\n//
+--list_files_write_file $MYSQLTEST_VARDIR/files.txt $MYSQLTEST_VARDIR/mysql-test-data-dir/test
+--replace_regex $regexp
+--cat_file $MYSQLTEST_VARDIR/files.txt
+--remove_file $MYSQLTEST_VARDIR/files.txt
--echo # The ibd tablespaces should not be directly under the DATA DIRECTORY
--echo ---- MYSQLTEST_VARDIR/mysql-test-data-dir
--list_files $MYSQLTEST_VARDIR/mysql-test-data-dir
@@ -120,8 +122,11 @@ ALTER TABLE t1 engine=MyISAM;
--replace_result $MYSQLTEST_VARDIR MYSQLTEST_VARDIR
SHOW CREATE TABLE t1;
--echo # Verifying .frm, .par and MyISAM files (.MYD, MYI)
---echo ---- MYSQLD_DATADIR/test
---list_files $MYSQLD_DATADIR/test
+--let $regexp=/#sql-ib[0-9a-f]+\.ibd\n//
+--list_files_write_file $MYSQLD_DATADIR.files.txt $MYSQLD_DATADIR/test
+--replace_regex $regexp
+--cat_file $MYSQLD_DATADIR.files.txt
+--remove_file $MYSQLD_DATADIR.files.txt
--echo ---- MYSQLTEST_VARDIR/mysql-test-data-dir
--list_files $MYSQLTEST_VARDIR/mysql-test-data-dir
--echo ---- MYSQLTEST_VARDIR/mysql-test-idx-dir
@@ -137,13 +142,21 @@ ALTER TABLE t1 engine=InnoDB;
SHOW CREATE TABLE t1;
--echo # Verifying .frm, .par, .isl and InnoDB .ibd files
--echo ---- MYSQLD_DATADIR/test
---list_files $MYSQLD_DATADIR/test
+--let $regexp=/#sql-ib[0-9a-f]+\.ibd\n//
+--list_files_write_file $MYSQLD_DATADIR.files.txt $MYSQLD_DATADIR/test
+--replace_regex $regexp
+--cat_file $MYSQLD_DATADIR.files.txt
+--remove_file $MYSQLD_DATADIR.files.txt
--echo ---- MYSQLTEST_VARDIR/mysql-test-data-dir
--list_files $MYSQLTEST_VARDIR/mysql-test-data-dir
--echo ---- MYSQLTEST_VARDIR/mysql-test-idx-dir
--list_files $MYSQLTEST_VARDIR/mysql-test-idx-dir
--echo ---- MYSQLTEST_VARDIR/mysql-test-data-dir/test
---list_files $MYSQLTEST_VARDIR/mysql-test-data-dir/test
+--let $regexp=/#sql-ib[0-9a-f]+\.ibd\n//
+--list_files_write_file $MYSQLTEST_VARDIR/files.txt $MYSQLTEST_VARDIR/mysql-test-data-dir/test
+--replace_regex $regexp
+--cat_file $MYSQLTEST_VARDIR/files.txt
+--remove_file $MYSQLTEST_VARDIR/files.txt
DROP TABLE t1;
@@ -175,7 +188,7 @@ eval CREATE TABLE t2
myval VARCHAR(10),
PRIMARY KEY (myid)
) ENGINE=INNODB DATA DIRECTORY = '$data_dir_path';
-
+
ALTER TABLE t1 EXCHANGE PARTITION p0001 WITH TABLE t2;
--replace_result $MYSQLTEST_VARDIR MYSQLTEST_VARDIR
@@ -205,7 +218,7 @@ eval CREATE TABLE t2
insert into t1 values (1, 'one');
insert into t2 values (2, 'two'), (3, 'threee'), (4, 'four');
-
+
select * from t1;
ALTER TABLE t1 EXCHANGE PARTITION p0001 WITH TABLE t2;
@@ -241,7 +254,7 @@ eval CREATE TABLE t2
insert into t1 values (1, 'one');
insert into t2 values (2, 'two'), (3, 'threee'), (4, 'four');
-
+
select * from t1;
ALTER TABLE t1 EXCHANGE PARTITION p0001 WITH TABLE t2;
@@ -277,7 +290,7 @@ eval CREATE TABLE t2
insert into t1 values (1, 'one');
insert into t2 values (2, 'two'), (3, 'threee'), (4, 'four');
-
+
select * from t1;
ALTER TABLE t1 EXCHANGE PARTITION p0001 WITH TABLE t2;
@@ -296,8 +309,5 @@ DROP TABLE t1, t2;
--rmdir $MYSQLTEST_VARDIR/mysql-test-data-dir
--rmdir $MYSQLTEST_VARDIR/mysql-test-idx-dir
---disable_query_log
-EVAL SET GLOBAL innodb_file_per_table=$innodb_file_per_table_orig;
-EVAL SET SESSION innodb_strict_mode=$innodb_strict_mode_orig;
---enable_query_log
-
+SET GLOBAL innodb_file_per_table=@file_per_table;
+SET SESSION innodb_strict_mode=@strict_mode;
diff --git a/mysql-test/suite/parts/t/partition_debug_sync_innodb.test b/mysql-test/suite/parts/t/partition_debug_sync_innodb.test
index d73333c3b8d..61eb48faa11 100644
--- a/mysql-test/suite/parts/t/partition_debug_sync_innodb.test
+++ b/mysql-test/suite/parts/t/partition_debug_sync_innodb.test
@@ -52,7 +52,11 @@ insert into t1 values (1), (11), (21), (33);
SELECT * FROM t1;
SHOW CREATE TABLE t1;
--replace_result #p# #P# #sp# #SP#
---list_files $MYSQLD_DATADIR/test
+--let $regexp=/#sql-ib[0-9a-f]+\.ibd\n//
+--list_files_write_file $MYSQLD_DATADIR.files.txt $MYSQLD_DATADIR/test
+--replace_regex $regexp
+--cat_file $MYSQLD_DATADIR.files.txt
+--remove_file $MYSQLD_DATADIR.files.txt
SET DEBUG_SYNC='before_open_in_get_all_tables SIGNAL parked WAIT_FOR open';
SET DEBUG_SYNC='partition_open_error SIGNAL alter WAIT_FOR finish';