Skip to content

Commit 7935cd6

Browse files
committed
hack: workaround JSHandle generated types
1 parent 8803b75 commit 7935cd6

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

playwright/js_handle.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -93,6 +93,8 @@ async def jsonValue(self) -> Any:
9393

9494

9595
def serialize_value(value: Any, handles: List[JSHandle], depth: int) -> Any:
96+
if type(value).__name__ == "JSHandle" and not isinstance(value, JSHandle):
97+
value = value._impl_obj
9698
if isinstance(value, JSHandle):
9799
h = len(handles)
98100
handles.append(value._channel)

tests/async/test_dispatch_event.py

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -137,7 +137,6 @@ async def test_should_be_atomic(selectors, page, utils):
137137
assert await page.evaluate("() => window._clicked")
138138

139139

140-
@pytest.mark.skip("TODO: Determine why there is a failure.")
141140
@pytest.mark.skip_browser("webkit")
142141
async def test_should_dispatch_drag_drop_events(page, server):
143142
await page.goto(server.PREFIX + "/drag-n-drop.html")
@@ -151,7 +150,6 @@ async def test_should_dispatch_drag_drop_events(page, server):
151150
)
152151

153152

154-
@pytest.mark.skip("TODO: Determine why there is a failure.")
155153
@pytest.mark.skip_browser("webkit")
156154
async def test_should_dispatch_drag_and_drop_events_element_handle(page, server):
157155
await page.goto(server.PREFIX + "/drag-n-drop.html")

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy