Gatsby Testing: Complete Framework and Plugin Test Suite
The Gatsby testing ecosystem demonstrates a comprehensive approach to quality assurance, leveraging Jest as the primary testing framework alongside Cypress for end-to-end testing. The test suite encompasses unit, integration, and E2E tests, with particular emphasis on validating core Gatsby functionality like font preloading, WordPress content processing, and GraphQL operations. The repository showcases real-world testing patterns for plugin development and core framework features. Qodo Tests Hub provides developers with deep insights into Gatsby's testing practices by organizing and analyzing its diverse test implementations. Through the platform, developers can explore practical examples of testing GraphQL operations, plugin functionality, and integration scenarios. This helps teams understand and adopt Gatsby's testing patterns, from basic unit tests to complex end-to-end validations, while learning from production-grade implementations.
Path | Test Type | Language | Description |
---|---|---|---|
deprecated-packages/gatsby-recipes/src/providers/fs/file.test.js |
unit
|
javascript | This Jest unit test verifies file resource provider functionality in Gatsby Recipes, including local and remote file operations. |
deprecated-packages/gatsby-recipes/src/providers/gatsby/shadow-file.test.js |
unit
|
javascript | This Jest unit test verifies Gatsby’s theme shadowing functionality for file path resolution and component overrides. |
deprecated-packages/gatsby-recipes/src/renderer/render.test.js |
unit
|
javascript | This JavaScript unit test verifies the rendering functionality and metadata handling of Gatsby Recipes components. |
deprecated-packages/gatsby-recipes/src/providers/gatsby/utils/build-plugin-node.test.js |
unit
|
javascript | This Jest unit test verifies the transformation of Gatsby plugin configurations into AST nodes and generated code output. |
deprecated-packages/gatsby-recipes/src/providers/npm/package-json.test.js |
unit
|
javascript | This Jest unit test verifies package.json manipulation functionality in Gatsby Recipes’ PackageJson resource module. |
deprecated-packages/gatsby-recipes/src/providers/utils/get-graphql-fields.test.js |
unit
|
javascript | This Jest unit test verifies the extraction and transformation of GraphQL fields from type definitions in Gatsby Recipes. |
deprecated-packages/gatsby-recipes/src/recipe-machine/index.test.js |
unit
|
javascript | This Jest unit test verifies the state machine implementation for Gatsby Recipes, including plan creation and file resource handling. |
deprecated-packages/gatsby-recipes/src/renderer/index.test.js |
unit
|
javascript | This Jest unit test verifies the Gatsby Recipes renderer’s ability to process MDX content, handle JSX components, and manage configuration steps. |
e2e-tests/development-runtime/playwright/gatsby-script-off-main-thread.spec.ts |
e2e
|
typescript | This Playwright e2e test verifies off-main-thread script loading and execution behavior in Gatsby applications using Partytown integration. |
e2e-tests/production-runtime/playwright/gatsby-script-off-main-thread.spec.ts |
e2e
|
typescript | This Playwright e2e test verifies off-main-thread script loading and execution behaviors in Gatsby applications using Partytown integration. |