test: don't hardcode the mapping of the column
This commit is contained in:
parent
701ebcb111
commit
bde3ea6ff7
|
@ -276,10 +276,10 @@ func TestGetColumnsComment(t *testing.T) {
|
||||||
var hasComment, noComment string
|
var hasComment, noComment string
|
||||||
for _, table := range tables {
|
for _, table := range tables {
|
||||||
if table.Name == tableName {
|
if table.Name == tableName {
|
||||||
col := table.GetColumn("has_comment")
|
col := table.GetColumn(testEngine.GetColumnMapper().Obj2Table("HasComment"))
|
||||||
assert.NotNil(t, col)
|
assert.NotNil(t, col)
|
||||||
hasComment = col.Comment
|
hasComment = col.Comment
|
||||||
col2 := table.GetColumn("no_comment")
|
col2 := table.GetColumn(testEngine.GetColumnMapper().Obj2Table("NoComment"))
|
||||||
assert.NotNil(t, col2)
|
assert.NotNil(t, col2)
|
||||||
noComment = col2.Comment
|
noComment = col2.Comment
|
||||||
break
|
break
|
||||||
|
|
Loading…
Reference in New Issue