From 33f0657f5c54020b84998e3121f04db5c200e66c Mon Sep 17 00:00:00 2001 From: Shiwei Zhang Date: Sat, 16 Mar 2024 21:41:38 +0800 Subject: [PATCH] chore: apply strict equal comparison Signed-off-by: Shiwei Zhang --- conformance/04_management_test.go | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/conformance/04_management_test.go b/conformance/04_management_test.go index 9c89a70e..78b7af6b 100644 --- a/conformance/04_management_test.go +++ b/conformance/04_management_test.go @@ -135,12 +135,16 @@ var test04ContentManagement = func() { Equal(http.StatusNotFound), Equal(http.StatusOK), )) + expectTags := numTags - 1 if resp.StatusCode() == http.StatusOK { tagList := &TagList{} jsonData := []byte(resp.String()) err = json.Unmarshal(jsonData, tagList) Expect(err).To(BeNil()) - Expect(len(tagList.Tags)).To(BeNumerically("<", numTags)) + Expect(len(tagList.Tags)).To(Equal(expectTags)) + } + if resp.StatusCode() == http.StatusNotFound { + Expect(expectTags).To(Equal(0)) } }) })