diff --git a/merge_requests.go b/merge_requests.go index 1531dfdfc..f5b68fdfa 100644 --- a/merge_requests.go +++ b/merge_requests.go @@ -468,7 +468,7 @@ type GetMergeRequestChangesOptions struct { // its files and changes. // // Deprecated: This endpoint has been replaced by -// MergeRequestsService.ListMergeRequesDiffs() +// MergeRequestsService.ListMergeRequestDiffs() // // GitLab API docs: // https://docs.gitlab.com/ee/api/merge_requests.html#get-single-merge-request-changes @@ -493,7 +493,7 @@ func (s *MergeRequestsService) GetMergeRequestChanges(pid interface{}, mergeRequ return m, resp, nil } -// ListMergeRequestDiffsOptions represents the available ListMergeRequesDiffs() +// ListMergeRequestDiffsOptions represents the available ListMergeRequestDiffs() // options. // // GitLab API docs: diff --git a/merge_requests_test.go b/merge_requests_test.go index 28ddf5c0f..b7301ca16 100644 --- a/merge_requests_test.go +++ b/merge_requests_test.go @@ -288,7 +288,7 @@ func TestGetIssuesClosedOnMerge_Jira(t *testing.T) { assert.Equal(t, "Title of this issue", issues[0].Title) } -func TestListMergeRequesDiffs(t *testing.T) { +func TestListMergeRequestDiffs(t *testing.T) { mux, client := setup(t) mux.HandleFunc("/api/v4/projects/1/merge_requests/1/diffs", func(w http.ResponseWriter, r *http.Request) { @@ -303,7 +303,7 @@ func TestListMergeRequesDiffs(t *testing.T) { diffs, _, err := client.MergeRequests.ListMergeRequestDiffs(1, 1, opts) if err != nil { - t.Errorf("MergeRequests.ListMergeRequesDiffs returned error: %v", err) + t.Errorf("MergeRequests.ListMergeRequestDiffs returned error: %v", err) } want := []*MergeRequestDiff{ @@ -330,7 +330,7 @@ func TestListMergeRequesDiffs(t *testing.T) { } if !reflect.DeepEqual(want, diffs) { - t.Errorf("MergeRequests.ListMergeRequesDiffs returned %+v, want %+v", diffs, want) + t.Errorf("MergeRequests.ListMergeRequestDiffs returned %+v, want %+v", diffs, want) } }