radix

package
v0.0.0-...-2490af2 Latest Latest
Warning

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

Go to latest
Published: Apr 29, 2024 License: MIT Imports: 11 Imported by: 0

Documentation

Overview

Package radix is a generated GoMock package.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type APIServer

type APIServer interface {
	ShowApplications(ctx context.Context, sshURL string) ([]*models.ApplicationSummary, error)
	GetApplication(ctx context.Context, appName string) (*models.Application, error)
	TriggerPipeline(ctx context.Context, appName, branch, commitID, triggeredBy string) (*models.JobSummary, error)
}

APIServer Stub methods in order to mock endpoints

func NewAPIServerStub

func NewAPIServerStub(apiServerEndPoint string, client *http.Client) APIServer

NewAPIServerStub Constructor

type APIServerStub

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

APIServerStub Makes calls to real API server

func (*APIServerStub) GetApplication

func (api *APIServerStub) GetApplication(ctx context.Context, appName string) (*models.Application, error)

GetApplication Implementation

func (*APIServerStub) ShowApplications

func (api *APIServerStub) ShowApplications(ctx context.Context, sshURL string) ([]*models.ApplicationSummary, error)

ShowApplications Implementation

func (*APIServerStub) TriggerPipeline

func (api *APIServerStub) TriggerPipeline(ctx context.Context, appName, branch, commitID, triggeredBy string) (*models.JobSummary, error)

TriggerPipeline Implementation

type ApiError

type ApiError struct {
	// a message that can be printed out for the user
	Message string `json:"message"`
	Code    int
}

ApiError Representation of parts of an error struct returned from the API

func (*ApiError) Error

func (e *ApiError) Error() string

type MockAPIServer

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

MockAPIServer is a mock of APIServer interface.

func NewMockAPIServer

func NewMockAPIServer(ctrl *gomock.Controller) *MockAPIServer

NewMockAPIServer creates a new mock instance.

func (*MockAPIServer) EXPECT

EXPECT returns an object that allows the caller to indicate expected use.

func (*MockAPIServer) GetApplication

func (m *MockAPIServer) GetApplication(ctx context.Context, appName string) (*models.Application, error)

GetApplication mocks base method.

func (*MockAPIServer) ShowApplications

func (m *MockAPIServer) ShowApplications(ctx context.Context, sshURL string) ([]*models.ApplicationSummary, error)

ShowApplications mocks base method.

func (*MockAPIServer) TriggerPipeline

func (m *MockAPIServer) TriggerPipeline(ctx context.Context, appName, branch, commitID, triggeredBy string) (*models.JobSummary, error)

TriggerPipeline mocks base method.

type MockAPIServerMockRecorder

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

MockAPIServerMockRecorder is the mock recorder for MockAPIServer.

func (*MockAPIServerMockRecorder) GetApplication

func (mr *MockAPIServerMockRecorder) GetApplication(ctx, appName interface{}) *gomock.Call

GetApplication indicates an expected call of GetApplication.

func (*MockAPIServerMockRecorder) ShowApplications

func (mr *MockAPIServerMockRecorder) ShowApplications(ctx, sshURL interface{}) *gomock.Call

ShowApplications indicates an expected call of ShowApplications.

func (*MockAPIServerMockRecorder) TriggerPipeline

func (mr *MockAPIServerMockRecorder) TriggerPipeline(ctx, appName, branch, commitID, triggeredBy interface{}) *gomock.Call

TriggerPipeline indicates an expected call of TriggerPipeline.

Jump to

Keyboard shortcuts

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