Documentation
¶
Index ¶
- type MockLeaseService
- func (ls *MockLeaseService) AssertReportDoneCalledOnceWith(t *testing.T, expected []string)
- func (ls *MockLeaseService) RenewJobLeases(jobs []*job.RunningJob) ([]*job.RunningJob, error)
- func (ls *MockLeaseService) ReportDone(jobIds []string) error
- func (ls *MockLeaseService) RequestJobLeases(availableResource *common.ComputeResources, nodes []api.NodeInfo, ...) ([]*api.Job, error)
- func (ls *MockLeaseService) ReturnLease(pod *v1.Pod) error
- type SyncFakeClusterContext
- func (c *SyncFakeClusterContext) AddAnnotation(pod *v1.Pod, annotations map[string]string) error
- func (c *SyncFakeClusterContext) AddPodEventHandler(handler cache.ResourceEventHandlerFuncs)
- func (c *SyncFakeClusterContext) DeleteIngress(ingress *networking.Ingress) error
- func (c *SyncFakeClusterContext) DeletePods(pods []*v1.Pod)
- func (c *SyncFakeClusterContext) DeleteService(service *v1.Service) error
- func (c *SyncFakeClusterContext) GetActiveBatchPods() ([]*v1.Pod, error)
- func (c *SyncFakeClusterContext) GetAllPods() ([]*v1.Pod, error)
- func (c *SyncFakeClusterContext) GetBatchPods() ([]*v1.Pod, error)
- func (c *SyncFakeClusterContext) GetClusterId() string
- func (c *SyncFakeClusterContext) GetClusterPool() string
- func (c *SyncFakeClusterContext) GetIngresses(pod *v1.Pod) ([]*networking.Ingress, error)
- func (c *SyncFakeClusterContext) GetNode(nodeName string) (*v1.Node, error)
- func (c *SyncFakeClusterContext) GetNodeStatsSummary(node *v1.Node) (*v1alpha1.Summary, error)
- func (c *SyncFakeClusterContext) GetNodes() ([]*v1.Node, error)
- func (c *SyncFakeClusterContext) GetPodEvents(pod *v1.Pod) ([]*v1.Event, error)
- func (c *SyncFakeClusterContext) GetServices(pod *v1.Pod) ([]*v1.Service, error)
- func (*SyncFakeClusterContext) Stop()
- func (c *SyncFakeClusterContext) SubmitIngress(ingress *networking.Ingress) (*networking.Ingress, error)
- func (c *SyncFakeClusterContext) SubmitPod(pod *v1.Pod, owner string, ownerGroups []string) (*v1.Pod, error)
- func (c *SyncFakeClusterContext) SubmitService(service *v1.Service) (*v1.Service, error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type MockLeaseService ¶
type MockLeaseService struct { ReturnLeaseCalls int RequestJobLeasesCalls int ReportDoneCalls int ReturnLeaseArg *v1.Pod ReportDoneArg []string }
func NewMockLeaseService ¶
func NewMockLeaseService() *MockLeaseService
func (*MockLeaseService) AssertReportDoneCalledOnceWith ¶
func (ls *MockLeaseService) AssertReportDoneCalledOnceWith(t *testing.T, expected []string)
func (*MockLeaseService) RenewJobLeases ¶
func (ls *MockLeaseService) RenewJobLeases(jobs []*job.RunningJob) ([]*job.RunningJob, error)
func (*MockLeaseService) ReportDone ¶
func (ls *MockLeaseService) ReportDone(jobIds []string) error
func (*MockLeaseService) RequestJobLeases ¶
func (ls *MockLeaseService) RequestJobLeases(availableResource *common.ComputeResources, nodes []api.NodeInfo, leasedResourceByQueue map[string]common.ComputeResources) ([]*api.Job, error)
func (*MockLeaseService) ReturnLease ¶
func (ls *MockLeaseService) ReturnLease(pod *v1.Pod) error
type SyncFakeClusterContext ¶
func NewSyncFakeClusterContext ¶
func NewSyncFakeClusterContext() *SyncFakeClusterContext
func (*SyncFakeClusterContext) AddAnnotation ¶
func (*SyncFakeClusterContext) AddPodEventHandler ¶
func (c *SyncFakeClusterContext) AddPodEventHandler(handler cache.ResourceEventHandlerFuncs)
func (*SyncFakeClusterContext) DeleteIngress ¶ added in v0.2.3
func (c *SyncFakeClusterContext) DeleteIngress(ingress *networking.Ingress) error
func (*SyncFakeClusterContext) DeletePods ¶
func (c *SyncFakeClusterContext) DeletePods(pods []*v1.Pod)
func (*SyncFakeClusterContext) DeleteService ¶
func (c *SyncFakeClusterContext) DeleteService(service *v1.Service) error
func (*SyncFakeClusterContext) GetActiveBatchPods ¶
func (c *SyncFakeClusterContext) GetActiveBatchPods() ([]*v1.Pod, error)
func (*SyncFakeClusterContext) GetAllPods ¶
func (c *SyncFakeClusterContext) GetAllPods() ([]*v1.Pod, error)
func (*SyncFakeClusterContext) GetBatchPods ¶
func (c *SyncFakeClusterContext) GetBatchPods() ([]*v1.Pod, error)
func (*SyncFakeClusterContext) GetClusterId ¶
func (c *SyncFakeClusterContext) GetClusterId() string
func (*SyncFakeClusterContext) GetClusterPool ¶
func (c *SyncFakeClusterContext) GetClusterPool() string
func (*SyncFakeClusterContext) GetIngresses ¶ added in v0.2.3
func (c *SyncFakeClusterContext) GetIngresses(pod *v1.Pod) ([]*networking.Ingress, error)
func (*SyncFakeClusterContext) GetNode ¶ added in v0.2.6
func (c *SyncFakeClusterContext) GetNode(nodeName string) (*v1.Node, error)
func (*SyncFakeClusterContext) GetNodeStatsSummary ¶
func (*SyncFakeClusterContext) GetNodes ¶
func (c *SyncFakeClusterContext) GetNodes() ([]*v1.Node, error)
func (*SyncFakeClusterContext) GetPodEvents ¶
func (*SyncFakeClusterContext) GetServices ¶ added in v0.2.3
func (*SyncFakeClusterContext) Stop ¶
func (*SyncFakeClusterContext) Stop()
func (*SyncFakeClusterContext) SubmitIngress ¶ added in v0.2.3
func (c *SyncFakeClusterContext) SubmitIngress(ingress *networking.Ingress) (*networking.Ingress, error)
func (*SyncFakeClusterContext) SubmitService ¶
Click to show internal directories.
Click to hide internal directories.