From 644bb3bff831e0daecdf3faec00244262b3b1ccf Mon Sep 17 00:00:00 2001 From: idbeta Date: Wed, 2 Dec 2020 13:20:34 +0800 Subject: [PATCH] fix: update testcase --- api/test/e2e/upstream_test.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/api/test/e2e/upstream_test.go b/api/test/e2e/upstream_test.go index d10994fe85..3d82f4165e 100644 --- a/api/test/e2e/upstream_test.go +++ b/api/test/e2e/upstream_test.go @@ -248,7 +248,7 @@ func TestUpstream_chash_remote_addr(t *testing.T) { var respBody []byte var count int res := map[string]int{} - for i := 0; i <= 17; i++ { + for i := 0; i < 18; i++ { resp, err = http.DefaultClient.Do(request) assert.Nil(t, err) respBody, err = ioutil.ReadAll(resp.Body) @@ -260,7 +260,7 @@ func TestUpstream_chash_remote_addr(t *testing.T) { } resp.Body.Close() } - assert.Equal(t, 18, res["1980"]+res["1981"]+res["1982"]) + assert.Equal(t, 18, res["1982"]) tests = []HttpTestCase{ {