From f283d2373ccfc0274e2452130d0fa279f59c0613 Mon Sep 17 00:00:00 2001 From: amyangfei Date: Fri, 2 Nov 2018 18:31:28 +0800 Subject: [PATCH] test: fix comment align to satisfy gofmt (#402) gofmt regression strategy changes in different go release version. In this case, go version under 1.11.x will re-format one line code while go version 1.11.x does nothing. Similar issue occurs in https://github.com/golang/go/issues/25161. So we change some comment position --- syncer/ast_test.go | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/syncer/ast_test.go b/syncer/ast_test.go index 1428b56162..99bba93fa0 100644 --- a/syncer/ast_test.go +++ b/syncer/ast_test.go @@ -83,8 +83,11 @@ func (s *testSyncerSuite) testFailedCases(c *C) { // cases parse failed and should be supported in the near future // {"ALTER TABLE bar ENABLE KEYS, DISABLE KEYS", []string{"ALTER TABLE `bar` ENABLE KEYS", "ALTER TABLE `bar` DISABLE KEYS"}, false}, - {"alter table bar ORDER BY id1, id2", []string{"alter table bar ORDER BY id1, id2"}, true}, // tidb not support ORDER BY. - {"alter table bar add index (`name`), add FOREIGN KEY (product_category, product_id) REFERENCES product(category, id) ON UPDATE CASCADE ON DELETE RESTRICT", []string{"alter table bar add index (`name`), add FOREIGN KEY (product_category, product_id) REFERENCES product(category, id) ON UPDATE CASCADE ON DELETE RESTRICT"}, true}, // tidb not support ON UPDATE CASCADE ON DELETE RESTRICT + + // tidb not support ORDER BY. + {"alter table bar ORDER BY id1, id2", []string{"alter table bar ORDER BY id1, id2"}, true}, + // tidb not support ON UPDATE CASCADE ON DELETE RESTRICT + {"alter table bar add index (`name`), add FOREIGN KEY (product_category, product_id) REFERENCES product(category, id) ON UPDATE CASCADE ON DELETE RESTRICT", []string{"alter table bar add index (`name`), add FOREIGN KEY (product_category, product_id) REFERENCES product(category, id) ON UPDATE CASCADE ON DELETE RESTRICT"}, true}, } s.run(c, tests)