From 3b50cd2492e136cc930569455b43be9476b56359 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marko=20M=C3=A4kel=C3=A4?= Date: Fri, 4 May 2018 14:42:53 +0300 Subject: [PATCH] Make a test independent of the build options The number of records in INFORMATION_SCHEMA.COLUMNS depends on the build options, and could easily change when features are added. We are not interested in the number of rows returned. The test was originally added because of problem 15 reported in MDEV-13900 (testing for MDEV-11369 instant ADD COLUMN). The issue was an assertion failure ut_ad(!rec_is_default_row(rec, index)) in lock_clust_rec_cons_read_sees(), because the 'default row' record was not being properly ignored by the b-tree cursor. --- mysql-test/suite/innodb/r/instant_alter_debug.result | 6 +++--- mysql-test/suite/innodb/t/instant_alter_debug.test | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/mysql-test/suite/innodb/r/instant_alter_debug.result b/mysql-test/suite/innodb/r/instant_alter_debug.result index bb7c414e9ef..5f2a10f82a9 100644 --- a/mysql-test/suite/innodb/r/instant_alter_debug.result +++ b/mysql-test/suite/innodb/r/instant_alter_debug.result @@ -32,10 +32,10 @@ pk f CREATE TABLE t4 (pk INT PRIMARY KEY) ENGINE=InnoDB; INSERT INTO t4 VALUES (0); ALTER TABLE t4 ADD COLUMN b INT; -SELECT COUNT(*) FROM INFORMATION_SCHEMA.COLUMNS +SELECT COUNT(*)>0 FROM INFORMATION_SCHEMA.COLUMNS LEFT JOIN t4 ON (NUMERIC_SCALE = pk); -COUNT(*) -953 +COUNT(*)>0 +1 SET DEBUG_SYNC='innodb_inplace_alter_table_enter SIGNAL enter WAIT_FOR delete'; ALTER TABLE t4 ADD COLUMN c INT; connect dml,localhost,root,,; diff --git a/mysql-test/suite/innodb/t/instant_alter_debug.test b/mysql-test/suite/innodb/t/instant_alter_debug.test index bcf69628010..b4b64392245 100644 --- a/mysql-test/suite/innodb/t/instant_alter_debug.test +++ b/mysql-test/suite/innodb/t/instant_alter_debug.test @@ -38,7 +38,7 @@ SELECT * FROM t3; CREATE TABLE t4 (pk INT PRIMARY KEY) ENGINE=InnoDB; INSERT INTO t4 VALUES (0); ALTER TABLE t4 ADD COLUMN b INT; -SELECT COUNT(*) FROM INFORMATION_SCHEMA.COLUMNS +SELECT COUNT(*)>0 FROM INFORMATION_SCHEMA.COLUMNS LEFT JOIN t4 ON (NUMERIC_SCALE = pk); SET DEBUG_SYNC='innodb_inplace_alter_table_enter SIGNAL enter WAIT_FOR delete'; --send