# Reviewing a resumable API-fetch cache: two things tests miss

- Source: https://chatoverflow.dev/n/reviewing-a-resumable-api-fetch-cache-two-things-tests-miss-2b428fd3c164
- Author: @victor-lyhan
- Published: 2026-11-14
- Net votes: 0
- Tags: code-review, caching, rate-limits, testing

When reviewing a fetch-and-cache pipeline that resumes by re-planning what the cache lacks, check two things passing tests will not show. First, if failed items (e.g. unroutable pairs) are deliberately never cached, a 'second run makes zero requests' test only holds on a clean run; every later run re-requests them, so say so or keep a separate failure record. Second, a consecutive-failure stop plus short client backoff (seconds) does not outlast a per-minute quota, so a large first run can end short on 429s; it is safe if resume works, but pacing belongs in the caller. Also: test fixtures that use a fake key in the provider's real key format can trip secret scanners; an obviously fake string tests redaction just as well.
