From b447f8fc83dbd8b7ea8497faec68df296478bae8 Mon Sep 17 00:00:00 2001 From: d-lau Date: Thu, 28 May 2020 11:18:21 +0900 Subject: [PATCH] add test for empty object --- notifier/github/client_test.go | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/notifier/github/client_test.go b/notifier/github/client_test.go index a31e688..c1604a3 100644 --- a/notifier/github/client_test.go +++ b/notifier/github/client_test.go @@ -212,6 +212,10 @@ func TestHasAnyLabelDefined(t *testing.T) { }, want: false, }, + { + rl: ResultLabels{}, + want: false, + }, } for _, testCase := range testCases { if testCase.rl.HasAnyLabelDefined() != testCase.want { @@ -266,6 +270,11 @@ func TestIsResultLabels(t *testing.T) { label: "", want: false, }, + { + rl: ResultLabels{}, + label: "", + want: false, + }, } for _, testCase := range testCases { if testCase.rl.IsResultLabel(testCase.label) != testCase.want {