prstate

package
v0.0.0-...-993d511 Latest Latest
Warning

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

Go to latest
Published: Oct 14, 2019 License: AGPL-3.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type APIStorage

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

func NewAPIStorage

func NewAPIStorage(client httputils.Client) *APIStorage

func (APIStorage) GetState

func (s APIStorage) GetState(ctx context.Context, owner, name, analysisID string) (*State, error)

func (APIStorage) UpdateState

func (s APIStorage) UpdateState(ctx context.Context, owner, name, analysisID string, state *State) error

type MockStorage

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

MockStorage is a mock of Storage interface

func NewMockStorage

func NewMockStorage(ctrl *gomock.Controller) *MockStorage

NewMockStorage creates a new mock instance

func (*MockStorage) EXPECT

func (_m *MockStorage) EXPECT() *MockStorageMockRecorder

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

func (*MockStorage) GetState

func (_m *MockStorage) GetState(ctx context.Context, owner string, name string, analysisID string) (*State, error)

GetState mocks base method

func (*MockStorage) UpdateState

func (_m *MockStorage) UpdateState(ctx context.Context, owner string, name string, analysisID string, state *State) error

UpdateState mocks base method

type MockStorageMockRecorder

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

MockStorageMockRecorder is the mock recorder for MockStorage

func (*MockStorageMockRecorder) GetState

func (_mr *MockStorageMockRecorder) GetState(arg0, arg1, arg2, arg3 interface{}) *gomock.Call

GetState indicates an expected call of GetState

func (*MockStorageMockRecorder) UpdateState

func (_mr *MockStorageMockRecorder) UpdateState(arg0, arg1, arg2, arg3, arg4 interface{}) *gomock.Call

UpdateState indicates an expected call of UpdateState

type State

type State struct {
	CreatedAt           time.Time
	Status              string
	ReportedIssuesCount int
	ResultJSON          interface{}
}

type Storage

type Storage interface {
	UpdateState(ctx context.Context, owner, name, analysisID string, state *State) error
	GetState(ctx context.Context, owner, name, analysisID string) (*State, error)
}

Jump to

Keyboard shortcuts

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