Documentation ¶
Index ¶
- Variables
- type FakeEvent
- type FakeMachine
- type FakeMachineClassStatus
- type FakeNetworkInterface
- type FakeRuntimeService
- func (r *FakeRuntimeService) AttachNetworkInterface(ctx context.Context, req *iri.AttachNetworkInterfaceRequest) (*iri.AttachNetworkInterfaceResponse, error)
- func (r *FakeRuntimeService) AttachVolume(ctx context.Context, req *iri.AttachVolumeRequest) (*iri.AttachVolumeResponse, error)
- func (r *FakeRuntimeService) CreateMachine(ctx context.Context, req *iri.CreateMachineRequest) (*iri.CreateMachineResponse, error)
- func (r *FakeRuntimeService) DeleteMachine(ctx context.Context, req *iri.DeleteMachineRequest) (*iri.DeleteMachineResponse, error)
- func (r *FakeRuntimeService) DetachNetworkInterface(ctx context.Context, req *iri.DetachNetworkInterfaceRequest) (*iri.DetachNetworkInterfaceResponse, error)
- func (r *FakeRuntimeService) DetachVolume(ctx context.Context, req *iri.DetachVolumeRequest) (*iri.DetachVolumeResponse, error)
- func (r *FakeRuntimeService) Exec(ctx context.Context, req *iri.ExecRequest) (*iri.ExecResponse, error)
- func (r *FakeRuntimeService) ListEvents(ctx context.Context, req *iri.ListEventsRequest) (*iri.ListEventsResponse, error)
- func (r *FakeRuntimeService) ListMachines(ctx context.Context, req *iri.ListMachinesRequest) (*iri.ListMachinesResponse, error)
- func (r *FakeRuntimeService) SetEvents(events []*FakeEvent)
- func (r *FakeRuntimeService) SetGetExecURL(f func(req *iri.ExecRequest) string)
- func (r *FakeRuntimeService) SetMachineClasses(machineClassStatus []*FakeMachineClassStatus)
- func (r *FakeRuntimeService) SetMachines(machines []*FakeMachine)
- func (r *FakeRuntimeService) Status(ctx context.Context, req *iri.StatusRequest) (*iri.StatusResponse, error)
- func (r *FakeRuntimeService) UpdateMachineAnnotations(ctx context.Context, req *iri.UpdateMachineAnnotationsRequest) (*iri.UpdateMachineAnnotationsResponse, error)
- func (r *FakeRuntimeService) UpdateMachinePower(ctx context.Context, req *iri.UpdateMachinePowerRequest) (*iri.UpdateMachinePowerResponse, error)
- func (r *FakeRuntimeService) Version(ctx context.Context, req *iri.VersionRequest) (*iri.VersionResponse, error)
- type FakeVolume
Constants ¶
This section is empty.
Variables ¶
View Source
var ( // FakeVersion is the version of the fake runtime. FakeVersion = "0.1.0" // FakeRuntimeName is the name of the fake runtime. FakeRuntimeName = "fakeRuntime" )
Functions ¶
This section is empty.
Types ¶
type FakeMachine ¶
type FakeMachineClassStatus ¶
type FakeMachineClassStatus struct {
iri.MachineClassStatus
}
type FakeNetworkInterface ¶
type FakeNetworkInterface struct {
iri.NetworkInterface
}
type FakeRuntimeService ¶
type FakeRuntimeService struct { sync.Mutex Machines map[string]*FakeMachine MachineClassStatus map[string]*FakeMachineClassStatus GetExecURL func(req *iri.ExecRequest) string Events []*FakeEvent }
func NewFakeRuntimeService ¶
func NewFakeRuntimeService() *FakeRuntimeService
func (*FakeRuntimeService) AttachNetworkInterface ¶
func (r *FakeRuntimeService) AttachNetworkInterface(ctx context.Context, req *iri.AttachNetworkInterfaceRequest) (*iri.AttachNetworkInterfaceResponse, error)
func (*FakeRuntimeService) AttachVolume ¶
func (r *FakeRuntimeService) AttachVolume(ctx context.Context, req *iri.AttachVolumeRequest) (*iri.AttachVolumeResponse, error)
func (*FakeRuntimeService) CreateMachine ¶
func (r *FakeRuntimeService) CreateMachine(ctx context.Context, req *iri.CreateMachineRequest) (*iri.CreateMachineResponse, error)
func (*FakeRuntimeService) DeleteMachine ¶
func (r *FakeRuntimeService) DeleteMachine(ctx context.Context, req *iri.DeleteMachineRequest) (*iri.DeleteMachineResponse, error)
func (*FakeRuntimeService) DetachNetworkInterface ¶
func (r *FakeRuntimeService) DetachNetworkInterface(ctx context.Context, req *iri.DetachNetworkInterfaceRequest) (*iri.DetachNetworkInterfaceResponse, error)
func (*FakeRuntimeService) DetachVolume ¶
func (r *FakeRuntimeService) DetachVolume(ctx context.Context, req *iri.DetachVolumeRequest) (*iri.DetachVolumeResponse, error)
func (*FakeRuntimeService) Exec ¶
func (r *FakeRuntimeService) Exec(ctx context.Context, req *iri.ExecRequest) (*iri.ExecResponse, error)
func (*FakeRuntimeService) ListEvents ¶ added in v0.2.0
func (r *FakeRuntimeService) ListEvents(ctx context.Context, req *iri.ListEventsRequest) (*iri.ListEventsResponse, error)
ListEvents implements machine.RuntimeService.
func (*FakeRuntimeService) ListMachines ¶
func (r *FakeRuntimeService) ListMachines(ctx context.Context, req *iri.ListMachinesRequest) (*iri.ListMachinesResponse, error)
func (*FakeRuntimeService) SetEvents ¶ added in v0.2.0
func (r *FakeRuntimeService) SetEvents(events []*FakeEvent)
func (*FakeRuntimeService) SetGetExecURL ¶
func (r *FakeRuntimeService) SetGetExecURL(f func(req *iri.ExecRequest) string)
func (*FakeRuntimeService) SetMachineClasses ¶
func (r *FakeRuntimeService) SetMachineClasses(machineClassStatus []*FakeMachineClassStatus)
func (*FakeRuntimeService) SetMachines ¶
func (r *FakeRuntimeService) SetMachines(machines []*FakeMachine)
func (*FakeRuntimeService) Status ¶
func (r *FakeRuntimeService) Status(ctx context.Context, req *iri.StatusRequest) (*iri.StatusResponse, error)
func (*FakeRuntimeService) UpdateMachineAnnotations ¶
func (r *FakeRuntimeService) UpdateMachineAnnotations(ctx context.Context, req *iri.UpdateMachineAnnotationsRequest) (*iri.UpdateMachineAnnotationsResponse, error)
func (*FakeRuntimeService) UpdateMachinePower ¶
func (r *FakeRuntimeService) UpdateMachinePower(ctx context.Context, req *iri.UpdateMachinePowerRequest) (*iri.UpdateMachinePowerResponse, error)
func (*FakeRuntimeService) Version ¶
func (r *FakeRuntimeService) Version(ctx context.Context, req *iri.VersionRequest) (*iri.VersionResponse, error)
type FakeVolume ¶
Click to show internal directories.
Click to hide internal directories.