diff --git a/packages/next/src/bin/next.ts b/packages/next/src/bin/next.ts index e95561b5d7555..8acbca5cec0f1 100755 --- a/packages/next/src/bin/next.ts +++ b/packages/next/src/bin/next.ts @@ -169,7 +169,6 @@ program '--experimental-upload-trace, ', 'Reports a subset of the debugging trace to a remote HTTP URL. Includes sensitive data.' ) - .addOption(new Option('--experimental-test-proxy').hideHelp()) .action((directory, options, { _optionValueSources }) => { const portSource = _optionValueSources.port import('../cli/next-dev.js').then((mod) => @@ -313,7 +312,6 @@ program 'Specify the maximum amount of milliseconds to wait before closing inactive connections.' ).argParser(myParseInt) ) - .addOption(new Option('--experimental-test-proxy').hideHelp()) .action((directory, options) => import('../cli/next-start.js').then((mod) => mod.nextStart(options, directory) diff --git a/packages/next/src/experimental/testmode/playwright/README.md b/packages/next/src/experimental/testmode/playwright/README.md index 1034babcd581b..1f31b590f3c59 100644 --- a/packages/next/src/experimental/testmode/playwright/README.md +++ b/packages/next/src/experimental/testmode/playwright/README.md @@ -4,6 +4,16 @@ You have a Next.js project. +### Update `next.config.js` + +```javascript +module.exports = { + experimental: { + testProxy: true, + }, +} +``` + ### Install `@playwright/test` in your project ```sh @@ -25,7 +35,7 @@ import { defineConfig } from 'next/experimental/testmode/playwright' export default defineConfig({ webServer: { - command: 'npm dev -- --experimental-test-proxy', + command: 'npm dev', url: 'http://localhost:3000', }, })