(r, attempt)
| 377 | }; |
| 378 | const MAX_RETRIES = 3; |
| 379 | const shouldRetryLocal = (r, attempt) => { |
| 380 | if (r.exitCode === 0) return false; |
| 381 | if (hasNumerousPermissionDeniedIssues(r.output)) return false; |
| 382 | if (isCAPIQuotaExceededError(r.output)) return false; |
| 383 | return attempt < MAX_RETRIES && r.hasOutput; |
| 384 | }; |
| 385 | expect(shouldRetryLocal(result, 0)).toBe(true); |
| 386 | }); |
| 387 |
no test coverage detected