From 2842c369851a8afc2a944ce6f4f60fa052f20969 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marko=20M=C3=A4kel=C3=A4?= Date: Thu, 5 Sep 2019 16:37:32 +0300 Subject: [PATCH] MDEV-20425: Enable a test for debug builds --- mysql-test/suite/innodb/r/trx_id_future.result | 3 +++ mysql-test/suite/innodb/t/trx_id_future.test | 7 ++++++- 2 files changed, 9 insertions(+), 1 deletion(-) diff --git a/mysql-test/suite/innodb/r/trx_id_future.result b/mysql-test/suite/innodb/r/trx_id_future.result index 17b76b4b1c1..1ddc0e64f8b 100644 --- a/mysql-test/suite/innodb/r/trx_id_future.result +++ b/mysql-test/suite/innodb/r/trx_id_future.result @@ -8,8 +8,11 @@ INSERT INTO t1 VALUES(1); InnoDB 0 transactions not purged NOT FOUND /\[Warning\] InnoDB: A transaction id in a record of table `test`\.`t1` is newer than the system-wide maximum/ in mysqld.1.err call mtr.add_suppression("\\[Warning\\] InnoDB: A transaction id in a record of table `test`\\.`t1` is newer than the system-wide maximum"); +SET @save_count = @@max_error_count; +SET max_error_count = 1; SELECT * FROM t1; a Warnings: Warning 1642 InnoDB: Transaction id in a record of table `test`.`t1` is newer than system-wide maximum. +SET max_error_count = @save_count; DROP TABLE t1; diff --git a/mysql-test/suite/innodb/t/trx_id_future.test b/mysql-test/suite/innodb/t/trx_id_future.test index 5ae0d0093ba..e65dc537fd8 100644 --- a/mysql-test/suite/innodb/t/trx_id_future.test +++ b/mysql-test/suite/innodb/t/trx_id_future.test @@ -3,7 +3,6 @@ --echo # IN THE FUTURE --echo # ---source include/not_debug.inc --source include/have_innodb.inc --source include/not_embedded.inc @@ -47,6 +46,8 @@ syswrite(FILE, $page, $ps)==$ps || die "Unable to write $file\n"; close(FILE) || die "Unable to close $file"; EOF +# Debug assertions would fail due to the injected corruption. +--let $restart_parameters= --loose-skip-debug-assert --source include/start_mysqld.inc let SEARCH_FILE= $MYSQLTEST_VARDIR/log/mysqld.1.err; @@ -55,5 +56,9 @@ let SEARCH_PATTERN= \[Warning\] InnoDB: A transaction id in a record of table `t call mtr.add_suppression("\\[Warning\\] InnoDB: A transaction id in a record of table `test`\\.`t1` is newer than the system-wide maximum"); +# A debug assertion would cause a duplicated message to be output. +SET @save_count = @@max_error_count; +SET max_error_count = 1; SELECT * FROM t1; +SET max_error_count = @save_count; DROP TABLE t1;