From 61f81f549cd04b06e6311b140224ec485b3926ca Mon Sep 17 00:00:00 2001 From: ElvinChan Date: Wed, 5 Sep 2018 20:15:28 +0800 Subject: [PATCH] Cover test of tag for omitted field --- tag_test.go | 1 + 1 file changed, 1 insertion(+) diff --git a/tag_test.go b/tag_test.go index af2dbfe..095ea8a 100644 --- a/tag_test.go +++ b/tag_test.go @@ -81,6 +81,7 @@ func TestParamSwaggerTags(t *testing.T) { func TestHeaderSwaggerTags(t *testing.T) { type SearchInput struct { Q string `json:"q" swagger:"minLen(5),maxLen(8)"` + Enable bool `json:"-"` BrandIds string `json:"brandIds" swagger:"collect(csv)"` Sortby [][]string `json:"sortby" swagger:"default(id)"` Order []int `json:"order" swagger:"enum(0|1|n)"`