Skip to content

Commit

Permalink
fix ut
Browse files Browse the repository at this point in the history
  • Loading branch information
okJiang committed Nov 24, 2023
1 parent 1aef5c7 commit da540d9
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion cdc/api/v2/changefeed_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -322,12 +322,13 @@ func TestUpdateChangefeed(t *testing.T) {
mockCapture.EXPECT().IsOwner().Return(true).AnyTimes()

// case 1 invalid id
invalidID := "#Invalid_"
invalidID := "_Invalid_"
w := httptest.NewRecorder()
req, _ := http.NewRequestWithContext(context.Background(), update.method,
fmt.Sprintf(update.url, invalidID), nil)
router.ServeHTTP(w, req)
respErr := model.HTTPError{}
t.Logf("body: %s", w.Body.String())
err := json.NewDecoder(w.Body).Decode(&respErr)
require.Nil(t, err)
require.Contains(t, respErr.Code, "ErrAPIInvalidParam")
Expand Down

0 comments on commit da540d9

Please sign in to comment.