fake

package
v0.3.27 Latest Latest
Warning

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

Go to latest
Published: Aug 10, 2022 License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type MockLeaseService

type MockLeaseService struct {
	NonrenewableJobIds    []string
	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, reason string) error

Jump to

Keyboard shortcuts

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