diff --git a/tests/sequence_sharding_optimistic/data/db1.increment.sql b/tests/sequence_sharding_optimistic/data/db1.increment.sql index 4476682c10..dfea7e602b 100644 --- a/tests/sequence_sharding_optimistic/data/db1.increment.sql +++ b/tests/sequence_sharding_optimistic/data/db1.increment.sql @@ -27,24 +27,9 @@ alter table t2 drop column c1; insert into t1 (id, c2) values (100006, '120006'); insert into t2 (id, c2, c3) values (200006, '220006', 230006); -alter table t2 add column c1 varchar(20); --- at this point: --- t1(id, c2) --- t2(id, c1, c2, c3) -insert into t2 (id, c1, c2, c3) values (200007, '210007', '220007', 230007); -insert into t1 (id, c2) values (100007, '120007'); - -alter table t2 drop column c1; --- at this point: --- t1(id, c2) --- t2(id, c2, c3) -insert into t1 (id, c2) values (100008, '120008'); -insert into t2 (id, c2, c3) values (200008, '220008', 230008); - alter table t1 add column c3 int; -- at this point: -- t1(id, c2, c3) -- t2(id, c2, c3) -insert into t2 (id, c2, c3) values (200009, '220009', 230009); -insert into t1 (id, c2, c3) values (100009, '120009', 130009); - +insert into t2 (id, c2, c3) values (200007, '220007', 230007); +insert into t1 (id, c2, c3) values (100007, '120007', 130007); diff --git a/tests/sequence_sharding_optimistic/data/db1.increment2.sql b/tests/sequence_sharding_optimistic/data/db1.increment2.sql index f4d881f3c9..f289b3185d 100644 --- a/tests/sequence_sharding_optimistic/data/db1.increment2.sql +++ b/tests/sequence_sharding_optimistic/data/db1.increment2.sql @@ -1,8 +1,16 @@ use `sharding_seq_opt`; +alter table t2 add column c1 varchar(20); +-- at this point: +-- t1(id, c2, c3) +-- t2(id, c1, c2, c3) +insert into t2 (id, c1, c2, c3) values (200008, '210008', '220008', 230008); +insert into t1 (id, c2, c3) values (100008, '120008', 130008); + +alter table t2 drop column c1; -- at this point: -- t1(id, c2, c3) -- t2(id, c2, c3) -insert into t1 (id, c2, c3) values (100010, '120010', 130010); -insert into t2 (id, c2, c3) values (200010, '220010', 230010); +insert into t1 (id, c2, c3) values (100009, '120009', 130009); +insert into t2 (id, c2, c3) values (200009, '220009', 230009); diff --git a/tests/shardddl1/run.sh b/tests/shardddl1/run.sh index 27aa38b38a..a2f7af1dc5 100644 --- a/tests/shardddl1/run.sh +++ b/tests/shardddl1/run.sh @@ -577,8 +577,7 @@ function DM_RENAME_COLUMN_OPTIMISTIC_CASE() { "\"result\": true" 2 run_dm_ctl $WORK_DIR "127.0.0.1:$MASTER_PORT" \ - "resume-task test -s mysql-replica-02" \ - "\"result\": true" 2 + "resume-task test -s mysql-replica-02" # source2.table2's ddl fails # Unknown column 'a' in 'tb2' diff --git a/tests/shardddl3/run.sh b/tests/shardddl3/run.sh index 5975a83b5f..af55e6a59c 100644 --- a/tests/shardddl3/run.sh +++ b/tests/shardddl3/run.sh @@ -1083,9 +1083,9 @@ function DM_DropAddColumn() { do echo "run DM_DropAddColumn case #${i}" run_case DropAddColumn "double-source-optimistic" \ - "run_sql_source1 \"create table ${shardddl1}.${tb1} (a int primary key, b int, c int);\"; \ - run_sql_source2 \"create table ${shardddl1}.${tb1} (a int primary key, b int, c int);\"" \ - "clean_table" "optimistic" "$i" + "run_sql_source1 \"create table ${shardddl1}.${tb1} (a int primary key, b int, c int);\"; \ + run_sql_source2 \"create table ${shardddl1}.${tb1} (a int primary key, b int, c int);\"" \ + "clean_table" "optimistic" "$i" done }