summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMarko Mäkelä <marko.makela@mariadb.com>2017-09-08 09:38:42 +0300
committerMarko Mäkelä <marko.makela@mariadb.com>2017-09-08 09:38:42 +0300
commit95f602698aeb246361e5e35a1dbf26f9c829bde5 (patch)
treeaaa45199c0b9f4da3c94b375dbc72e601fdefe1e
parent18e17f134c38c61ba649ae742ee07bdffeed8dea (diff)
downloadmariadb-git-95f602698aeb246361e5e35a1dbf26f9c829bde5.tar.gz
Make a test more robust
The redo log is divided into 512-byte blocks. Sometimes, some of the strings end up at a block boundary and will not be found. Look for only one match.
-rw-r--r--mysql-test/suite/encryption/r/innodb_encrypt_log.result2
-rw-r--r--mysql-test/suite/encryption/t/innodb_encrypt_log.test2
2 files changed, 2 insertions, 2 deletions
diff --git a/mysql-test/suite/encryption/r/innodb_encrypt_log.result b/mysql-test/suite/encryption/r/innodb_encrypt_log.result
index 2ed3e50a590..0663890c685 100644
--- a/mysql-test/suite/encryption/r/innodb_encrypt_log.result
+++ b/mysql-test/suite/encryption/r/innodb_encrypt_log.result
@@ -50,7 +50,7 @@ INSERT INTO t0 VALUES(NULL, 5, 5, 'public', 'gossip');
# ib_logfile0 expecting NOT FOUND
NOT FOUND /private|secret|sacr(ed|ament)|success|story|secur(e|ity)/ in ib_logfile0
# ib_logfile0 expecting FOUND
-FOUND 3 /public|gossip/ in ib_logfile0
+FOUND 1 /(public|gossip).*/ in ib_logfile0
# ibdata1 expecting NOT FOUND
NOT FOUND /private|secret|sacr(ed|ament)|success|story|secur(e|ity)|public|gossip/ in ibdata1
# t0.ibd expecting NOT FOUND
diff --git a/mysql-test/suite/encryption/t/innodb_encrypt_log.test b/mysql-test/suite/encryption/t/innodb_encrypt_log.test
index 4bc556ee1d2..4b3d92e876c 100644
--- a/mysql-test/suite/encryption/t/innodb_encrypt_log.test
+++ b/mysql-test/suite/encryption/t/innodb_encrypt_log.test
@@ -75,7 +75,7 @@ INSERT INTO t0 VALUES(NULL, 5, 5, 'public', 'gossip');
--echo # ib_logfile0 expecting NOT FOUND
-- let SEARCH_FILE=$MYSQLD_DATADIR/ib_logfile0
-- source include/search_pattern_in_file.inc
---let SEARCH_PATTERN=public|gossip
+--let SEARCH_PATTERN=(public|gossip).*
--echo # ib_logfile0 expecting FOUND
-- let SEARCH_FILE=$MYSQLD_DATADIR/ib_logfile0
-- source include/search_pattern_in_file.inc