chore: make local docker build work on branch (#17896)

Branch does not pass `isDevelopmentMode` check because it does not have
a version ending with `-next`. Therefore, `env.PWTEST_DOCKER_BASE_IMAGE`
is ignored which leads to the pull of non-existent image.
This commit is contained in:
Dmitry Gozman 2022-10-07 06:55:26 -07:00 committed by GitHub
parent c81af6b2bd
commit 51a8807f6b
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -76,7 +76,7 @@ async function buildPlaywrightImage() {
await checkDockerEngineIsRunningOrDie();
const isDevelopmentMode = getPlaywrightVersion().includes('next');
let baseImageName = `mcr.microsoft.com/playwright:v${getPlaywrightVersion()}-${VRT_IMAGE_DISTRO}`;
let baseImageName = process.env.PWTEST_DOCKER_BASE_IMAGE || `mcr.microsoft.com/playwright:v${getPlaywrightVersion()}-${VRT_IMAGE_DISTRO}`;
// 1. Build or pull base image.
if (isDevelopmentMode) {
// Use our docker build scripts in development mode!