1
0
mirror of https://github.com/interviewstreet/go-jira.git synced 2025-03-17 20:47:57 +02:00

doc: Fix comments

This commit is contained in:
Thibaut Rousseau 2018-06-25 17:52:57 +02:00
parent fb1ce22699
commit 52e8877e24
No known key found for this signature in database
GPG Key ID: BCA6444086610E3D
2 changed files with 5 additions and 6 deletions

@ -1,14 +1,13 @@
package jira
// PriorityService handles priorities for the JIRA instance / API.
// FieldService handles fields for the JIRA instance / API.
//
// JIRA API docs: https://developer.atlassian.com/cloud/jira/platform/rest/#api-Priority
// JIRA API docs: https://developer.atlassian.com/cloud/jira/platform/rest/#api-Field
type FieldService struct {
client *Client
}
// Priority represents a priority of a JIRA issue.
// Typical types are "Normal", "Moderate", "Urgent", ...
// Field represents a field of a JIRA issue.
type Field struct {
ID string `json:"id,omitempty" structs:"id,omitempty"`
Key string `json:"key,omitempty" structs:"key,omitempty"`
@ -27,7 +26,7 @@ type FieldSchema struct {
// GetList gets all fields from JIRA
//
// JIRA API docs: https://developer.atlassian.com/cloud/jira/platform/rest/#api-api-2-priority-get
// JIRA API docs: https://developer.atlassian.com/cloud/jira/platform/rest/#api-api-2-field-get
func (s *FieldService) GetList() ([]Field, *Response, error) {
apiEndpoint := "rest/api/2/field"
req, err := s.client.NewRequest("GET", apiEndpoint, nil)

@ -24,7 +24,7 @@ func TestFieldService_GetList(t *testing.T) {
fields, _, err := testClient.Field.GetList()
if fields == nil {
t.Error("Expected priority list. Priority list is nil")
t.Error("Expected field list. Field list is nil")
}
if err != nil {
t.Errorf("Error given: %s", err)