Skip to content

docs: enable the testing API at build and server startup - #101443

Merged
aurorascharff merged 6 commits into
canaryfrom
codex/docs-testing-api-start
Nov 9, 2026
Merged

aurorascharff merged 6 commits into
canaryfrom
codex/docs-testing-api-start

Conversation

@aurorascharff

@aurorascharff aurorascharff commented Nov 9, 2026 •

Copy link
Copy Markdown
Contributor

Summary

Production tests need the Instant Navigation testing API enabled during both the build and server startup. With the flag set only during the build, initial page loads render request-time content during instant() tests while client navigations still pause.

The command examples now set the flag for both stages. The skill templates link to the config reference instead of repeating its explanation, while retaining their environment and server lifecycle instructions. The static-shell eval also passes the flag to its Playwright server.

Addresses agent feedback finding 5264.

Updated files

  • docs/01-app/03-api-reference/05-config/01-next-config-js/exposeTestingApiInProductionBuild.mdx
  • docs/01-app/02-guides/instant-navigation.mdx
  • skills/next-cache-components-optimizer/rig-template.md
  • skills/next-partial-prefetching-adoption/rig-template.md
  • skills/next-partial-prefetching-optimizer/rig-template.md
  • evals/evals/agent-050-optimize-static-shell/playwright.config.ts
  • evals/evals/agent-050-optimize-static-shell/instant-nav.rig.md

Verification

  • Reproduced the original setup with matching Next.js and @next/playwright versions 16.4.2 and 16.5.0-canary.45. Restarting the same build with the variable enabled fixed initial page locking on both versions.
  • Passed 12 Playwright tests on 16.5.0-canary.45. Each test checks that request-time content stays absent during the lock and appears after release. Initial page tests also inspect the response markup.
  • Tested the exact TypeScript and CommonJS config examples with manual startup. Verified both Playwright startup configurations against a production build, then checked development without an opt-in and a Webpack production build.
  • Confirmed that enabling the flag only at startup cannot add the client lock. That configuration also produced a document hydration error.
  • Formatting, scoped ESLint, and diff checks passed. The final style edit preserves all code blocks and executable commands.

Full repository lint previously failed on unused Rust task items in untouched files. Process cleanup also reported a sandbox permission error. The full agent-eval suite was not run.

@github-actions

github-actions Bot commented Nov 9, 2026 •

Copy link
Copy Markdown
Contributor

Tests Passed

Commit: 86c64dd
View workflow run

@github-actions github-actions Bot added Documentation Related to Next.js' official documentation. type: next labels Nov 9, 2026

@vercel vercel Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Vercel Agent reviewed ac3ff4d and found no issues.

@vercel vercel Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Vercel Agent reviewed 4c6f3bd and found no issues.

@aurorascharff
aurorascharff marked this pull request as ready for review November 9, 2026 10:10

@vercel vercel Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Vercel Agent reviewed d7de843 and found no issues.

@aurorascharff
aurorascharff enabled auto-merge (squash) November 9, 2026 10:31
@aurorascharff
aurorascharff merged commit 0cf3769 into canary Nov 9, 2026
57 checks passed
@aurorascharff
aurorascharff deleted the codex/docs-testing-api-start branch November 9, 2026 10:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Documentation Related to Next.js' official documentation. type: next

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant