* clear job from interface
({ cid, passed, retries }: { cid: string, passed: boolean, retries: number })
| 199 | * clear job from interface |
| 200 | */ |
| 201 | clearJob({ cid, passed, retries }: { cid: string, passed: boolean, retries: number }) { |
| 202 | const job = this._jobs.get(cid) |
| 203 | |
| 204 | this._jobs.delete(cid) |
| 205 | const retryAttempts = this._specFileRetries - retries |
| 206 | const retry = !passed && retries > 0 |
| 207 | if (!retry) { |
| 208 | this.result.finished++ |
| 209 | } |
| 210 | |
| 211 | if (job && job.hasTests === false) { |
| 212 | return this.onSpecSkip(cid, job) |
| 213 | } |
| 214 | |
| 215 | if (passed) { |
| 216 | this.result.passed++ |
| 217 | this.onSpecPass(cid, job, retryAttempts) |
| 218 | } else if (retry) { |
| 219 | this.totalWorkerCnt++ |
| 220 | this.result.retries++ |
| 221 | this.onSpecRetry(cid, job, retryAttempts) |
| 222 | } else { |
| 223 | this.result.failed++ |
| 224 | this.onSpecFailure(cid, job, retryAttempts) |
| 225 | } |
| 226 | } |
| 227 | |
| 228 | /** |
| 229 | * for testing purposes call console log in a static method |
nothing calls this directly
no test coverage detected