Browse Source

fixes for gofmt -s, golint, and go vet

Will Norris 11 years ago
parent
commit
7ea4ee6d22
6 changed files with 10 additions and 10 deletions
  1. +4
    -4
      github/pulls_test.go
  2. +1
    -1
      github/repos_releases.go
  3. +1
    -1
      github/repos_stats_test.go
  4. +2
    -2
      github/search_test.go
  5. +1
    -1
      tests/fields/fields.go
  6. +1
    -1
      tests/integration/github_test.go

+ 4
- 4
github/pulls_test.go View File

@ -209,7 +209,7 @@ func TestPullRequestsService_ListCommits(t *testing.T) {
{
SHA: String("3"),
Parents: []Commit{
Commit{
{
SHA: String("2"),
},
},
@ -217,7 +217,7 @@ func TestPullRequestsService_ListCommits(t *testing.T) {
{
SHA: String("2"),
Parents: []Commit{
Commit{
{
SHA: String("1"),
},
},
@ -265,7 +265,7 @@ func TestPullRequestsService_ListFiles(t *testing.T) {
}
want := []CommitFile{
CommitFile{
{
SHA: String("6dcb09b5b57875f334f61aebed695e2e4193db5e"),
Filename: String("file1.txt"),
Additions: Int(103),
@ -274,7 +274,7 @@ func TestPullRequestsService_ListFiles(t *testing.T) {
Status: String("added"),
Patch: String("@@ -132,7 +132,7 @@ module Test @@ -1000,7 +1000,7 @@ module Test"),
},
CommitFile{
{
SHA: String("f61aebed695e2e4193db5e6dcb09b5b57875f334"),
Filename: String("file2.txt"),
Additions: Int(5),


+ 1
- 1
github/repos_releases.go View File

@ -49,7 +49,7 @@ type ReleaseAsset struct {
DownloadCount *int `json:"download_count,omitempty"`
CreatedAt *Timestamp `json:"created_at,omitempty"`
UpdatedAt *Timestamp `json:"updated_at,omitempty"`
BrowserDownloadUrl *string `json:"browser_download_url,omitempty"`
BrowserDownloadURL *string `json:"browser_download_url,omitempty"`
Uploader *User `json:"uploader,omitempty"`
}


+ 1
- 1
github/repos_stats_test.go View File

@ -46,7 +46,7 @@ func TestRepositoriesService_ListContributorsStats(t *testing.T) {
}
want := []ContributorStats{
ContributorStats{
{
Author: &Contributor{
ID: Int(1),
},


+ 2
- 2
github/search_test.go View File

@ -179,9 +179,9 @@ func TestSearchService_CodeTextMatch(t *testing.T) {
wantedCodeResult := CodeResult{
Name: String("gopher1"),
TextMatches: []TextMatch{TextMatch{
TextMatches: []TextMatch{{
Fragment: String("I'm afraid my friend what you have found\nIs a gopher who lives to feed"),
Matches: []Match{Match{Text: String("gopher"), Indices: []int{14, 21}}},
Matches: []Match{{Text: String("gopher"), Indices: []int{14, 21}}},
},
},
}


+ 1
- 1
tests/fields/fields.go View File

@ -43,7 +43,7 @@ func main() {
token := os.Getenv("GITHUB_AUTH_TOKEN")
if token == "" {
println("!!! No OAuth token. Some tests won't run. !!!\n")
print("!!! No OAuth token. Some tests won't run. !!!\n\n")
client = github.NewClient(nil)
} else {
t := &oauth.Transport{


+ 1
- 1
tests/integration/github_test.go View File

@ -28,7 +28,7 @@ var (
func init() {
token := os.Getenv("GITHUB_AUTH_TOKEN")
if token == "" {
println("!!! No OAuth token. Some tests won't run. !!!\n")
print("!!! No OAuth token. Some tests won't run. !!!\n\n")
client = github.NewClient(nil)
} else {
t := &oauth.Transport{


Loading…
Cancel
Save