mirror of
https://github.com/microsoft/playwright.git
synced 2025-06-26 21:40:17 +00:00
chore: make installing non-hermetic browsers idempotent (#35791)
This commit is contained in:
parent
9b6fbcc452
commit
1924b51d3f
@ -1053,7 +1053,7 @@ export class Registry {
|
|||||||
const { embedderName } = getEmbedderName();
|
const { embedderName } = getEmbedderName();
|
||||||
if (!getAsBooleanFromENV('CI') && !executable._isHermeticInstallation && !forceReinstall && executable.executablePath(embedderName)) {
|
if (!getAsBooleanFromENV('CI') && !executable._isHermeticInstallation && !forceReinstall && executable.executablePath(embedderName)) {
|
||||||
const command = buildPlaywrightCLICommand(embedderName, 'install --force ' + executable.name);
|
const command = buildPlaywrightCLICommand(embedderName, 'install --force ' + executable.name);
|
||||||
throw new Error('\n' + wrapInASCIIBox([
|
process.stderr.write('\n' + wrapInASCIIBox([
|
||||||
`ATTENTION: "${executable.name}" is already installed on the system!`,
|
`ATTENTION: "${executable.name}" is already installed on the system!`,
|
||||||
``,
|
``,
|
||||||
`"${executable.name}" installation is not hermetic; installing newer version`,
|
`"${executable.name}" installation is not hermetic; installing newer version`,
|
||||||
@ -1067,7 +1067,8 @@ export class Registry {
|
|||||||
` ${command}`,
|
` ${command}`,
|
||||||
``,
|
``,
|
||||||
`<3 Playwright Team`,
|
`<3 Playwright Team`,
|
||||||
].join('\n'), 1));
|
].join('\n'), 1) + '\n\n');
|
||||||
|
return;
|
||||||
}
|
}
|
||||||
await executable._install();
|
await executable._install();
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user