Documentation
¶
Index ¶
- func FromTemplate() runtime.Runtime
- type Nerv
- type Runtime
- func (_m *Runtime) AttachWorkload(ctx context.Context, ID string) (io.Reader, io.Reader, error)
- func (_m *Runtime) CollectWorkloadMetrics(ctx context.Context, ID string)
- func (_m *Runtime) Events(ctx context.Context, filters map[string]string) (<-chan *types.WorkloadEventMessage, <-chan error)
- func (_m *Runtime) GetStatus(ctx context.Context, ID string, checkHealth bool) (*types.WorkloadStatus, error)
- func (_m *Runtime) GetWorkloadName(ctx context.Context, ID string) (string, error)
- func (_m *Runtime) IsDaemonRunning(ctx context.Context) bool
- func (_m *Runtime) ListWorkloadIDs(ctx context.Context, filters map[string]string) ([]string, error)
- func (_m *Runtime) LogFieldsExtra(ctx context.Context, ID string) (map[string]string, error)
- func (_m *Runtime) Name() string
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func FromTemplate ¶
FromTemplate returns a mock runtime instance created from template
Types ¶
type Nerv ¶
Nerv a fake runtime
func (*Nerv) SetDaemonRunning ¶
SetDaemonRunning set `daemonRunning`
func (*Nerv) StartCustomEvent ¶
func (n *Nerv) StartCustomEvent(event *types.WorkloadEventMessage)
StartCustomEvent .
func (*Nerv) StartEvents ¶
func (n *Nerv) StartEvents()
StartEvents starts the events: Shinji 400%, Asuka starts, Asuka dies, Rei dies
type Runtime ¶
Runtime is an autogenerated mock type for the Runtime type
func NewRuntime ¶
func NewRuntime(t mockConstructorTestingTNewRuntime) *Runtime
NewRuntime creates a new instance of Runtime. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations.
func (*Runtime) AttachWorkload ¶
AttachWorkload provides a mock function with given fields: ctx, ID
func (*Runtime) CollectWorkloadMetrics ¶
CollectWorkloadMetrics provides a mock function with given fields: ctx, ID
func (*Runtime) Events ¶
func (_m *Runtime) Events(ctx context.Context, filters map[string]string) (<-chan *types.WorkloadEventMessage, <-chan error)
Events provides a mock function with given fields: ctx, filters
func (*Runtime) GetStatus ¶
func (_m *Runtime) GetStatus(ctx context.Context, ID string, checkHealth bool) (*types.WorkloadStatus, error)
GetStatus provides a mock function with given fields: ctx, ID, checkHealth
func (*Runtime) GetWorkloadName ¶
GetWorkloadName provides a mock function with given fields: ctx, ID
func (*Runtime) IsDaemonRunning ¶
IsDaemonRunning provides a mock function with given fields: ctx
func (*Runtime) ListWorkloadIDs ¶
func (_m *Runtime) ListWorkloadIDs(ctx context.Context, filters map[string]string) ([]string, error)
ListWorkloadIDs provides a mock function with given fields: ctx, filters
func (*Runtime) LogFieldsExtra ¶
LogFieldsExtra provides a mock function with given fields: ctx, ID