Documentation ¶
Overview ¶
Package client contains client for Jenkins API
Package mock_client is a generated GoMock package.
Index ¶
- func BuildJenkinsAPIUrl(namespace, serviceName string, portNumber int, local, minikube bool) (string, error)
- type Jenkins
- type MockJenkins
- func (m *MockJenkins) BuildJob(name string, options ...interface{}) (int64, error)
- func (m *MockJenkins) CopyJob(copyFrom, newName string) (*gojenkins.Job, error)
- func (m *MockJenkins) CreateFolder(name string, parents ...string) (*gojenkins.Folder, error)
- func (m *MockJenkins) CreateJob(config string, options ...interface{}) (*gojenkins.Job, error)
- func (m *MockJenkins) CreateJobInFolder(config, jobName string, parentIDs ...string) (*gojenkins.Job, error)
- func (m *MockJenkins) CreateNode(name string, numExecutors int, description, remoteFS, label string, ...) (*gojenkins.Node, error)
- func (m *MockJenkins) CreateOrUpdateJob(config string, options ...interface{}) (*gojenkins.Job, error)
- func (m *MockJenkins) CreateView(name, viewType string) (*gojenkins.View, error)
- func (m *MockJenkins) DeleteJob(name string) (bool, error)
- func (m *MockJenkins) DeleteNode(name string) (bool, error)
- func (m *MockJenkins) EXPECT() *MockJenkinsMockRecorder
- func (m *MockJenkins) GenerateToken(userName, tokenName string) (*UserToken, error)
- func (m *MockJenkins) GetAllBuildIds(job string) ([]gojenkins.JobBuild, error)
- func (m *MockJenkins) GetAllJobNames() ([]gojenkins.InnerJob, error)
- func (m *MockJenkins) GetAllJobs() ([]*gojenkins.Job, error)
- func (m *MockJenkins) GetAllNodes() ([]*gojenkins.Node, error)
- func (m *MockJenkins) GetAllViews() ([]*gojenkins.View, error)
- func (m *MockJenkins) GetArtifactData(id string) (*gojenkins.FingerPrintResponse, error)
- func (m *MockJenkins) GetBuild(jobName string, number int64) (*gojenkins.Build, error)
- func (m *MockJenkins) GetFolder(id string, parents ...string) (*gojenkins.Folder, error)
- func (m *MockJenkins) GetJob(id string, parentIDs ...string) (*gojenkins.Job, error)
- func (m *MockJenkins) GetLabel(name string) (*gojenkins.Label, error)
- func (m *MockJenkins) GetNode(name string) (*gojenkins.Node, error)
- func (m *MockJenkins) GetPlugins(depth int) (*gojenkins.Plugins, error)
- func (m *MockJenkins) GetQueue() (*gojenkins.Queue, error)
- func (m *MockJenkins) GetQueueItem(id int64) (*gojenkins.Task, error)
- func (m *MockJenkins) GetQueueUrl() string
- func (m *MockJenkins) GetSubJob(parentID, childID string) (*gojenkins.Job, error)
- func (m *MockJenkins) GetView(name string) (*gojenkins.View, error)
- func (m *MockJenkins) HasPlugin(name string) (*gojenkins.Plugin, error)
- func (m *MockJenkins) Info() (*gojenkins.ExecutorResponse, error)
- func (m *MockJenkins) InstallPlugin(name, version string) error
- func (m *MockJenkins) Poll() (int, error)
- func (m *MockJenkins) RenameJob(job, name string) *gojenkins.Job
- func (m *MockJenkins) SafeRestart() error
- func (m *MockJenkins) UninstallPlugin(name string) error
- func (m *MockJenkins) ValidateFingerPrint(id string) (bool, error)
- type MockJenkinsMockRecorder
- func (mr *MockJenkinsMockRecorder) BuildJob(name interface{}, options ...interface{}) *gomock.Call
- func (mr *MockJenkinsMockRecorder) CopyJob(copyFrom, newName interface{}) *gomock.Call
- func (mr *MockJenkinsMockRecorder) CreateFolder(name interface{}, parents ...interface{}) *gomock.Call
- func (mr *MockJenkinsMockRecorder) CreateJob(config interface{}, options ...interface{}) *gomock.Call
- func (mr *MockJenkinsMockRecorder) CreateJobInFolder(config, jobName interface{}, parentIDs ...interface{}) *gomock.Call
- func (mr *MockJenkinsMockRecorder) CreateNode(name, numExecutors, description, remoteFS, label interface{}, ...) *gomock.Call
- func (mr *MockJenkinsMockRecorder) CreateOrUpdateJob(config interface{}, options ...interface{}) *gomock.Call
- func (mr *MockJenkinsMockRecorder) CreateView(name, viewType interface{}) *gomock.Call
- func (mr *MockJenkinsMockRecorder) DeleteJob(name interface{}) *gomock.Call
- func (mr *MockJenkinsMockRecorder) DeleteNode(name interface{}) *gomock.Call
- func (mr *MockJenkinsMockRecorder) GenerateToken(userName, tokenName interface{}) *gomock.Call
- func (mr *MockJenkinsMockRecorder) GetAllBuildIds(job interface{}) *gomock.Call
- func (mr *MockJenkinsMockRecorder) GetAllJobNames() *gomock.Call
- func (mr *MockJenkinsMockRecorder) GetAllJobs() *gomock.Call
- func (mr *MockJenkinsMockRecorder) GetAllNodes() *gomock.Call
- func (mr *MockJenkinsMockRecorder) GetAllViews() *gomock.Call
- func (mr *MockJenkinsMockRecorder) GetArtifactData(id interface{}) *gomock.Call
- func (mr *MockJenkinsMockRecorder) GetBuild(jobName, number interface{}) *gomock.Call
- func (mr *MockJenkinsMockRecorder) GetFolder(id interface{}, parents ...interface{}) *gomock.Call
- func (mr *MockJenkinsMockRecorder) GetJob(id interface{}, parentIDs ...interface{}) *gomock.Call
- func (mr *MockJenkinsMockRecorder) GetLabel(name interface{}) *gomock.Call
- func (mr *MockJenkinsMockRecorder) GetNode(name interface{}) *gomock.Call
- func (mr *MockJenkinsMockRecorder) GetPlugins(depth interface{}) *gomock.Call
- func (mr *MockJenkinsMockRecorder) GetQueue() *gomock.Call
- func (mr *MockJenkinsMockRecorder) GetQueueItem(id interface{}) *gomock.Call
- func (mr *MockJenkinsMockRecorder) GetQueueUrl() *gomock.Call
- func (mr *MockJenkinsMockRecorder) GetSubJob(parentID, childID interface{}) *gomock.Call
- func (mr *MockJenkinsMockRecorder) GetView(name interface{}) *gomock.Call
- func (mr *MockJenkinsMockRecorder) HasPlugin(name interface{}) *gomock.Call
- func (mr *MockJenkinsMockRecorder) Info() *gomock.Call
- func (mr *MockJenkinsMockRecorder) InstallPlugin(name, version interface{}) *gomock.Call
- func (mr *MockJenkinsMockRecorder) Poll() *gomock.Call
- func (mr *MockJenkinsMockRecorder) RenameJob(job, name interface{}) *gomock.Call
- func (mr *MockJenkinsMockRecorder) SafeRestart() *gomock.Call
- func (mr *MockJenkinsMockRecorder) UninstallPlugin(name interface{}) *gomock.Call
- func (mr *MockJenkinsMockRecorder) ValidateFingerPrint(id interface{}) *gomock.Call
- type UserToken
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Jenkins ¶
type Jenkins interface { GenerateToken(userName, tokenName string) (*UserToken, error) Info() (*gojenkins.ExecutorResponse, error) SafeRestart() error CreateNode(name string, numExecutors int, description string, remoteFS string, label string, options ...interface{}) (*gojenkins.Node, error) DeleteNode(name string) (bool, error) CreateFolder(name string, parents ...string) (*gojenkins.Folder, error) CreateJobInFolder(config string, jobName string, parentIDs ...string) (*gojenkins.Job, error) CreateJob(config string, options ...interface{}) (*gojenkins.Job, error) CreateOrUpdateJob(config string, options ...interface{}) (*gojenkins.Job, error) RenameJob(job string, name string) *gojenkins.Job CopyJob(copyFrom string, newName string) (*gojenkins.Job, error) DeleteJob(name string) (bool, error) BuildJob(name string, options ...interface{}) (int64, error) GetNode(name string) (*gojenkins.Node, error) GetLabel(name string) (*gojenkins.Label, error) GetBuild(jobName string, number int64) (*gojenkins.Build, error) GetJob(id string, parentIDs ...string) (*gojenkins.Job, error) GetSubJob(parentID string, childID string) (*gojenkins.Job, error) GetFolder(id string, parents ...string) (*gojenkins.Folder, error) GetAllNodes() ([]*gojenkins.Node, error) GetAllBuildIds(job string) ([]gojenkins.JobBuild, error) GetAllJobNames() ([]gojenkins.InnerJob, error) GetAllJobs() ([]*gojenkins.Job, error) GetQueue() (*gojenkins.Queue, error) GetQueueUrl() string GetQueueItem(id int64) (*gojenkins.Task, error) GetArtifactData(id string) (*gojenkins.FingerPrintResponse, error) GetPlugins(depth int) (*gojenkins.Plugins, error) UninstallPlugin(name string) error HasPlugin(name string) (*gojenkins.Plugin, error) InstallPlugin(name string, version string) error ValidateFingerPrint(id string) (bool, error) GetView(name string) (*gojenkins.View, error) GetAllViews() ([]*gojenkins.View, error) CreateView(name string, viewType string) (*gojenkins.View, error) Poll() (int, error) }
Jenkins defines Jenkins API
type MockJenkins ¶
type MockJenkins struct {
// contains filtered or unexported fields
}
MockJenkins is a mock of Jenkins interface
func NewMockJenkins ¶
func NewMockJenkins(ctrl *gomock.Controller) *MockJenkins
NewMockJenkins creates a new mock instance
func (*MockJenkins) BuildJob ¶
func (m *MockJenkins) BuildJob(name string, options ...interface{}) (int64, error)
BuildJob mocks base method
func (*MockJenkins) CopyJob ¶
func (m *MockJenkins) CopyJob(copyFrom, newName string) (*gojenkins.Job, error)
CopyJob mocks base method
func (*MockJenkins) CreateFolder ¶
CreateFolder mocks base method
func (*MockJenkins) CreateJob ¶
func (m *MockJenkins) CreateJob(config string, options ...interface{}) (*gojenkins.Job, error)
CreateJob mocks base method
func (*MockJenkins) CreateJobInFolder ¶
func (m *MockJenkins) CreateJobInFolder(config, jobName string, parentIDs ...string) (*gojenkins.Job, error)
CreateJobInFolder mocks base method
func (*MockJenkins) CreateNode ¶
func (m *MockJenkins) CreateNode(name string, numExecutors int, description, remoteFS, label string, options ...interface{}) (*gojenkins.Node, error)
CreateNode mocks base method
func (*MockJenkins) CreateOrUpdateJob ¶
func (m *MockJenkins) CreateOrUpdateJob(config string, options ...interface{}) (*gojenkins.Job, error)
CreateOrUpdateJob mocks base method
func (*MockJenkins) CreateView ¶
func (m *MockJenkins) CreateView(name, viewType string) (*gojenkins.View, error)
CreateView mocks base method
func (*MockJenkins) DeleteJob ¶
func (m *MockJenkins) DeleteJob(name string) (bool, error)
DeleteJob mocks base method
func (*MockJenkins) DeleteNode ¶
func (m *MockJenkins) DeleteNode(name string) (bool, error)
DeleteNode mocks base method
func (*MockJenkins) EXPECT ¶
func (m *MockJenkins) EXPECT() *MockJenkinsMockRecorder
EXPECT returns an object that allows the caller to indicate expected use
func (*MockJenkins) GenerateToken ¶
func (m *MockJenkins) GenerateToken(userName, tokenName string) (*UserToken, error)
GenerateToken mocks base method
func (*MockJenkins) GetAllBuildIds ¶
func (m *MockJenkins) GetAllBuildIds(job string) ([]gojenkins.JobBuild, error)
GetAllBuildIds mocks base method
func (*MockJenkins) GetAllJobNames ¶
func (m *MockJenkins) GetAllJobNames() ([]gojenkins.InnerJob, error)
GetAllJobNames mocks base method
func (*MockJenkins) GetAllJobs ¶
func (m *MockJenkins) GetAllJobs() ([]*gojenkins.Job, error)
GetAllJobs mocks base method
func (*MockJenkins) GetAllNodes ¶
func (m *MockJenkins) GetAllNodes() ([]*gojenkins.Node, error)
GetAllNodes mocks base method
func (*MockJenkins) GetAllViews ¶
func (m *MockJenkins) GetAllViews() ([]*gojenkins.View, error)
GetAllViews mocks base method
func (*MockJenkins) GetArtifactData ¶
func (m *MockJenkins) GetArtifactData(id string) (*gojenkins.FingerPrintResponse, error)
GetArtifactData mocks base method
func (*MockJenkins) GetLabel ¶
func (m *MockJenkins) GetLabel(name string) (*gojenkins.Label, error)
GetLabel mocks base method
func (*MockJenkins) GetNode ¶
func (m *MockJenkins) GetNode(name string) (*gojenkins.Node, error)
GetNode mocks base method
func (*MockJenkins) GetPlugins ¶
func (m *MockJenkins) GetPlugins(depth int) (*gojenkins.Plugins, error)
GetPlugins mocks base method
func (*MockJenkins) GetQueue ¶
func (m *MockJenkins) GetQueue() (*gojenkins.Queue, error)
GetQueue mocks base method
func (*MockJenkins) GetQueueItem ¶
func (m *MockJenkins) GetQueueItem(id int64) (*gojenkins.Task, error)
GetQueueItem mocks base method
func (*MockJenkins) GetQueueUrl ¶
func (m *MockJenkins) GetQueueUrl() string
GetQueueUrl mocks base method
func (*MockJenkins) GetSubJob ¶
func (m *MockJenkins) GetSubJob(parentID, childID string) (*gojenkins.Job, error)
GetSubJob mocks base method
func (*MockJenkins) GetView ¶
func (m *MockJenkins) GetView(name string) (*gojenkins.View, error)
GetView mocks base method
func (*MockJenkins) HasPlugin ¶
func (m *MockJenkins) HasPlugin(name string) (*gojenkins.Plugin, error)
HasPlugin mocks base method
func (*MockJenkins) Info ¶
func (m *MockJenkins) Info() (*gojenkins.ExecutorResponse, error)
Info mocks base method
func (*MockJenkins) InstallPlugin ¶
func (m *MockJenkins) InstallPlugin(name, version string) error
InstallPlugin mocks base method
func (*MockJenkins) RenameJob ¶
func (m *MockJenkins) RenameJob(job, name string) *gojenkins.Job
RenameJob mocks base method
func (*MockJenkins) SafeRestart ¶
func (m *MockJenkins) SafeRestart() error
SafeRestart mocks base method
func (*MockJenkins) UninstallPlugin ¶
func (m *MockJenkins) UninstallPlugin(name string) error
UninstallPlugin mocks base method
func (*MockJenkins) ValidateFingerPrint ¶
func (m *MockJenkins) ValidateFingerPrint(id string) (bool, error)
ValidateFingerPrint mocks base method
type MockJenkinsMockRecorder ¶
type MockJenkinsMockRecorder struct {
// contains filtered or unexported fields
}
MockJenkinsMockRecorder is the mock recorder for MockJenkins
func (*MockJenkinsMockRecorder) BuildJob ¶
func (mr *MockJenkinsMockRecorder) BuildJob(name interface{}, options ...interface{}) *gomock.Call
BuildJob indicates an expected call of BuildJob
func (*MockJenkinsMockRecorder) CopyJob ¶
func (mr *MockJenkinsMockRecorder) CopyJob(copyFrom, newName interface{}) *gomock.Call
CopyJob indicates an expected call of CopyJob
func (*MockJenkinsMockRecorder) CreateFolder ¶
func (mr *MockJenkinsMockRecorder) CreateFolder(name interface{}, parents ...interface{}) *gomock.Call
CreateFolder indicates an expected call of CreateFolder
func (*MockJenkinsMockRecorder) CreateJob ¶
func (mr *MockJenkinsMockRecorder) CreateJob(config interface{}, options ...interface{}) *gomock.Call
CreateJob indicates an expected call of CreateJob
func (*MockJenkinsMockRecorder) CreateJobInFolder ¶
func (mr *MockJenkinsMockRecorder) CreateJobInFolder(config, jobName interface{}, parentIDs ...interface{}) *gomock.Call
CreateJobInFolder indicates an expected call of CreateJobInFolder
func (*MockJenkinsMockRecorder) CreateNode ¶
func (mr *MockJenkinsMockRecorder) CreateNode(name, numExecutors, description, remoteFS, label interface{}, options ...interface{}) *gomock.Call
CreateNode indicates an expected call of CreateNode
func (*MockJenkinsMockRecorder) CreateOrUpdateJob ¶
func (mr *MockJenkinsMockRecorder) CreateOrUpdateJob(config interface{}, options ...interface{}) *gomock.Call
CreateOrUpdateJob indicates an expected call of CreateOrUpdateJob
func (*MockJenkinsMockRecorder) CreateView ¶
func (mr *MockJenkinsMockRecorder) CreateView(name, viewType interface{}) *gomock.Call
CreateView indicates an expected call of CreateView
func (*MockJenkinsMockRecorder) DeleteJob ¶
func (mr *MockJenkinsMockRecorder) DeleteJob(name interface{}) *gomock.Call
DeleteJob indicates an expected call of DeleteJob
func (*MockJenkinsMockRecorder) DeleteNode ¶
func (mr *MockJenkinsMockRecorder) DeleteNode(name interface{}) *gomock.Call
DeleteNode indicates an expected call of DeleteNode
func (*MockJenkinsMockRecorder) GenerateToken ¶
func (mr *MockJenkinsMockRecorder) GenerateToken(userName, tokenName interface{}) *gomock.Call
GenerateToken indicates an expected call of GenerateToken
func (*MockJenkinsMockRecorder) GetAllBuildIds ¶
func (mr *MockJenkinsMockRecorder) GetAllBuildIds(job interface{}) *gomock.Call
GetAllBuildIds indicates an expected call of GetAllBuildIds
func (*MockJenkinsMockRecorder) GetAllJobNames ¶
func (mr *MockJenkinsMockRecorder) GetAllJobNames() *gomock.Call
GetAllJobNames indicates an expected call of GetAllJobNames
func (*MockJenkinsMockRecorder) GetAllJobs ¶
func (mr *MockJenkinsMockRecorder) GetAllJobs() *gomock.Call
GetAllJobs indicates an expected call of GetAllJobs
func (*MockJenkinsMockRecorder) GetAllNodes ¶
func (mr *MockJenkinsMockRecorder) GetAllNodes() *gomock.Call
GetAllNodes indicates an expected call of GetAllNodes
func (*MockJenkinsMockRecorder) GetAllViews ¶
func (mr *MockJenkinsMockRecorder) GetAllViews() *gomock.Call
GetAllViews indicates an expected call of GetAllViews
func (*MockJenkinsMockRecorder) GetArtifactData ¶
func (mr *MockJenkinsMockRecorder) GetArtifactData(id interface{}) *gomock.Call
GetArtifactData indicates an expected call of GetArtifactData
func (*MockJenkinsMockRecorder) GetBuild ¶
func (mr *MockJenkinsMockRecorder) GetBuild(jobName, number interface{}) *gomock.Call
GetBuild indicates an expected call of GetBuild
func (*MockJenkinsMockRecorder) GetFolder ¶
func (mr *MockJenkinsMockRecorder) GetFolder(id interface{}, parents ...interface{}) *gomock.Call
GetFolder indicates an expected call of GetFolder
func (*MockJenkinsMockRecorder) GetJob ¶
func (mr *MockJenkinsMockRecorder) GetJob(id interface{}, parentIDs ...interface{}) *gomock.Call
GetJob indicates an expected call of GetJob
func (*MockJenkinsMockRecorder) GetLabel ¶
func (mr *MockJenkinsMockRecorder) GetLabel(name interface{}) *gomock.Call
GetLabel indicates an expected call of GetLabel
func (*MockJenkinsMockRecorder) GetNode ¶
func (mr *MockJenkinsMockRecorder) GetNode(name interface{}) *gomock.Call
GetNode indicates an expected call of GetNode
func (*MockJenkinsMockRecorder) GetPlugins ¶
func (mr *MockJenkinsMockRecorder) GetPlugins(depth interface{}) *gomock.Call
GetPlugins indicates an expected call of GetPlugins
func (*MockJenkinsMockRecorder) GetQueue ¶
func (mr *MockJenkinsMockRecorder) GetQueue() *gomock.Call
GetQueue indicates an expected call of GetQueue
func (*MockJenkinsMockRecorder) GetQueueItem ¶
func (mr *MockJenkinsMockRecorder) GetQueueItem(id interface{}) *gomock.Call
GetQueueItem indicates an expected call of GetQueueItem
func (*MockJenkinsMockRecorder) GetQueueUrl ¶
func (mr *MockJenkinsMockRecorder) GetQueueUrl() *gomock.Call
GetQueueUrl indicates an expected call of GetQueueUrl
func (*MockJenkinsMockRecorder) GetSubJob ¶
func (mr *MockJenkinsMockRecorder) GetSubJob(parentID, childID interface{}) *gomock.Call
GetSubJob indicates an expected call of GetSubJob
func (*MockJenkinsMockRecorder) GetView ¶
func (mr *MockJenkinsMockRecorder) GetView(name interface{}) *gomock.Call
GetView indicates an expected call of GetView
func (*MockJenkinsMockRecorder) HasPlugin ¶
func (mr *MockJenkinsMockRecorder) HasPlugin(name interface{}) *gomock.Call
HasPlugin indicates an expected call of HasPlugin
func (*MockJenkinsMockRecorder) Info ¶
func (mr *MockJenkinsMockRecorder) Info() *gomock.Call
Info indicates an expected call of Info
func (*MockJenkinsMockRecorder) InstallPlugin ¶
func (mr *MockJenkinsMockRecorder) InstallPlugin(name, version interface{}) *gomock.Call
InstallPlugin indicates an expected call of InstallPlugin
func (*MockJenkinsMockRecorder) Poll ¶
func (mr *MockJenkinsMockRecorder) Poll() *gomock.Call
Poll indicates an expected call of Poll
func (*MockJenkinsMockRecorder) RenameJob ¶
func (mr *MockJenkinsMockRecorder) RenameJob(job, name interface{}) *gomock.Call
RenameJob indicates an expected call of RenameJob
func (*MockJenkinsMockRecorder) SafeRestart ¶
func (mr *MockJenkinsMockRecorder) SafeRestart() *gomock.Call
SafeRestart indicates an expected call of SafeRestart
func (*MockJenkinsMockRecorder) UninstallPlugin ¶
func (mr *MockJenkinsMockRecorder) UninstallPlugin(name interface{}) *gomock.Call
UninstallPlugin indicates an expected call of UninstallPlugin
func (*MockJenkinsMockRecorder) ValidateFingerPrint ¶
func (mr *MockJenkinsMockRecorder) ValidateFingerPrint(id interface{}) *gomock.Call
ValidateFingerPrint indicates an expected call of ValidateFingerPrint