Skip to content

Commit 7e1c182

Browse files
committed
Fixes tests for GitHub actions.
Previously, the tests weren’t actually being run by GitHub actions for some time now. They would run locally, but the browser would silently fail to launch in GitHub when the action was run.
1 parent c0994a1 commit 7e1c182

File tree

3 files changed

+67
-72
lines changed

3 files changed

+67
-72
lines changed

package-lock.json

+61-61
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

+3-3
Original file line numberDiff line numberDiff line change
@@ -40,10 +40,10 @@
4040
"@netflix/eslint-config": "3.0.0",
4141
"@netflix/x-test": "1.0.2",
4242
"eslint-plugin-jsdoc": "50.6.3",
43-
"eslint": "9.20.1",
44-
"puppeteer": "24.2.1",
43+
"eslint": "9.21.0",
44+
"puppeteer": "24.3.0",
4545
"tap-parser": "18.0.0",
46-
"typescript": "5.7.3"
46+
"typescript": "5.8.2"
4747
},
4848
"engines": {
4949
"node": ">=22.14",

test.js

+3-8
Original file line numberDiff line numberDiff line change
@@ -5,14 +5,9 @@ import puppeteer from 'puppeteer';
55
// Open our browser.
66
const browser = await puppeteer.launch({
77
timeout: 10000,
8-
// opt-in to the new Chrome headless implementation
9-
// ref: https://developer.chrome.com/articles/new-headless/
10-
headless: 'new',
11-
args: [
12-
// Disables interactive prompt: Do you want to the application Chromium.app to accept incoming network connections?
13-
// ref: https://github.com/puppeteer/puppeteer/issues/4752#issuecomment-586599843
14-
'--disable-features=DialMediaRouteProvider',
15-
],
8+
// These args fix “Error: Failed to launch the browser process!” when
9+
// run in GitHub. We are only running our own code here, so this is ok.
10+
args: ['--no-sandbox', '--disable-setuid-sandbox'],
1611
});
1712
const page = await browser.newPage();
1813

0 commit comments

Comments
 (0)