From 81ea1e5cb324404cd87c66d2a1050c7c31a2121b Mon Sep 17 00:00:00 2001 From: Dmitri Shuralyov Date: Thu, 21 Apr 2016 22:36:17 -0700 Subject: [PATCH] Fix formatting directive issues in tests. As detected with go vet. Simplify code slightly by removing unnecessary brackets around a variable. --- github/repos_releases_test.go | 2 +- tests/integration/authorizations_test.go | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/github/repos_releases_test.go b/github/repos_releases_test.go index 2810d60..0151fcd 100644 --- a/github/repos_releases_test.go +++ b/github/repos_releases_test.go @@ -275,7 +275,7 @@ func TestRepositoriesService_DownloadReleaseAsset_APIError(t *testing.T) { } if loc != "" { - t.Error(`Repositories.DownloadReleaseAsset returned "%s", want empty ""`, loc) + t.Errorf(`Repositories.DownloadReleaseAsset returned "%s", want empty ""`, loc) } } diff --git a/tests/integration/authorizations_test.go b/tests/integration/authorizations_test.go index 2ad934c..7e953bf 100644 --- a/tests/integration/authorizations_test.go +++ b/tests/integration/authorizations_test.go @@ -52,7 +52,7 @@ func TestAuthorizationsBasicOperations(t *testing.T) { failIfNotStatusCode(t, resp, 200) if len(auths) != initialAuthCount+1 { - t.Fatalf("The number of Authorizations should have increased. Expected [%v], was [%v]", (initialAuthCount + 1), len(auths)) + t.Fatalf("The number of Authorizations should have increased. Expected [%v], was [%v]", initialAuthCount+1, len(auths)) } // Test updating the authorization @@ -94,7 +94,7 @@ func TestAuthorizationsBasicOperations(t *testing.T) { failIfNotStatusCode(t, resp, 200) if len(auths) != initialAuthCount { - t.Fatal("The number of Authorizations should match the initial count Expected [%v], got [%v]", (initialAuthCount), len(auths)) + t.Fatalf("The number of Authorizations should match the initial count Expected [%v], got [%v]", initialAuthCount, len(auths)) } }