From f1adaef45849fc260b07be39a39b9c1ee5146923 Mon Sep 17 00:00:00 2001 From: Ethan Koenig Date: Fri, 7 Jul 2017 15:36:47 -0400 Subject: Less verbose integration tests (#2123) * Helper functions for intergration test boilerplate --- integrations/api_issue_label_test.go | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) (limited to 'integrations/api_issue_label_test.go') diff --git a/integrations/api_issue_label_test.go b/integrations/api_issue_label_test.go index 2014d38e7d..195ec24ca8 100644 --- a/integrations/api_issue_label_test.go +++ b/integrations/api_issue_label_test.go @@ -29,8 +29,7 @@ func TestAPIAddIssueLabels(t *testing.T) { Labels: []int64{label.ID}, }) session := loginUser(t, owner.Name) - resp := session.MakeRequest(t, req) - assert.EqualValues(t, http.StatusOK, resp.HeaderCode) + resp := session.MakeRequest(t, req, http.StatusOK) var apiLabels []*api.Label DecodeJSON(t, resp, &apiLabels) assert.Len(t, apiLabels, models.GetCount(t, &models.IssueLabel{IssueID: issue.ID})) @@ -52,8 +51,7 @@ func TestAPIReplaceIssueLabels(t *testing.T) { Labels: []int64{label.ID}, }) session := loginUser(t, owner.Name) - resp := session.MakeRequest(t, req) - assert.EqualValues(t, http.StatusOK, resp.HeaderCode) + resp := session.MakeRequest(t, req, http.StatusOK) var apiLabels []*api.Label DecodeJSON(t, resp, &apiLabels) assert.Len(t, apiLabels, 1) -- cgit v1.2.3