Skip to content

Commit b35bf70

Browse files
committed
changefeedccl: fix test assertion in TestNoStopAfterNonTargetColumnDrop
This patch replaces an incorrect usage of `require.Regexp` in `TestNoStopAfterNonTargetColumnDrop`. Release note: None
1 parent c0a561e commit b35bf70

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

pkg/ccl/changefeedccl/changefeed_test.go

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1833,9 +1833,9 @@ func TestNoStopAfterNonTargetColumnDrop(t *testing.T) {
18331833

18341834
// Check that dropping a watched column still stops the changefeed.
18351835
sqlDB.Exec(t, `ALTER TABLE hasfams DROP COLUMN b`)
1836-
if _, err := cf.Next(); !testutils.IsError(err, `schema change occurred at`) {
1837-
require.Regexp(t, `expected "schema change occurred at ..." got: %+v`, err)
1838-
}
1836+
msg, err := cf.Next()
1837+
require.True(t, testutils.IsError(err, `schema change occurred at`),
1838+
`expected "schema change occurred at ..." got: msg=%s, err=%+v`, msg, err)
18391839
}
18401840

18411841
runWithAndWithoutRegression141453(t, testFn, func(t *testing.T, testFn cdcTestFn) {

0 commit comments

Comments
 (0)