Playwright is a framework for Web Testing and Automation. It allows testing Chromium, Firefox and WebKit with a single API.
TypeScript automationchromechromiume2e-testingelectronend-to-end-testingfirefoxjavascriptplaywrighttesttest-automationtestingtesting-toolswebwebkit
fix: point to the right cli program export (#29715)
Pavel Feldmand48aadac7e4c
diff --git a/packages/playwright-chromium/cli.js b/packages/playwright-chromium/cli.jsindex 86adb86a84..f46d8b409e 100755--- a/packages/playwright-chromium/cli.js+++ b/packages/playwright-chromium/cli.js@@ -15,5 +15,5 @@* limitations under the License.*/-const { program } = require('playwright-core/lib/program');+const { program } = require('playwright-core/lib/cli/program');program.parse(process.argv);diff --git a/packages/playwright-firefox/cli.js b/packages/playwright-firefox/cli.jsindex 86adb86a84..f46d8b409e 100755--- a/packages/playwright-firefox/cli.js+++ b/packages/playwright-firefox/cli.js@@ -15,5 +15,5 @@* limitations under the License.*/-const { program } = require('playwright-core/lib/program');+const { program } = require('playwright-core/lib/cli/program');program.parse(process.argv);diff --git a/packages/playwright-webkit/cli.js b/packages/playwright-webkit/cli.jsindex 86adb86a84..f46d8b409e 100755--- a/packages/playwright-webkit/cli.js+++ b/packages/playwright-webkit/cli.js@@ -15,5 +15,5 @@* limitations under the License.*/-const { program } = require('playwright-core/lib/program');+const { program } = require('playwright-core/lib/cli/program');program.parse(process.argv);diff --git a/tests/installation/playwright-cli-install-should-work.spec.ts b/tests/installation/playwright-cli-install-should-work.spec.tsindex c6d84cedae..e056e61138 100755--- a/tests/installation/playwright-cli-install-should-work.spec.ts+++ b/tests/installation/playwright-cli-install-should-work.spec.ts@@ -89,3 +89,9 @@ test('subsequent installs works', async ({ exec }) => {// of UnhandledPromiseRejection.await exec('node --unhandled-rejections=strict', path.join('node_modules', '@playwright', 'browser-chromium', 'install.js'));});++test('install playwright-chromium should work', async ({ exec, installedSoftwareOnDisk }) => {+ await exec('npm i playwright-chromium');+ await exec('npx playwright install chromium');+ await exec('node sanity.js playwright-chromium chromium');+});