diff --git a/src/e2e/puppeteer-environment.js b/src/e2e/puppeteer-environment.js index 1c3f4588727..134d0ed7224 100644 --- a/src/e2e/puppeteer-environment.js +++ b/src/e2e/puppeteer-environment.js @@ -17,6 +17,19 @@ class PuppeteerEnvironment extends JsDomEnvironment { // Note: this.global is not global to all test suites; it is sandboxed to a single test module, e.g. caret.ts this.global.browser = await puppeteer.launch({ headless: true, + // Disable Chrome features that crash GitHub Actions with "Protocol error (Target.createTarget): Target closed." + // See: https://stackoverflow.com/a/66994528/480608 + // List of Chromium switches: https://peter.sh/experiments/chromium-command-line-switches/ + args: [ + '--deterministic-fetch', + '--disable-dev-shm-usage', + '--disable-features=IsolateOrigins', + '--disable-setuid-sandbox', + '--disable-site-isolation-trials', + '--no-first-run', + '--no-sandbox', + '--no-zygote', + ], }) }