Skip to content

Commit

Permalink
chore(test): Remove unit testing log output for success cases (#293)
Browse files Browse the repository at this point in the history
During running the unit tests we see output like

=== RUN   TestIssueService_DeleteAttachment
    TestIssueService_DeleteAttachment: issue_test.go:587: Attachment deleted
    TestIssueService_DeleteAttachment: issue_test.go:592: No error

This log can be removed, because this mostly confirms the success case.
The opposite case is throwing a testing error, which is visible as well.
Hence, there is no need to log this messages durcing testing
  • Loading branch information
andygrunwald authored May 3, 2020
1 parent 80c0282 commit eaaeec5
Showing 1 changed file with 1 addition and 4 deletions.
5 changes: 1 addition & 4 deletions issue_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -583,13 +583,10 @@ func TestIssueService_DeleteAttachment(t *testing.T) {
if resp.StatusCode == 404 {
t.Error("Attachment not found")
}
} else {
t.Log("Attachment deleted")
}

if err != nil {
t.Errorf("Error given: %s", err)
} else {
t.Log("No error")
}
}

Expand Down

0 comments on commit eaaeec5

Please sign in to comment.