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: add best-effort support for MacOS beta versions (#7003)
Andrey Lushnikov3c7d2aae6a05
diff --git a/src/utils/registry.ts b/src/utils/registry.tsindex 57bb8f6197..c380ab99ba 100644--- a/src/utils/registry.ts+++ b/src/utils/registry.ts@@ -186,9 +186,16 @@ export const hostPlatform = ((): BrowserPlatform => {stdio: ['ignore', 'pipe', 'ignore']}).toString().trim() === '1';}- // We do not want to differentiate between minor big sur releases- // since they don't change core APIs so far.- const macVersion = major === 10 ? `${major}.${minor}` : `${major}`;+ const LAST_STABLE_MAC_MAJOR_VERSION = 11;+ // All new MacOS releases increase major version.+ let macVersion = `${major}`;+ if (major === 10) {+ // Pre-BigSur MacOS was increasing minor version every release.+ macVersion = `${major}.${minor}`;+ } else if (major > LAST_STABLE_MAC_MAJOR_VERSION) {+ // Best-effort support for MacOS beta versions.+ macVersion = LAST_STABLE_MAC_MAJOR_VERSION + '';+ }const archSuffix = arm64 ? '-arm64' : '';return `mac${macVersion}${archSuffix}` as BrowserPlatform;}