gitlab

package
v0.6.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 13, 2020 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

View Source
const (
	DefaultBaseURL = "https://gitlab.com/"
	DefaultPerPage = 25
)

Variables

This section is empty.

Functions

This section is empty.

Types

type APIError

type APIError struct {
	// contains filtered or unexported fields
}

func NewAPIError

func NewAPIError(endpointType string, err error) *APIError

func (*APIError) Error

func (e *APIError) Error() string

func (*APIError) Is

func (e *APIError) Is(err error) bool

func (*APIError) Unwrap

func (e *APIError) Unwrap() error

type Client

type Client interface {
	ListMergeRequests(IIDs []int, perPage int) ([]MergeRequest, error)
}

func NewClient

func NewClient(privateToken string, projectID string) (Client, error)

func NewClientWithBaseURL

func NewClientWithBaseURL(privateToken string, projectID string, baseURL string) (Client, error)

type ClientNotCreatedError

type ClientNotCreatedError struct {
	// contains filtered or unexported fields
}

func NewClientNotCreatedError

func NewClientNotCreatedError(err error) *ClientNotCreatedError

func (*ClientNotCreatedError) Error

func (e *ClientNotCreatedError) Error() string

func (*ClientNotCreatedError) Is

func (e *ClientNotCreatedError) Is(err error) bool

func (*ClientNotCreatedError) Unwrap

func (e *ClientNotCreatedError) Unwrap() error

type MergeRequest

type MergeRequest struct {
	IID    int
	Title  string
	Labels []string

	AuthorName   string
	AuthorHandle string
}

func (MergeRequest) Author

func (mr MergeRequest) Author() string

type MockClient

type MockClient struct {
	mock.Mock
}

MockClient is an autogenerated mock type for the Client type

func (*MockClient) ListMergeRequests

func (_m *MockClient) ListMergeRequests(IIDs []int, perPage int) ([]MergeRequest, error)

ListMergeRequests provides a mock function with given fields: IIDs, perPage

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL