playwright-ruby-client 1.17.0 → 1.18.beta1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/documentation/docs/api/api_request_context.md +49 -0
- data/documentation/docs/api/download.md +1 -3
- data/documentation/docs/api/frame.md +1 -1
- data/documentation/docs/api/frame_locator.md +10 -1
- data/documentation/docs/api/locator.md +19 -47
- data/documentation/docs/api/page.md +1 -1
- data/documentation/docs/include/api_coverage.md +5 -0
- data/lib/playwright/channel_owners/browser_context.rb +5 -0
- data/lib/playwright/channel_owners/frame.rb +2 -2
- data/lib/playwright/channel_owners/local_utils.rb +14 -0
- data/lib/playwright/channel_owners/page.rb +2 -2
- data/lib/playwright/frame_locator_impl.rb +2 -1
- data/lib/playwright/locator_impl.rb +62 -3
- data/lib/playwright/tracing_impl.rb +21 -7
- data/lib/playwright/version.rb +2 -2
- data/lib/playwright_api/android.rb +6 -6
- data/lib/playwright_api/android_device.rb +8 -8
- data/lib/playwright_api/api_request_context.rb +53 -6
- data/lib/playwright_api/browser.rb +6 -6
- data/lib/playwright_api/browser_context.rb +10 -10
- data/lib/playwright_api/browser_type.rb +6 -6
- data/lib/playwright_api/cdp_session.rb +6 -6
- data/lib/playwright_api/console_message.rb +6 -6
- data/lib/playwright_api/dialog.rb +6 -6
- data/lib/playwright_api/download.rb +0 -4
- data/lib/playwright_api/element_handle.rb +6 -6
- data/lib/playwright_api/frame.rb +8 -8
- data/lib/playwright_api/frame_locator.rb +11 -2
- data/lib/playwright_api/js_handle.rb +6 -6
- data/lib/playwright_api/local_utils.rb +9 -0
- data/lib/playwright_api/locator.rb +16 -46
- data/lib/playwright_api/page.rb +17 -12
- data/lib/playwright_api/playwright.rb +6 -6
- data/lib/playwright_api/request.rb +6 -6
- data/lib/playwright_api/response.rb +6 -6
- data/lib/playwright_api/route.rb +6 -6
- data/lib/playwright_api/selectors.rb +6 -6
- data/lib/playwright_api/web_socket.rb +6 -6
- data/lib/playwright_api/worker.rb +8 -8
- data/playwright.gemspec +1 -1
- metadata +10 -8
@@ -146,12 +146,6 @@ module Playwright
|
|
146
146
|
wrap_impl(@impl.name)
|
147
147
|
end
|
148
148
|
|
149
|
-
# -- inherited from EventEmitter --
|
150
|
-
# @nodoc
|
151
|
-
def off(event, callback)
|
152
|
-
event_emitter_proxy.off(event, callback)
|
153
|
-
end
|
154
|
-
|
155
149
|
# -- inherited from EventEmitter --
|
156
150
|
# @nodoc
|
157
151
|
def once(event, callback)
|
@@ -164,6 +158,12 @@ module Playwright
|
|
164
158
|
event_emitter_proxy.on(event, callback)
|
165
159
|
end
|
166
160
|
|
161
|
+
# -- inherited from EventEmitter --
|
162
|
+
# @nodoc
|
163
|
+
def off(event, callback)
|
164
|
+
event_emitter_proxy.off(event, callback)
|
165
|
+
end
|
166
|
+
|
167
167
|
private def event_emitter_proxy
|
168
168
|
@event_emitter_proxy ||= EventEmitterProxy.new(self, @impl)
|
169
169
|
end
|
@@ -33,12 +33,6 @@ module Playwright
|
|
33
33
|
wrap_impl(@impl.send_message(unwrap_impl(method), params: unwrap_impl(params)))
|
34
34
|
end
|
35
35
|
|
36
|
-
# -- inherited from EventEmitter --
|
37
|
-
# @nodoc
|
38
|
-
def off(event, callback)
|
39
|
-
event_emitter_proxy.off(event, callback)
|
40
|
-
end
|
41
|
-
|
42
36
|
# -- inherited from EventEmitter --
|
43
37
|
# @nodoc
|
44
38
|
def once(event, callback)
|
@@ -51,6 +45,12 @@ module Playwright
|
|
51
45
|
event_emitter_proxy.on(event, callback)
|
52
46
|
end
|
53
47
|
|
48
|
+
# -- inherited from EventEmitter --
|
49
|
+
# @nodoc
|
50
|
+
def off(event, callback)
|
51
|
+
event_emitter_proxy.off(event, callback)
|
52
|
+
end
|
53
|
+
|
54
54
|
private def event_emitter_proxy
|
55
55
|
@event_emitter_proxy ||= EventEmitterProxy.new(self, @impl)
|
56
56
|
end
|
@@ -23,12 +23,6 @@ module Playwright
|
|
23
23
|
wrap_impl(@impl.type)
|
24
24
|
end
|
25
25
|
|
26
|
-
# -- inherited from EventEmitter --
|
27
|
-
# @nodoc
|
28
|
-
def off(event, callback)
|
29
|
-
event_emitter_proxy.off(event, callback)
|
30
|
-
end
|
31
|
-
|
32
26
|
# -- inherited from EventEmitter --
|
33
27
|
# @nodoc
|
34
28
|
def once(event, callback)
|
@@ -41,6 +35,12 @@ module Playwright
|
|
41
35
|
event_emitter_proxy.on(event, callback)
|
42
36
|
end
|
43
37
|
|
38
|
+
# -- inherited from EventEmitter --
|
39
|
+
# @nodoc
|
40
|
+
def off(event, callback)
|
41
|
+
event_emitter_proxy.off(event, callback)
|
42
|
+
end
|
43
|
+
|
44
44
|
private def event_emitter_proxy
|
45
45
|
@event_emitter_proxy ||= EventEmitterProxy.new(self, @impl)
|
46
46
|
end
|
@@ -58,12 +58,6 @@ module Playwright
|
|
58
58
|
wrap_impl(@impl.accept_async(promptText: unwrap_impl(promptText)))
|
59
59
|
end
|
60
60
|
|
61
|
-
# -- inherited from EventEmitter --
|
62
|
-
# @nodoc
|
63
|
-
def off(event, callback)
|
64
|
-
event_emitter_proxy.off(event, callback)
|
65
|
-
end
|
66
|
-
|
67
61
|
# -- inherited from EventEmitter --
|
68
62
|
# @nodoc
|
69
63
|
def once(event, callback)
|
@@ -76,6 +70,12 @@ module Playwright
|
|
76
70
|
event_emitter_proxy.on(event, callback)
|
77
71
|
end
|
78
72
|
|
73
|
+
# -- inherited from EventEmitter --
|
74
|
+
# @nodoc
|
75
|
+
def off(event, callback)
|
76
|
+
event_emitter_proxy.off(event, callback)
|
77
|
+
end
|
78
|
+
|
79
79
|
private def event_emitter_proxy
|
80
80
|
@event_emitter_proxy ||= EventEmitterProxy.new(self, @impl)
|
81
81
|
end
|
@@ -12,10 +12,6 @@ module Playwright
|
|
12
12
|
# # wait for download to complete
|
13
13
|
# path = download.path()
|
14
14
|
# ```
|
15
|
-
#
|
16
|
-
# > NOTE: Browser context **must** be created with the `acceptDownloads` set to `true` when user needs access to the
|
17
|
-
# downloaded content. If `acceptDownloads` is not set, download events are emitted, but the actual download is not
|
18
|
-
# performed and user has no access to the downloaded files.
|
19
15
|
class Download < PlaywrightApi
|
20
16
|
|
21
17
|
# Cancels a download. Will not fail if the download is already finished or canceled. Upon successful cancellations,
|
@@ -551,12 +551,6 @@ module Playwright
|
|
551
551
|
wrap_impl(@impl.wait_for_selector(unwrap_impl(selector), state: unwrap_impl(state), strict: unwrap_impl(strict), timeout: unwrap_impl(timeout)))
|
552
552
|
end
|
553
553
|
|
554
|
-
# -- inherited from EventEmitter --
|
555
|
-
# @nodoc
|
556
|
-
def off(event, callback)
|
557
|
-
event_emitter_proxy.off(event, callback)
|
558
|
-
end
|
559
|
-
|
560
554
|
# -- inherited from EventEmitter --
|
561
555
|
# @nodoc
|
562
556
|
def once(event, callback)
|
@@ -569,6 +563,12 @@ module Playwright
|
|
569
563
|
event_emitter_proxy.on(event, callback)
|
570
564
|
end
|
571
565
|
|
566
|
+
# -- inherited from EventEmitter --
|
567
|
+
# @nodoc
|
568
|
+
def off(event, callback)
|
569
|
+
event_emitter_proxy.off(event, callback)
|
570
|
+
end
|
571
|
+
|
572
572
|
private def event_emitter_proxy
|
573
573
|
@event_emitter_proxy ||= EventEmitterProxy.new(self, @impl)
|
574
574
|
end
|
data/lib/playwright_api/frame.rb
CHANGED
@@ -445,8 +445,8 @@ module Playwright
|
|
445
445
|
# The method returns an element locator that can be used to perform actions in the frame. Locator is resolved to the
|
446
446
|
# element immediately before performing an action, so a series of actions on the same locator can in fact be performed on
|
447
447
|
# different DOM elements. That would happen if the DOM structure between those actions has changed.
|
448
|
-
def locator(selector)
|
449
|
-
wrap_impl(@impl.locator(unwrap_impl(selector)))
|
448
|
+
def locator(selector, hasText: nil)
|
449
|
+
wrap_impl(@impl.locator(unwrap_impl(selector), hasText: unwrap_impl(hasText)))
|
450
450
|
end
|
451
451
|
|
452
452
|
# Returns frame's name attribute as specified in the tag.
|
@@ -788,12 +788,6 @@ module Playwright
|
|
788
788
|
wrap_impl(@impl.detached=(unwrap_impl(req)))
|
789
789
|
end
|
790
790
|
|
791
|
-
# -- inherited from EventEmitter --
|
792
|
-
# @nodoc
|
793
|
-
def off(event, callback)
|
794
|
-
event_emitter_proxy.off(event, callback)
|
795
|
-
end
|
796
|
-
|
797
791
|
# -- inherited from EventEmitter --
|
798
792
|
# @nodoc
|
799
793
|
def once(event, callback)
|
@@ -806,6 +800,12 @@ module Playwright
|
|
806
800
|
event_emitter_proxy.on(event, callback)
|
807
801
|
end
|
808
802
|
|
803
|
+
# -- inherited from EventEmitter --
|
804
|
+
# @nodoc
|
805
|
+
def off(event, callback)
|
806
|
+
event_emitter_proxy.off(event, callback)
|
807
|
+
end
|
808
|
+
|
809
809
|
private def event_emitter_proxy
|
810
810
|
@event_emitter_proxy ||= EventEmitterProxy.new(self, @impl)
|
811
811
|
end
|
@@ -20,6 +20,15 @@ module Playwright
|
|
20
20
|
# # Works because we explicitly tell locator to pick the first frame:
|
21
21
|
# page.frame_locator('.result-frame').first.locator('button').click()
|
22
22
|
# ```
|
23
|
+
#
|
24
|
+
# **Converting Locator to FrameLocator**
|
25
|
+
#
|
26
|
+
# If you have a `Locator` object pointing to an `iframe` it can be converted to `FrameLocator` using
|
27
|
+
# [`:scope`](https://developer.mozilla.org/en-US/docs/Web/CSS/:scope) CSS selector:
|
28
|
+
#
|
29
|
+
# ```python sync
|
30
|
+
# frameLocator = locator.frame_locator(":scope");
|
31
|
+
# ```
|
23
32
|
class FrameLocator < PlaywrightApi
|
24
33
|
|
25
34
|
# Returns locator to the first matching frame.
|
@@ -39,8 +48,8 @@ module Playwright
|
|
39
48
|
end
|
40
49
|
|
41
50
|
# The method finds an element matching the specified selector in the FrameLocator's subtree.
|
42
|
-
def locator(selector)
|
43
|
-
wrap_impl(@impl.locator(unwrap_impl(selector)))
|
51
|
+
def locator(selector, hasText: nil)
|
52
|
+
wrap_impl(@impl.locator(unwrap_impl(selector), hasText: unwrap_impl(hasText)))
|
44
53
|
end
|
45
54
|
|
46
55
|
# Returns locator to the n-th matching frame.
|
@@ -88,12 +88,6 @@ module Playwright
|
|
88
88
|
wrap_impl(@impl.to_s)
|
89
89
|
end
|
90
90
|
|
91
|
-
# -- inherited from EventEmitter --
|
92
|
-
# @nodoc
|
93
|
-
def off(event, callback)
|
94
|
-
event_emitter_proxy.off(event, callback)
|
95
|
-
end
|
96
|
-
|
97
91
|
# -- inherited from EventEmitter --
|
98
92
|
# @nodoc
|
99
93
|
def once(event, callback)
|
@@ -106,6 +100,12 @@ module Playwright
|
|
106
100
|
event_emitter_proxy.on(event, callback)
|
107
101
|
end
|
108
102
|
|
103
|
+
# -- inherited from EventEmitter --
|
104
|
+
# @nodoc
|
105
|
+
def off(event, callback)
|
106
|
+
event_emitter_proxy.off(event, callback)
|
107
|
+
end
|
108
|
+
|
109
109
|
private def event_emitter_proxy
|
110
110
|
@event_emitter_proxy ||= EventEmitterProxy.new(self, @impl)
|
111
111
|
end
|
@@ -1,49 +1,8 @@
|
|
1
1
|
module Playwright
|
2
|
-
#
|
3
|
-
#
|
2
|
+
# Locators are the central piece of Playwright's auto-waiting and retry-ability. In a nutshell, locators represent a way
|
3
|
+
# to find element(s) on the page at any moment. Locator can be created with the [`method: Page.locator`] method.
|
4
4
|
#
|
5
|
-
#
|
6
|
-
# locator = page.locator("text=Submit")
|
7
|
-
# locator.click()
|
8
|
-
# ```
|
9
|
-
#
|
10
|
-
# The difference between the Locator and `ElementHandle` is that the latter points to a particular element, while Locator
|
11
|
-
# captures the logic of how to retrieve that element.
|
12
|
-
#
|
13
|
-
# In the example below, handle points to a particular DOM element on page. If that element changes text or is used by
|
14
|
-
# React to render an entirely different component, handle is still pointing to that very DOM element. This can lead to
|
15
|
-
# unexpected behaviors.
|
16
|
-
#
|
17
|
-
# ```python sync
|
18
|
-
# handle = page.query_selector("text=Submit")
|
19
|
-
# handle.hover()
|
20
|
-
# handle.click()
|
21
|
-
# ```
|
22
|
-
#
|
23
|
-
# With the locator, every time the `element` is used, up-to-date DOM element is located in the page using the selector. So
|
24
|
-
# in the snippet below, underlying DOM element is going to be located twice.
|
25
|
-
#
|
26
|
-
# ```python sync
|
27
|
-
# locator = page.locator("text=Submit")
|
28
|
-
# locator.hover()
|
29
|
-
# locator.click()
|
30
|
-
# ```
|
31
|
-
#
|
32
|
-
# **Strictness**
|
33
|
-
#
|
34
|
-
# Locators are strict. This means that all operations on locators that imply some target DOM element will throw if more
|
35
|
-
# than one element matches given selector.
|
36
|
-
#
|
37
|
-
# ```python sync
|
38
|
-
# # Throws if there are several buttons in DOM:
|
39
|
-
# page.locator('button').click()
|
40
|
-
#
|
41
|
-
# # Works because we explicitly tell locator to pick the first element:
|
42
|
-
# page.locator('button').first.click()
|
43
|
-
#
|
44
|
-
# # Works because count knows what to do with multiple matches:
|
45
|
-
# page.locator('button').count()
|
46
|
-
# ```
|
5
|
+
# [Learn more about locators](./locators.md).
|
47
6
|
class Locator < PlaywrightApi
|
48
7
|
|
49
8
|
# Returns an array of `node.innerText` values for all matching nodes.
|
@@ -183,6 +142,17 @@ module Playwright
|
|
183
142
|
wrap_impl(@impl.dispatch_event(unwrap_impl(type), eventInit: unwrap_impl(eventInit), timeout: unwrap_impl(timeout)))
|
184
143
|
end
|
185
144
|
|
145
|
+
def drag_to(
|
146
|
+
target,
|
147
|
+
force: nil,
|
148
|
+
noWaitAfter: nil,
|
149
|
+
sourcePosition: nil,
|
150
|
+
targetPosition: nil,
|
151
|
+
timeout: nil,
|
152
|
+
trial: nil)
|
153
|
+
wrap_impl(@impl.drag_to(unwrap_impl(target), force: unwrap_impl(force), noWaitAfter: unwrap_impl(noWaitAfter), sourcePosition: unwrap_impl(sourcePosition), targetPosition: unwrap_impl(targetPosition), timeout: unwrap_impl(timeout), trial: unwrap_impl(trial)))
|
154
|
+
end
|
155
|
+
|
186
156
|
# Resolves given locator to the first matching DOM element. If no elements matching the query are visible, waits for them
|
187
157
|
# up to a given timeout. If multiple elements match the selector, throws.
|
188
158
|
def element_handle(timeout: nil)
|
@@ -350,8 +320,8 @@ module Playwright
|
|
350
320
|
end
|
351
321
|
|
352
322
|
# The method finds an element matching the specified selector in the `Locator`'s subtree.
|
353
|
-
def locator(selector)
|
354
|
-
wrap_impl(@impl.locator(unwrap_impl(selector)))
|
323
|
+
def locator(selector, hasText: nil)
|
324
|
+
wrap_impl(@impl.locator(unwrap_impl(selector), hasText: unwrap_impl(hasText)))
|
355
325
|
end
|
356
326
|
|
357
327
|
# Returns locator to the n-th matching element.
|
data/lib/playwright_api/page.rb
CHANGED
@@ -56,6 +56,11 @@ module Playwright
|
|
56
56
|
wrap_impl(@impl.mouse)
|
57
57
|
end
|
58
58
|
|
59
|
+
# API testing helper associated with this page. Requests made with this API will use page cookies.
|
60
|
+
def request # property
|
61
|
+
raise NotImplementedError.new('request is not implemented yet.')
|
62
|
+
end
|
63
|
+
|
59
64
|
def touchscreen # property
|
60
65
|
wrap_impl(@impl.touchscreen)
|
61
66
|
end
|
@@ -681,8 +686,8 @@ module Playwright
|
|
681
686
|
# different DOM elements. That would happen if the DOM structure between those actions has changed.
|
682
687
|
#
|
683
688
|
# Shortcut for main frame's [`method: Frame.locator`].
|
684
|
-
def locator(selector)
|
685
|
-
wrap_impl(@impl.locator(unwrap_impl(selector)))
|
689
|
+
def locator(selector, hasText: nil)
|
690
|
+
wrap_impl(@impl.locator(unwrap_impl(selector), hasText: unwrap_impl(hasText)))
|
686
691
|
end
|
687
692
|
|
688
693
|
# The page's main frame. Page is guaranteed to have a main frame which persists during navigations.
|
@@ -1391,25 +1396,19 @@ module Playwright
|
|
1391
1396
|
wrap_impl(@impl.stop_js_coverage)
|
1392
1397
|
end
|
1393
1398
|
|
1394
|
-
# @nodoc
|
1395
|
-
def stop_css_coverage
|
1396
|
-
wrap_impl(@impl.stop_css_coverage)
|
1397
|
-
end
|
1398
|
-
|
1399
1399
|
# @nodoc
|
1400
1400
|
def start_css_coverage(resetOnNavigation: nil, reportAnonymousScripts: nil)
|
1401
1401
|
wrap_impl(@impl.start_css_coverage(resetOnNavigation: unwrap_impl(resetOnNavigation), reportAnonymousScripts: unwrap_impl(reportAnonymousScripts)))
|
1402
1402
|
end
|
1403
1403
|
|
1404
1404
|
# @nodoc
|
1405
|
-
def
|
1406
|
-
wrap_impl(@impl.
|
1405
|
+
def stop_css_coverage
|
1406
|
+
wrap_impl(@impl.stop_css_coverage)
|
1407
1407
|
end
|
1408
1408
|
|
1409
|
-
# -- inherited from EventEmitter --
|
1410
1409
|
# @nodoc
|
1411
|
-
def
|
1412
|
-
|
1410
|
+
def guid
|
1411
|
+
wrap_impl(@impl.guid)
|
1413
1412
|
end
|
1414
1413
|
|
1415
1414
|
# -- inherited from EventEmitter --
|
@@ -1424,6 +1423,12 @@ module Playwright
|
|
1424
1423
|
event_emitter_proxy.on(event, callback)
|
1425
1424
|
end
|
1426
1425
|
|
1426
|
+
# -- inherited from EventEmitter --
|
1427
|
+
# @nodoc
|
1428
|
+
def off(event, callback)
|
1429
|
+
event_emitter_proxy.off(event, callback)
|
1430
|
+
end
|
1431
|
+
|
1427
1432
|
private def event_emitter_proxy
|
1428
1433
|
@event_emitter_proxy ||= EventEmitterProxy.new(self, @impl)
|
1429
1434
|
end
|
@@ -96,12 +96,6 @@ module Playwright
|
|
96
96
|
wrap_impl(@impl.electron)
|
97
97
|
end
|
98
98
|
|
99
|
-
# -- inherited from EventEmitter --
|
100
|
-
# @nodoc
|
101
|
-
def off(event, callback)
|
102
|
-
event_emitter_proxy.off(event, callback)
|
103
|
-
end
|
104
|
-
|
105
99
|
# -- inherited from EventEmitter --
|
106
100
|
# @nodoc
|
107
101
|
def once(event, callback)
|
@@ -114,6 +108,12 @@ module Playwright
|
|
114
108
|
event_emitter_proxy.on(event, callback)
|
115
109
|
end
|
116
110
|
|
111
|
+
# -- inherited from EventEmitter --
|
112
|
+
# @nodoc
|
113
|
+
def off(event, callback)
|
114
|
+
event_emitter_proxy.off(event, callback)
|
115
|
+
end
|
116
|
+
|
117
117
|
private def event_emitter_proxy
|
118
118
|
@event_emitter_proxy ||= EventEmitterProxy.new(self, @impl)
|
119
119
|
end
|
@@ -154,12 +154,6 @@ module Playwright
|
|
154
154
|
wrap_impl(@impl.header_values(unwrap_impl(name)))
|
155
155
|
end
|
156
156
|
|
157
|
-
# -- inherited from EventEmitter --
|
158
|
-
# @nodoc
|
159
|
-
def off(event, callback)
|
160
|
-
event_emitter_proxy.off(event, callback)
|
161
|
-
end
|
162
|
-
|
163
157
|
# -- inherited from EventEmitter --
|
164
158
|
# @nodoc
|
165
159
|
def once(event, callback)
|
@@ -172,6 +166,12 @@ module Playwright
|
|
172
166
|
event_emitter_proxy.on(event, callback)
|
173
167
|
end
|
174
168
|
|
169
|
+
# -- inherited from EventEmitter --
|
170
|
+
# @nodoc
|
171
|
+
def off(event, callback)
|
172
|
+
event_emitter_proxy.off(event, callback)
|
173
|
+
end
|
174
|
+
|
175
175
|
private def event_emitter_proxy
|
176
176
|
@event_emitter_proxy ||= EventEmitterProxy.new(self, @impl)
|
177
177
|
end
|
@@ -97,12 +97,6 @@ module Playwright
|
|
97
97
|
wrap_impl(@impl.ok?)
|
98
98
|
end
|
99
99
|
|
100
|
-
# -- inherited from EventEmitter --
|
101
|
-
# @nodoc
|
102
|
-
def off(event, callback)
|
103
|
-
event_emitter_proxy.off(event, callback)
|
104
|
-
end
|
105
|
-
|
106
100
|
# -- inherited from EventEmitter --
|
107
101
|
# @nodoc
|
108
102
|
def once(event, callback)
|
@@ -115,6 +109,12 @@ module Playwright
|
|
115
109
|
event_emitter_proxy.on(event, callback)
|
116
110
|
end
|
117
111
|
|
112
|
+
# -- inherited from EventEmitter --
|
113
|
+
# @nodoc
|
114
|
+
def off(event, callback)
|
115
|
+
event_emitter_proxy.off(event, callback)
|
116
|
+
end
|
117
|
+
|
118
118
|
private def event_emitter_proxy
|
119
119
|
@event_emitter_proxy ||= EventEmitterProxy.new(self, @impl)
|
120
120
|
end
|
data/lib/playwright_api/route.rb
CHANGED
@@ -56,12 +56,6 @@ module Playwright
|
|
56
56
|
wrap_impl(@impl.request)
|
57
57
|
end
|
58
58
|
|
59
|
-
# -- inherited from EventEmitter --
|
60
|
-
# @nodoc
|
61
|
-
def off(event, callback)
|
62
|
-
event_emitter_proxy.off(event, callback)
|
63
|
-
end
|
64
|
-
|
65
59
|
# -- inherited from EventEmitter --
|
66
60
|
# @nodoc
|
67
61
|
def once(event, callback)
|
@@ -74,6 +68,12 @@ module Playwright
|
|
74
68
|
event_emitter_proxy.on(event, callback)
|
75
69
|
end
|
76
70
|
|
71
|
+
# -- inherited from EventEmitter --
|
72
|
+
# @nodoc
|
73
|
+
def off(event, callback)
|
74
|
+
event_emitter_proxy.off(event, callback)
|
75
|
+
end
|
76
|
+
|
77
77
|
private def event_emitter_proxy
|
78
78
|
@event_emitter_proxy ||= EventEmitterProxy.new(self, @impl)
|
79
79
|
end
|
@@ -43,12 +43,6 @@ module Playwright
|
|
43
43
|
wrap_impl(@impl.register(unwrap_impl(name), contentScript: unwrap_impl(contentScript), path: unwrap_impl(path), script: unwrap_impl(script)))
|
44
44
|
end
|
45
45
|
|
46
|
-
# -- inherited from EventEmitter --
|
47
|
-
# @nodoc
|
48
|
-
def off(event, callback)
|
49
|
-
event_emitter_proxy.off(event, callback)
|
50
|
-
end
|
51
|
-
|
52
46
|
# -- inherited from EventEmitter --
|
53
47
|
# @nodoc
|
54
48
|
def once(event, callback)
|
@@ -61,6 +55,12 @@ module Playwright
|
|
61
55
|
event_emitter_proxy.on(event, callback)
|
62
56
|
end
|
63
57
|
|
58
|
+
# -- inherited from EventEmitter --
|
59
|
+
# @nodoc
|
60
|
+
def off(event, callback)
|
61
|
+
event_emitter_proxy.off(event, callback)
|
62
|
+
end
|
63
|
+
|
64
64
|
private def event_emitter_proxy
|
65
65
|
@event_emitter_proxy ||= EventEmitterProxy.new(self, @impl)
|
66
66
|
end
|
@@ -27,12 +27,6 @@ module Playwright
|
|
27
27
|
wrap_impl(@impl.wait_for_event(unwrap_impl(event), predicate: unwrap_impl(predicate), timeout: unwrap_impl(timeout), &wrap_block_call(block)))
|
28
28
|
end
|
29
29
|
|
30
|
-
# -- inherited from EventEmitter --
|
31
|
-
# @nodoc
|
32
|
-
def off(event, callback)
|
33
|
-
event_emitter_proxy.off(event, callback)
|
34
|
-
end
|
35
|
-
|
36
30
|
# -- inherited from EventEmitter --
|
37
31
|
# @nodoc
|
38
32
|
def once(event, callback)
|
@@ -45,6 +39,12 @@ module Playwright
|
|
45
39
|
event_emitter_proxy.on(event, callback)
|
46
40
|
end
|
47
41
|
|
42
|
+
# -- inherited from EventEmitter --
|
43
|
+
# @nodoc
|
44
|
+
def off(event, callback)
|
45
|
+
event_emitter_proxy.off(event, callback)
|
46
|
+
end
|
47
|
+
|
48
48
|
private def event_emitter_proxy
|
49
49
|
@event_emitter_proxy ||= EventEmitterProxy.new(self, @impl)
|
50
50
|
end
|
@@ -43,20 +43,14 @@ module Playwright
|
|
43
43
|
wrap_impl(@impl.url)
|
44
44
|
end
|
45
45
|
|
46
|
-
# @nodoc
|
47
|
-
def page=(req)
|
48
|
-
wrap_impl(@impl.page=(unwrap_impl(req)))
|
49
|
-
end
|
50
|
-
|
51
46
|
# @nodoc
|
52
47
|
def context=(req)
|
53
48
|
wrap_impl(@impl.context=(unwrap_impl(req)))
|
54
49
|
end
|
55
50
|
|
56
|
-
# -- inherited from EventEmitter --
|
57
51
|
# @nodoc
|
58
|
-
def
|
59
|
-
|
52
|
+
def page=(req)
|
53
|
+
wrap_impl(@impl.page=(unwrap_impl(req)))
|
60
54
|
end
|
61
55
|
|
62
56
|
# -- inherited from EventEmitter --
|
@@ -71,6 +65,12 @@ module Playwright
|
|
71
65
|
event_emitter_proxy.on(event, callback)
|
72
66
|
end
|
73
67
|
|
68
|
+
# -- inherited from EventEmitter --
|
69
|
+
# @nodoc
|
70
|
+
def off(event, callback)
|
71
|
+
event_emitter_proxy.off(event, callback)
|
72
|
+
end
|
73
|
+
|
74
74
|
private def event_emitter_proxy
|
75
75
|
@event_emitter_proxy ||= EventEmitterProxy.new(self, @impl)
|
76
76
|
end
|
data/playwright.gemspec
CHANGED
@@ -27,7 +27,7 @@ Gem::Specification.new do |spec|
|
|
27
27
|
spec.required_ruby_version = '>= 2.4'
|
28
28
|
spec.add_dependency 'concurrent-ruby', '>= 1.1.6'
|
29
29
|
spec.add_dependency 'mime-types', '>= 3.0'
|
30
|
-
spec.add_development_dependency 'bundler', '~> 2.
|
30
|
+
spec.add_development_dependency 'bundler', '~> 2.3.0'
|
31
31
|
spec.add_development_dependency 'chunky_png'
|
32
32
|
spec.add_development_dependency 'dry-inflector'
|
33
33
|
spec.add_development_dependency 'faye-websocket'
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: playwright-ruby-client
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.
|
4
|
+
version: 1.18.beta1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- YusukeIwaki
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2022-01-18 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: concurrent-ruby
|
@@ -44,14 +44,14 @@ dependencies:
|
|
44
44
|
requirements:
|
45
45
|
- - "~>"
|
46
46
|
- !ruby/object:Gem::Version
|
47
|
-
version: 2.
|
47
|
+
version: 2.3.0
|
48
48
|
type: :development
|
49
49
|
prerelease: false
|
50
50
|
version_requirements: !ruby/object:Gem::Requirement
|
51
51
|
requirements:
|
52
52
|
- - "~>"
|
53
53
|
- !ruby/object:Gem::Version
|
54
|
-
version: 2.
|
54
|
+
version: 2.3.0
|
55
55
|
- !ruby/object:Gem::Dependency
|
56
56
|
name: chunky_png
|
57
57
|
requirement: !ruby/object:Gem::Requirement
|
@@ -293,6 +293,7 @@ files:
|
|
293
293
|
- lib/playwright/channel_owners/fetch_request.rb
|
294
294
|
- lib/playwright/channel_owners/frame.rb
|
295
295
|
- lib/playwright/channel_owners/js_handle.rb
|
296
|
+
- lib/playwright/channel_owners/local_utils.rb
|
296
297
|
- lib/playwright/channel_owners/page.rb
|
297
298
|
- lib/playwright/channel_owners/playwright.rb
|
298
299
|
- lib/playwright/channel_owners/request.rb
|
@@ -354,6 +355,7 @@ files:
|
|
354
355
|
- lib/playwright_api/frame_locator.rb
|
355
356
|
- lib/playwright_api/js_handle.rb
|
356
357
|
- lib/playwright_api/keyboard.rb
|
358
|
+
- lib/playwright_api/local_utils.rb
|
357
359
|
- lib/playwright_api/locator.rb
|
358
360
|
- lib/playwright_api/mouse.rb
|
359
361
|
- lib/playwright_api/page.rb
|
@@ -382,12 +384,12 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
382
384
|
version: '2.4'
|
383
385
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
384
386
|
requirements:
|
385
|
-
- - "
|
387
|
+
- - ">"
|
386
388
|
- !ruby/object:Gem::Version
|
387
|
-
version:
|
389
|
+
version: 1.3.1
|
388
390
|
requirements: []
|
389
|
-
rubygems_version: 3.
|
391
|
+
rubygems_version: 3.3.3
|
390
392
|
signing_key:
|
391
393
|
specification_version: 4
|
392
|
-
summary: The Ruby binding of playwright driver 1.
|
394
|
+
summary: The Ruby binding of playwright driver 1.18.0
|
393
395
|
test_files: []
|