CodeVetter · Repo Unpack · Testing signals
sindresorhus/got
Tests and CI were inspected, not executed; no passing result or measured coverage is asserted. The inspected suite uses AVA, TypeScript assertions, local HTTP servers, and selected fake timers. Regression cases exercise transport identity, cross-origin behavior, buffering, caching, retries, and timeout budgets. The inventory is bounded, and explicit skipped or expected-failing cases limit what test presence establishes.
- AVA runs test/* excluding *.types.ts, treats TypeScript as modules, uses a ten-minute timeout, and disables worker threads; the script first runs XO and tsc --noEmit with tsx supplying ESM execution support.
- withServer creates a real HTTP server, optionally installs fake timers, builds a Got instance with that server's prefixUrl, and closes the server in finally; maintainer.md explicitly discourages nock because of process-wide interception.
- Promise tests assert request/response events, raw Uint8Array behavior with decompression disabled, and abort propagation through .json(); extend.types.ts checks inferred instance/default merges using expect-type under TypeScript checking.
- Cross-origin regressions distinguish POST 302 body removal from 307 body preservation with credential stripping; pagination tests check authorization removal and rejection of absolute Link URLs or in-place origin mutations.
- Retry tests assert a consumed generator produces only one upload and a replay error; request-timeout tests cover slow redirects, stalled downloads/uploads, and the intentional exclusion of initial beforeRequest hook time.
- Transport tests assert HTTP/2 pooled-socket reuse and separation by checkServerIdentity function identity; DnsCache tests inject resolvers to verify answer reuse and requested IPv4-family selection.
- Cache tests assert cacheable GET/POST reuse, QUERY bypass, 304 refresh of existing metadata, and uncached native FormData/Web-stream uploads; a separate test.failing documents missing new metadata from 304 responses.
- Inspection identified a skipped unhandled-body-error test and an expected-failing cache case; CI specifies Ubuntu Node 22/24/26 and npm test, while coverage is a separate c8 script with text/HTML/lcov output and is not invoked by the inspected workflow.