From b301c9af60c182b433281291605677ddf7490276 Mon Sep 17 00:00:00 2001 From: Max Schmitt Date: Wed, 25 Jun 2025 09:04:30 +0000 Subject: [PATCH] test: fix installation tests under Node.js 24 --- tests/installation/npmTest.ts | 2 ++ tests/installation/playwright-cli-install-should-work.spec.ts | 1 - 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/tests/installation/npmTest.ts b/tests/installation/npmTest.ts index 09849077b5985..9360ce8a50170 100644 --- a/tests/installation/npmTest.ts +++ b/tests/installation/npmTest.ts @@ -107,6 +107,8 @@ export const test = _test const npmLines = [ `registry = ${registry.url()}/`, `cache = ${testInfo.outputPath('npm_cache')}`, + // Required after https://github.com/npm/cli/pull/8185. + 'replace-registry-host=never', ]; if (!allowGlobalInstall) { yarnLines.push(`prefix "${testInfo.outputPath('npm_global')}"`); diff --git a/tests/installation/playwright-cli-install-should-work.spec.ts b/tests/installation/playwright-cli-install-should-work.spec.ts index 9f909945a076d..ebbb22adb2230 100755 --- a/tests/installation/playwright-cli-install-should-work.spec.ts +++ b/tests/installation/playwright-cli-install-should-work.spec.ts @@ -38,7 +38,6 @@ test('install command should work', async ({ exec, checkInstalledSoftwareOnDisk await test.step('playwright install --list', async () => { const result = await exec('npx playwright install --list'); - console.log('result', result); expect.soft(result).toMatch(/Playwright version: \d+\.\d+/); expect.soft(result).toMatch(/chromium-\d+/); expect.soft(result).toMatch(/chromium_headless_shell-\d+/);