Skip to content

Playwright is a framework for Web Testing and Automation. It allows testing Chromium, Firefox and WebKit with a single API.

chore: update electron to v38 (#37411)

Yury Semikhatsky20023ab33a1d
diff --git a/package-lock.json b/package-lock.json
index 212aea52c5..548715024d 100644
--- a/package-lock.json
+++ b/package-lock.json
@@ -41,7 +41,7 @@
"concurrently": "^6.2.1",
"cross-env": "^7.0.3",
"dotenv": "^16.4.5",
- "electron": "^30.1.2",
+ "electron": "^38.1.0",
"esbuild": "^0.25.0",
"eslint": "^9.34.0",
"eslint-plugin-import": "^2.32.0",
@@ -3349,14 +3349,15 @@
"dev": true
},
"node_modules/electron": {
- "version": "30.5.1",
- "resolved": "https://registry.npmjs.org/electron/-/electron-30.5.1.tgz",
- "integrity": "sha512-AhL7+mZ8Lg14iaNfoYTkXQ2qee8mmsQyllKdqxlpv/zrKgfxz6jNVtcRRbQtLxtF8yzcImWdfTQROpYiPumdbw==",
+ "version": "38.1.0",
+ "resolved": "https://registry.npmjs.org/electron/-/electron-38.1.0.tgz",
+ "integrity": "sha512-ypA8GF8RU4HD5pA1sa0/2U8k+92EPP2c7pX+3XbgB760F7OmqrFXtYkOilVw6HfV4+lk88XxqigmsUKTACQYoQ==",
"dev": true,
"hasInstallScript": true,
+ "license": "MIT",
"dependencies": {
"@electron/get": "^2.0.0",
- "@types/node": "^20.9.0",
+ "@types/node": "^22.7.7",
"extract-zip": "^2.0.1"
},
"bin": {
@@ -3372,10 +3373,11 @@
"integrity": "sha512-TpvUNdha+X3ybfU78NoQatKvQEm1oq3lf2QbnmCEdw+Bd9RuIAY+hJTvq1avzHM0f7EJfnH3vbCnbzKzisc/9Q=="
},
"node_modules/electron/node_modules/@types/node": {
- "version": "20.19.13",
- "resolved": "https://registry.npmjs.org/@types/node/-/node-20.19.13.tgz",
- "integrity": "sha512-yCAeZl7a0DxgNVteXFHt9+uyFbqXGy/ShC4BlcHkoE0AfGXYv/BUiplV72DjMYXHDBXFjhvr6DD1NiRVfB4j8g==",
+ "version": "22.18.1",
+ "resolved": "https://registry.npmjs.org/@types/node/-/node-22.18.1.tgz",
+ "integrity": "sha512-rzSDyhn4cYznVG+PCzGe1lwuMYJrcBS1fc3JqSa2PvtABwWo+dZ1ij5OVok3tqfpEBCBoaR4d7upFJk73HRJDw==",
"dev": true,
+ "license": "MIT",
"dependencies": {
"undici-types": "~6.21.0"
}
@@ -3384,7 +3386,8 @@
"version": "6.21.0",
"resolved": "https://registry.npmjs.org/undici-types/-/undici-types-6.21.0.tgz",
"integrity": "sha512-iwDZqg0QAGrg9Rav5H4n0M64c3mkR59cJ6wQp+7C4nI0gsmExaedaYLNO44eT4AtBBwjbTiGPMlt2Md0T9H9JQ==",
- "dev": true
+ "dev": true,
+ "license": "MIT"
},
"node_modules/emoji-regex": {
"version": "8.0.0",
diff --git a/package.json b/package.json
index 92915e311e..ec56915d80 100644
--- a/package.json
+++ b/package.json
@@ -82,7 +82,7 @@
"concurrently": "^6.2.1",
"cross-env": "^7.0.3",
"dotenv": "^16.4.5",
- "electron": "^30.1.2",
+ "electron": "^38.1.0",
"esbuild": "^0.25.0",
"eslint": "^9.34.0",
"eslint-plugin-import": "^2.32.0",
diff --git a/tests/page/page-request-continue.spec.ts b/tests/page/page-request-continue.spec.ts
index 70b5d71667..1b8a0d5f27 100644
--- a/tests/page/page-request-continue.spec.ts
+++ b/tests/page/page-request-continue.spec.ts
@@ -55,12 +55,7 @@ it('should not allow to override unsafe HTTP headers', async ({ page, server, br
trailer: 'baz',
}
}).catch(e => e);
- if (isElectron) {
- // Electron doesn't send the request if the host header is overridden,
- // but doesn't throw an error either.
- expect(error).toBeFalsy();
- serverRequestPromise.catch(() => {});
- } else if (browserName === 'chromium') {
+ if (browserName === 'chromium' || isElectron) {
expect(error.message).toContain('Unsafe header');
serverRequestPromise.catch(() => {});
} else {