[Commits] f1a69879f24: MDEV-17403: Test failure on galera.galera_enum
revision-id: f1a69879f2498deccc16c317d78d9f91ad7acc63 (mariadb-10.1.35-82-gf1a69879f24) parent(s): f517d8c7425257b6b9fe81c82c489e1e5619898d author: Jan Lindström committer: Jan Lindström timestamp: 2018-10-10 09:14:16 +0300 message: MDEV-17403: Test failure on galera.galera_enum Add wait on second node. --- mysql-test/suite/galera/r/galera_enum.result | 37 ++++++++++++++++------------ mysql-test/suite/galera/t/galera_enum.test | 18 +++++++++----- 2 files changed, 33 insertions(+), 22 deletions(-) diff --git a/mysql-test/suite/galera/r/galera_enum.result b/mysql-test/suite/galera/r/galera_enum.result index e853c5c9943..7b42aab264c 100644 --- a/mysql-test/suite/galera/r/galera_enum.result +++ b/mysql-test/suite/galera/r/galera_enum.result @@ -4,23 +4,23 @@ INSERT INTO t1 VALUES ('one'), ('two'); INSERT INTO t1 VALUES (0), (1), (2); Warnings: Warning 1265 Data truncated for column 'f1' at row 1 -SELECT COUNT(*) = 6 FROM t1; -COUNT(*) = 6 -1 -SELECT COUNT(*) = 2 FROM t1 where f1 = ''; -COUNT(*) = 2 -1 -SELECT COUNT(*) = 2 FROM t1 where f1 = 'one'; -COUNT(*) = 2 -1 +SELECT COUNT(*) FROM t1; +COUNT(*) +6 +SELECT COUNT(*) FROM t1 where f1 = ''; +COUNT(*) +2 +SELECT COUNT(*) FROM t1 where f1 = 'one'; +COUNT(*) +2 DROP TABLE t1; CREATE TABLE t1 (f1 ENUM('', 'one', 'two', 'three', 'four') PRIMARY KEY) ENGINE=InnoDB; INSERT INTO t1 VALUES (''), ('one'), ('two'); -SELECT COUNT(*) = 3 FROM t1; -COUNT(*) = 3 -1 -SELECT COUNT(*) = 1 FROM t1 WHERE f1 = ''; -COUNT(*) = 1 +SELECT COUNT(*) FROM t1; +COUNT(*) +3 +SELECT COUNT(*) FROM t1 WHERE f1 = ''; +COUNT(*) 1 SET AUTOCOMMIT=OFF; START TRANSACTION; @@ -31,7 +31,12 @@ UPDATE t1 SET f1 = 'four' where f1 = ''; COMMIT; COMMIT; ERROR 40001: Deadlock found when trying to get lock; try restarting transaction -SELECT COUNT(*) = 1 FROM t1 WHERE f1 = 'three'; -COUNT(*) = 1 +SELECT COUNT(*) FROM t1 WHERE f1 = 'three'; +COUNT(*) 1 +SELECT * FROM t1; +f1 +one +two +three DROP TABLE t1; diff --git a/mysql-test/suite/galera/t/galera_enum.test b/mysql-test/suite/galera/t/galera_enum.test index ff5332486aa..782180a3aa1 100644 --- a/mysql-test/suite/galera/t/galera_enum.test +++ b/mysql-test/suite/galera/t/galera_enum.test @@ -17,9 +17,12 @@ INSERT INTO t1 VALUES ('one'), ('two'); INSERT INTO t1 VALUES (0), (1), (2); --connection node_2 -SELECT COUNT(*) = 6 FROM t1; -SELECT COUNT(*) = 2 FROM t1 where f1 = ''; -SELECT COUNT(*) = 2 FROM t1 where f1 = 'one'; +--let $wait_condition = SELECT COUNT(*) = 1 FROM INFORMATION_SCHEMA.INNODB_SYS_TABLES WHERE NAME LIKE 'test/t1'; +--source include/wait_condition.inc + +SELECT COUNT(*) FROM t1; +SELECT COUNT(*) FROM t1 where f1 = ''; +SELECT COUNT(*) FROM t1 where f1 = 'one'; DROP TABLE t1; @@ -33,8 +36,10 @@ CREATE TABLE t1 (f1 ENUM('', 'one', 'two', 'three', 'four') PRIMARY KEY) ENGINE= INSERT INTO t1 VALUES (''), ('one'), ('two'); --connection node_2 -SELECT COUNT(*) = 3 FROM t1; -SELECT COUNT(*) = 1 FROM t1 WHERE f1 = ''; +--let $wait_condition = SELECT COUNT(*) = 1 FROM INFORMATION_SCHEMA.INNODB_SYS_TABLES WHERE NAME LIKE 'test/t1'; +--source include/wait_condition.inc +SELECT COUNT(*) FROM t1; +SELECT COUNT(*) FROM t1 WHERE f1 = ''; # Conflict @@ -57,6 +62,7 @@ COMMIT; --connection node_1 -SELECT COUNT(*) = 1 FROM t1 WHERE f1 = 'three'; +SELECT COUNT(*) FROM t1 WHERE f1 = 'three'; +SELECT * FROM t1; DROP TABLE t1;
participants (1)
-
jan