Documentation ¶
Index ¶
- type WharfClientAPIFetcherMock
- func (m *WharfClientAPIFetcherMock) GetProvider(providerName, urlStr, uploadURLStr string, tokenID uint) (wharfapi.Provider, error)
- func (m *WharfClientAPIFetcherMock) GetProviderByID(providerID uint) (wharfapi.Provider, error)
- func (m *WharfClientAPIFetcherMock) GetToken(token, userName string) (wharfapi.Token, error)
- func (m *WharfClientAPIFetcherMock) GetTokenByID(tokenID uint) (wharfapi.Token, error)
- func (m *WharfClientAPIFetcherMock) PostProvider(provider wharfapi.Provider) (wharfapi.Provider, error)
- func (m *WharfClientAPIFetcherMock) PostToken(token wharfapi.Token) (wharfapi.Token, error)
- func (m *WharfClientAPIFetcherMock) PutBranches(branches []wharfapi.Branch) ([]wharfapi.Branch, error)
- func (m *WharfClientAPIFetcherMock) PutProject(project wharfapi.Project) (wharfapi.Project, error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type WharfClientAPIFetcherMock ¶ added in v1.2.0
WharfClientAPIFetcherMock is a mock variant of the wharfapi.Client with the help of github.com/stretchr/testify/mock.
func (*WharfClientAPIFetcherMock) GetProvider ¶ added in v1.2.0
func (m *WharfClientAPIFetcherMock) GetProvider(providerName, urlStr, uploadURLStr string, tokenID uint) (wharfapi.Provider, error)
GetProvider returns a provider as identified by its name, URL, and upload URL strings, as well as its token ID reference.
func (*WharfClientAPIFetcherMock) GetProviderByID ¶ added in v1.3.0
func (m *WharfClientAPIFetcherMock) GetProviderByID(providerID uint) (wharfapi.Provider, error)
GetProviderByID returns a provider as identified by its ID.
func (*WharfClientAPIFetcherMock) GetToken ¶ added in v1.2.0
func (m *WharfClientAPIFetcherMock) GetToken(token, userName string) (wharfapi.Token, error)
GetToken returns a token as identified by its token and username strings.
func (*WharfClientAPIFetcherMock) GetTokenByID ¶ added in v1.3.0
func (m *WharfClientAPIFetcherMock) GetTokenByID(tokenID uint) (wharfapi.Token, error)
GetTokenByID returns a token as identified by its ID.
func (*WharfClientAPIFetcherMock) PostProvider ¶ added in v1.2.0
func (m *WharfClientAPIFetcherMock) PostProvider(provider wharfapi.Provider) (wharfapi.Provider, error)
PostProvider creates a new provider and returns the created provider, populated with its newly assigned ID.
func (*WharfClientAPIFetcherMock) PostToken ¶ added in v1.2.0
PostToken creates a new token and returns the created token, populated with its newly assigned ID.
func (*WharfClientAPIFetcherMock) PutBranches ¶ added in v1.2.0
func (m *WharfClientAPIFetcherMock) PutBranches(branches []wharfapi.Branch) ([]wharfapi.Branch, error)
PutBranches replaces the list of branches for a project.
func (*WharfClientAPIFetcherMock) PutProject ¶ added in v1.2.0
PutProject creates or updates a project, based on wether the project ID value is non-zero, and returns the created or updated project, populated with its possibly newly assigned ID.