137 Commits

Author SHA1 Message Date
Dmitry Gozman
f78918ab03
chore: fix removeInitScript implementation (#36159) 2025-06-02 22:14:35 +01:00
Dmitry Gozman
70d64a2978
chore: chain routes from multiple connections (#36105) 2025-05-30 15:59:24 +01:00
Dmitry Gozman
e58f076d42
chore: cleanup more state upon disconnect (#36132) 2025-05-30 14:59:20 +01:00
Pavel Feldman
0ab13695e7
chore: allow describing the aria refs (#36071) 2025-05-26 12:32:58 -07:00
Dmitry Gozman
d1eb9589f8
chore: remove bindings and init scripts upon client disconnect (#36064) 2025-05-26 10:33:00 +01:00
Pavel Feldman
a15e94aa3f
chore: two-line trace view (3) (#36058) 2025-05-22 19:00:33 -07:00
Pavel Feldman
e0365747ce
chore: two-line trace view (2) (#36055) 2025-05-22 14:50:54 -07:00
Dmitry Gozman
fd7d249ed4
chore: cleanup runtimeGuid and other builtins bits (#36035) 2025-05-21 22:10:41 +01:00
Dmitry Gozman
6af41232b8
chore: evaluate UtilityScript lazily (#36019) 2025-05-21 14:45:50 +01:00
Dmitry Gozman
6532d7c7d6
chore: move timeout handling to the client (#35988) 2025-05-20 15:51:33 +01:00
Dmitry Gozman
d57f194693
chore: extract page bindings controller from UtilityScript (#35996) 2025-05-20 13:43:46 +01:00
Dmitry Gozman
2a5d83a623
chore: introduce Page.viewportSizeChanged event (#35994) 2025-05-19 21:39:41 +01:00
Dmitry Gozman
bcd2f10dfd
chore: install playwright binding lazily (#35976) 2025-05-16 21:21:44 +01:00
Dmitry Gozman
0898662b4d
chore: use runImmediately option to ensure init script runs once (#35975) 2025-05-16 19:46:05 +01:00
Simon Knott
b9055fe9fc
chore(ai snapshot): dont error on navigating childframe (#35951) 2025-05-14 17:38:00 +02:00
Pavel Feldman
a6b4b222ed
chore: upstream the frame tree snapshot (#35917) 2025-05-09 16:15:16 -07:00
Dmitry Gozman
42ade54975
chore: use utilityScript handle in bindings (#35824) 2025-05-01 15:14:17 +01:00
Yury Semikhatsky
baeb065e9e
chore: remove underscore from public members in page (#35820) 2025-04-30 18:57:59 -07:00
Dmitry Gozman
6d3ee50a02
chore: remove setUnderTest (#35810) 2025-04-30 15:52:00 +01:00
Dmitry Gozman
3b0135411e
chore: inject builtins through esbuild (#35800) 2025-04-29 20:07:06 +01:00
Pavel Feldman
3371fb9bea
chore: do not leak pw internals (#35721) 2025-04-23 21:53:17 -07:00
Dmitry Gozman
c9a1ad4d8d
chore: use a singleton "builtins" instead of passing it around (#35493) 2025-04-10 09:30:39 +01:00
Yury Semikhatsky
f9d9c5c512
chore: merge server/isomorphic into utils/isomorphic (#35480) 2025-04-03 13:36:50 -07:00
Dmitry Gozman
0467c28722
chore: builtins (#35197) 2025-03-25 13:49:28 +00:00
Yury Semikhatsky
962a752832
chore: contain remote objects to browser-specific code (#34890) 2025-02-21 16:52:39 -08:00
Yury Semikhatsky
145b6bf4fe
chore: browser independent setInputFiles implementation (#34808) 2025-02-14 16:44:27 -08:00
Pavel Feldman
8b28e637c8
chrome: remove state from isomorphic utils (#34795) 2025-02-14 15:10:50 -08:00
Pavel Feldman
3d760b657b
chore: move debug, env and user agent from utils/ (#34766) 2025-02-12 19:27:24 -08:00
Pavel Feldman
0eeba380f2
chore: move crypto to server/util/ (#34759) 2025-02-12 14:43:52 -08:00
Pavel Feldman
f54478a23e
chore: move utils that are user in server to server/utils (3) (#34739) 2025-02-12 09:34:01 -08:00
Pavel Feldman
25a168fae5
chore: move utils that are user in server to server/utils (1) (#34734) 2025-02-11 15:40:41 -08:00
Pavel Feldman
4a7f6a6ef0
chore: organize imports in playwright-core (#34680) 2025-02-07 13:54:01 -08:00
Simon Knott
5d82567346
feat: emulate prefers-contrast (#34494) 2025-02-04 11:15:51 +01:00
Dmitry Gozman
9dbe63636d
fix(routeWebSocket): should work after context reuse (#34165) 2024-12-30 10:00:10 -08:00
Dmitry Gozman
f713d3adaf
chore: simplify page initialization logic across browser types (#34002) 2024-12-14 20:15:58 +00:00
Max Schmitt
e3629dc1df
fix: validate ffmpeg on context creation (#33903) 2024-12-11 23:07:03 -08:00
Pavel Feldman
c76f004ec3
chore: move compress call log to server (#33399) 2024-11-01 13:38:01 -07:00
Yury Semikhatsky
1e8884621a
chore: unify toHaveScreenshot error formatting (#33300) 2024-10-25 12:36:39 -07:00
Yury Semikhatsky
b9cce598dd
fix(screenshot): show image diff inline in errors list (#32997)
The diff is now shown inline in the errors list.

There are 2 possible failures of toHaveScreenshot
* Previous and actual snapshot mismatch. In this case html report will
show diff between Actual/Previous and have Expected as a separate
screenshot.
* Actual/Previous are equal but they differ from the expected. In this
case html report only contains Actual/Expected images and the diff.

Reference: https://github.com/microsoft/playwright/issues/32341

<img width="1039" alt="image"
src="https://github.com/user-attachments/assets/b458f986-cc25-4721-862c-0cc2c1b01a42">
2024-10-10 16:49:17 -07:00
Dmitry Gozman
84b4fd4e40
feat: wait for pending navigation to resolve before many actions (#32899)
This includes all actions that perform locator handler check.
    
Note this makes it impossible to interact with the page while a main
frame navigation is ongoing. This was already the case for Chromium, but
now WebKit and Firefox align with it.

Setting `PLAYWRIGHT_SKIP_NAVIGATION_CHECK` environment variable disables
this behavior.
2024-10-04 07:25:18 -07:00
Dmitry Gozman
a9d5c39d40
chore: address api review for page.forceGarbageCollection (#32824)
- Renamed to `page.requestGC`.
- Added a useful snippet to the docs.

References #32278.

---------

Signed-off-by: Dmitry Gozman <dgozman@gmail.com>
Co-authored-by: Max Schmitt <max@schmitt.mx>
2024-09-26 05:08:33 -07:00
Dmitry Gozman
f9d9ad25de
feat(locator handler): perform checkpoit during locator.waitFor (#32683)
Fixes #32255.
2024-09-18 09:34:06 -07:00
Matthew Jee
f2a974b045
feat(api): add method to force garbage collection (#32383) 2024-09-13 23:09:36 +02:00
Rui Figueira
f8562e4ca7
chore: improve error message when Array.toJSON misbehaves (#32508)
Fixes: #32507
2024-09-10 04:14:24 -07:00
Yury Semikhatsky
37bc485827
chore: remove browser-specific bidi hacks (#32498)
Those were just workarounds for browser-specific bugs, they should be
fixed upstream.
* individual mouse down/up/down/up events don't trigger dblclick event
in Firefox
* setContent throws when document.open/write is called in the utility
context in Firefox
2024-09-06 16:40:24 -07:00
Yury Semikhatsky
9a2c60a77c
chore: identify largest gaps in Bidi API (#32434)
This pull request introduces initial support for the WebDriver BiDi
protocol in Playwright. The primary goal of this PR is not to fully
implement BiDi but to experiment with the current state of the
specification and its implementation. We aim to identify the biggest
gaps and challenges that need to be addressed before considering BiDi as
the main protocol for Playwright.
2024-09-04 11:36:52 -07:00
Dmitry Gozman
f8eef3897c
chore: move urlMatch to isomorphic (#32142)
To be reused in injected code.
2024-08-13 12:47:02 -07:00
Dmitry Gozman
9b3e0e5667
chore: simplify binding result dispatch (#32092)
We can now pass an Error object through evaluate.
2024-08-09 03:46:52 -07:00
Dmitry Gozman
ea747afcdd
chore: use a single binding for all Playwright needs (#32039)
This makes it easier to manage bindings, being just init scripts.
Fixes the BFCache binding problem.
Makes bindings removable in Firefox.

Fixes #31515.
2024-08-07 06:20:12 -07:00
Dmitry Gozman
229000501e
chore: introduce helpers for non-stalling eval on page/context (#31658) 2024-07-12 02:26:16 -07:00