From 8c1b725c672019586273232bc3660c5f1c46b63b Mon Sep 17 00:00:00 2001 From: Dmitry Gozman Date: Fri, 27 Sep 2024 15:58:55 +0100 Subject: [PATCH] docs: release notes for 1.48 --- docs/src/release-notes-csharp.md | 40 +++++++++++++++++++++++++++++++ docs/src/release-notes-java.md | 39 ++++++++++++++++++++++++++++++ docs/src/release-notes-js.md | 41 ++++++++++++++++++++++++++++++++ docs/src/release-notes-python.md | 40 +++++++++++++++++++++++++++++++ 4 files changed, 160 insertions(+) diff --git a/docs/src/release-notes-csharp.md b/docs/src/release-notes-csharp.md index 994d047794bfee..7e34669d895ea3 100644 --- a/docs/src/release-notes-csharp.md +++ b/docs/src/release-notes-csharp.md @@ -4,6 +4,46 @@ title: "Release notes" toc_max_heading_level: 2 --- + +## Version 1.48 + +### WebSocket routing + +New methods [`method: Page.routeWebSocket`] and [`method: BrowserContext.routeWebSocket`] allow to intercept, modify and mock WebSocket connections initiated in the page. Below is a simple example that mocks WebSocket communication by responding to a `"request"` with a `"response"`. + +```csharp +await page.RouteWebSocketAsync("/ws", ws => { + ws.OnMessage(message => { + if (message == "request") + ws.Send("response"); + }); +}); +``` + +See [WebSocketRoute] for more details. + +### UI updates + +- New "copy" buttons for annotations and test location in the HTML report. +- Route method calls like [`method: Route.fulfill`] are not shown in the report and trace viewer anymore. You can see which network requests were routed in the network tab instead. +- New "Copy as cURL" and "Copy as fetch" buttons for requests in the network tab. + +### Miscellaneous + +- New method [`method: Page.requestGC`] may help detect memory leaks. + +### Browser Versions + +- Chromium 130.0.6723.19 +- Mozilla Firefox 130.0 +- WebKit 18.0 + +This version was also tested against the following stable channels: + +- Google Chrome 129 +- Microsoft Edge 129 + + ## Version 1.47 ### Network Tab improvements diff --git a/docs/src/release-notes-java.md b/docs/src/release-notes-java.md index c50d5a67c4b672..c0b9bdd498703e 100644 --- a/docs/src/release-notes-java.md +++ b/docs/src/release-notes-java.md @@ -4,6 +4,45 @@ title: "Release notes" toc_max_heading_level: 2 --- +## Version 1.48 + +### WebSocket routing + +New methods [`method: Page.routeWebSocket`] and [`method: BrowserContext.routeWebSocket`] allow to intercept, modify and mock WebSocket connections initiated in the page. Below is a simple example that mocks WebSocket communication by responding to a `"request"` with a `"response"`. + +```java +page.routeWebSocket("/ws", ws -> { + ws.onMessage(message -> { + if ("request".equals(message)) + ws.send("response"); + }); +}); +``` + +See [WebSocketRoute] for more details. + +### UI updates + +- New "copy" buttons for annotations and test location in the HTML report. +- Route method calls like [`method: Route.fulfill`] are not shown in the report and trace viewer anymore. You can see which network requests were routed in the network tab instead. +- New "Copy as cURL" and "Copy as fetch" buttons for requests in the network tab. + +### Miscellaneous + +- New method [`method: Page.requestGC`] may help detect memory leaks. + +### Browser Versions + +- Chromium 130.0.6723.19 +- Mozilla Firefox 130.0 +- WebKit 18.0 + +This version was also tested against the following stable channels: + +- Google Chrome 129 +- Microsoft Edge 129 + + ## Version 1.47 ### Network Tab improvements diff --git a/docs/src/release-notes-js.md b/docs/src/release-notes-js.md index 4676a9dfb10fcf..3613487c078c83 100644 --- a/docs/src/release-notes-js.md +++ b/docs/src/release-notes-js.md @@ -6,6 +6,47 @@ toc_max_heading_level: 2 import LiteYouTube from '@site/src/components/LiteYouTube'; +## Version 1.48 + +### WebSocket routing + +New methods [`method: Page.routeWebSocket`] and [`method: BrowserContext.routeWebSocket`] allow to intercept, modify and mock WebSocket connections initiated in the page. Below is a simple example that mocks WebSocket communication by responding to a `"request"` with a `"response"`. + +```js +await page.routeWebSocket('/ws', ws => { + ws.onMessage(message => { + if (message === 'request') + ws.send('response'); + }); +}); +``` + +See [WebSocketRoute] for more details. + +### UI updates + +- New "copy" buttons for annotations and test location in the HTML report. +- Route method calls like [`method: Route.fulfill`] are not shown in the report and trace viewer anymore. You can see which network requests were routed in the network tab instead. +- New "Copy as cURL" and "Copy as fetch" buttons for requests in the network tab. + +### Miscellaneous + +- Option [`option: APIRequestContext.fetch.form`] and similar ones now accept [FormData](https://developer.mozilla.org/en-US/docs/Web/API/FormData). +- New method [`method: Page.requestGC`] may help detect memory leaks. +- New option [`option: Test.step.location`] to pass custom step location. + +### Browser Versions + +- Chromium 130.0.6723.19 +- Mozilla Firefox 130.0 +- WebKit 18.0 + +This version was also tested against the following stable channels: + +- Google Chrome 129 +- Microsoft Edge 129 + + ## Version 1.47 ### Network Tab improvements diff --git a/docs/src/release-notes-python.md b/docs/src/release-notes-python.md index 033c2697505a12..75e26e416645c6 100644 --- a/docs/src/release-notes-python.md +++ b/docs/src/release-notes-python.md @@ -4,6 +4,46 @@ title: "Release notes" toc_max_heading_level: 2 --- +## Version 1.48 + +### WebSocket routing + +New methods [`method: Page.routeWebSocket`] and [`method: BrowserContext.routeWebSocket`] allow to intercept, modify and mock WebSocket connections initiated in the page. Below is a simple example that mocks WebSocket communication by responding to a `"request"` with a `"response"`. + +```python +def message_handler(ws, message): + if message == "request": + ws.send("response") + +page.route_web_socket("/ws", lambda ws: ws.on_message( + lambda message: message_handler(ws, message) +)) +``` + +See [WebSocketRoute] for more details. + +### UI updates + +- New "copy" buttons for annotations and test location in the HTML report. +- Route method calls like [`method: Route.fulfill`] are not shown in the report and trace viewer anymore. You can see which network requests were routed in the network tab instead. +- New "Copy as cURL" and "Copy as fetch" buttons for requests in the network tab. + +### Miscellaneous + +- New method [`method: Page.requestGC`] may help detect memory leaks. + +### Browser Versions + +- Chromium 130.0.6723.19 +- Mozilla Firefox 130.0 +- WebKit 18.0 + +This version was also tested against the following stable channels: + +- Google Chrome 129 +- Microsoft Edge 129 + + ## Version 1.47 ### Network Tab improvements