cherry-pick(#29715): fix: point to the right cli program export

This commit is contained in:
Pavel Feldman 2024-02-28 14:05:42 -08:00
parent e7f0635c17
commit 84780b1b75
4 changed files with 9 additions and 3 deletions

View file

@ -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);

View file

@ -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);

View file

@ -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);

View file

@ -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');
});