nock-graphql

JSON →
library 2.1.0 ·javascript
verified Jun 7, 2026

Nock-based GraphQL testing library (v2.1.0) that mocks GraphQL queries and mutations by intercepting actual HTTP calls via nock. Unlike Apollo's MockedProvider, it tests with real fetch requests, providing more realistic integration tests. Ships TypeScript types. Requires nock, cross-fetch, and graphql as peer dependencies. Suitable for Apollo Client and other GraphQL clients that use HTTP.