Skip to content

Commit

Permalink
test: use a less restrictive interface to allow vitess-tester to use …
Browse files Browse the repository at this point in the history
…these functions

Signed-off-by: Manan Gupta <manan@planetscale.com>
  • Loading branch information
GuptaManan100 committed Apr 17, 2024
1 parent 807524a commit 54e71e5
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions go/test/endtoend/utils/utils.go
Original file line number Diff line number Diff line change
Expand Up @@ -244,7 +244,7 @@ func AssertMatchesWithTimeout(t *testing.T, conn *mysql.Conn, query, expected st
}

// WaitForAuthoritative waits for a table to become authoritative
func WaitForAuthoritative(t *testing.T, ks, tbl string, readVSchema func() (*interface{}, error)) error {
func WaitForAuthoritative(t TestingT, ks, tbl string, readVSchema func() (*interface{}, error)) error {
timeout := time.After(60 * time.Second)
for {
select {
Expand Down Expand Up @@ -320,7 +320,7 @@ func WaitForTableDeletions(t *testing.T, vtgateProcess cluster.VtgateProcess, ks
}

// WaitForColumn waits for a table's column to be present
func WaitForColumn(t testing.TB, vtgateProcess cluster.VtgateProcess, ks, tbl, col string) error {
func WaitForColumn(t TestingT, vtgateProcess cluster.VtgateProcess, ks, tbl, col string) error {
timeout := time.After(60 * time.Second)
for {
select {
Expand Down Expand Up @@ -355,7 +355,7 @@ func WaitForColumn(t testing.TB, vtgateProcess cluster.VtgateProcess, ks, tbl, c
if !isMap {
break
}
if colName, exists := colDef["name"]; exists && colName == col {
if colName, exists := colDef["name"]; exists && strings.EqualFold(colName.(string), col) {
return nil
}
}
Expand Down

0 comments on commit 54e71e5

Please sign in to comment.