JobStoreMock
Hierarchy
- JobStoreMock
Implements
Index
Constructors
Properties
Methods
- addJob
- deleteAllJobs
- getActiveMarkedJobs
- getJobs
- getJobsForWorker
- getNextJob
- removeJob
- removeJobsByWorkerName
- updateJob
Constructors
constructor
+ new JobStoreMock(): JobStoreMock
Defined in utils/JobQueueMock.ts:5
Returns: JobStoreMock
Properties
jobs
• jobs: RawJob[] = []
Defined in utils/JobQueueMock.ts:5
Methods
addJob
▸ addJob(job
: RawJob): Promise<void>
Implementation of JobStore
Defined in utils/JobQueueMock.ts:8
Parameters:
Name | Type |
---|---|
job | RawJob |
Returns: Promise<void>
deleteAllJobs
▸ deleteAllJobs(): Promise<void>
Implementation of JobStore
Defined in utils/JobQueueMock.ts:44
Returns: Promise<void>
getActiveMarkedJobs
▸ getActiveMarkedJobs(): Promise<RawJob[]>
Implementation of JobStore
Defined in utils/JobQueueMock.ts:15
Returns: Promise<RawJob[]>
getJobs
▸ getJobs(): Promise<RawJob[]>
Implementation of JobStore
Defined in utils/JobQueueMock.ts:12
Returns: Promise<RawJob[]>
getJobsForWorker
▸ getJobsForWorker(name
: string, count
: number): Promise<RawJob[]>
Implementation of JobStore
Defined in utils/JobQueueMock.ts:25
Parameters:
Name | Type |
---|---|
name | string |
count | number |
Returns: Promise<RawJob[]>
getNextJob
▸ getNextJob(): Promise<RawJob>
Implementation of JobStore
Defined in utils/JobQueueMock.ts:19
Returns: Promise<RawJob>
removeJob
▸ removeJob(rawJob
: RawJob): void
Implementation of JobStore
Defined in utils/JobQueueMock.ts:38
Parameters:
Name | Type |
---|---|
rawJob | RawJob |
Returns: void
removeJobsByWorkerName
▸ removeJobsByWorkerName(workerName
: string): void
Implementation of JobStore
Defined in utils/JobQueueMock.ts:41
Parameters:
Name | Type |
---|---|
workerName | string |
Returns: void
updateJob
▸ updateJob(rawJob
: RawJob): void
Implementation of JobStore
Defined in utils/JobQueueMock.ts:30
Parameters:
Name | Type |
---|---|
rawJob | RawJob |
Returns: void