Skip to content

Commit

Permalink
Merge branch 'trunk' into webkit_service
Browse files Browse the repository at this point in the history
  • Loading branch information
Delta456 authored Oct 18, 2024
2 parents aef2c4c + 1b64798 commit 2e378ee
Show file tree
Hide file tree
Showing 8 changed files with 83 additions and 8 deletions.
2 changes: 1 addition & 1 deletion dotnet/src/webdriver/WebDriver.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -106,7 +106,7 @@
</Target>

<Target Name="GenerateCdp" BeforeTargets="CoreCompile">
<Exec Command="bazel build //dotnet/src/webdriver/cdp:generate-v85 //dotnet/src/webdriver/cdp:generate-v127 //dotnet/src/webdriver/cdp:generate-v128 //dotnet/src/webdriver/cdp:generate-v129" WorkingDirectory="../../.." />
<Exec Command="bazel build //dotnet/src/webdriver/cdp/..." WorkingDirectory="../../.." />

<ItemGroup>
<Compile Include="..\..\..\bazel-bin\dotnet\src\webdriver\cdp\**\*.cs" LinkBase="DevTools\generated" />
Expand Down
7 changes: 1 addition & 6 deletions dotnet/src/webdriver/cdp/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -52,9 +52,4 @@ perform the following steps, where `<N>` is the major version of the protocol:
remove the entry for version `<N>` from the `SupportedDevToolsVersions` dictionary initialization.
3. Remove the version string (`v<N>`) from the `SUPPORTED_DEVTOOLS_VERSIONS` list in
[`//dotnet:selenium-dotnet-version.bzl`](https://github.com/SeleniumHQ/selenium/blob/trunk/dotnet/selenium-dotnet-version.bzl).
4. In [`//dotnet/src/webdriver:WebDriver.csproj.prebuild.cmd`](https://github.com/SeleniumHQ/selenium/blob/trunk/dotnet/src/webdriver/WebDriver.csproj.prebuild.cmd),
remove the `if not exist` block for version `<N>`.
5. In [`//dotnet/src/webdriver:WebDriver.csproj.prebuild.sh`](https://github.com/SeleniumHQ/selenium/blob/trunk/dotnet/src/webdriver/WebDriver.csproj.prebuild.sh),
remove the `if-fi` block for version `<N>`.
6. Commit the changes.

4. Commit the changes.
6 changes: 5 additions & 1 deletion rb/sig/lib/selenium/webdriver/bidi.rbs
Original file line number Diff line number Diff line change
Expand Up @@ -7,13 +7,17 @@ module Selenium

def initialize: (url: String) -> void

def add_callback: -> Integer

def close: () -> nil

def callbacks: () -> Hash[untyped, untyped]

def remove_callback: -> Array[Integer]

def session: () -> Session

def send_cmd: (untyped method, **untyped params) -> untyped
def send_cmd: (String method, **untyped params) -> untyped

def error_message: (Hash[String,String] message) -> String
end
Expand Down
27 changes: 27 additions & 0 deletions rb/sig/lib/selenium/webdriver/bidi/log_handler.rbs
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
module Selenium
module WebDriver
class BiDi
class LogHandler
@bidi: BiDi

@log_entry_subscribed: bool

ConsoleLogEntry: Struct

JavaScriptLogEntry: Struct

def initialize: (BiDi bidi) -> void

def add_message_handler: (String type) { (untyped) -> untyped } -> Integer

def remove_message_handler: (Integer id) -> false

private

def subscribe_log_entry: () -> false

def unsubscribe_log_entry: () -> false
end
end
end
end
11 changes: 11 additions & 0 deletions rb/sig/lib/selenium/webdriver/bidi/struct.rbs
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
module Selenium
module WebDriver
class BiDi
class Struct < ::Struct
def self.new: (*untyped args) { (?) -> untyped } -> void

def self.camel_to_snake: (String camel_str) -> String
end
end
end
end
17 changes: 17 additions & 0 deletions rb/sig/lib/selenium/webdriver/remote/bidi_bridge.rbs
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
module Selenium
module WebDriver
module Remote
class BiDiBridge < Bridge
@bidi: untyped

attr_reader bidi: untyped

def create_session: (Hash[Symbol, String] capabilities) -> BiDi

def quit: () -> nil

def close: () -> nil
end
end
end
end
2 changes: 2 additions & 0 deletions rb/sig/lib/selenium/webdriver/remote/bridge.rbs
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,8 @@ module Selenium

def initialize: (url: String | URI, ?http_client: untyped?) -> void

def bidi: -> WebDriver::Error::WebDriverError

def cancel_fedcm_dialog: -> nil

def click_fedcm_dialog_button: -> nil
Expand Down
19 changes: 19 additions & 0 deletions rb/sig/lib/selenium/webdriver/remote/bridge/locator_converter.rbs
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
module Selenium
module WebDriver
module Remote
class Bridge
class LocatorConverter
ESCAPE_CSS_REGEXP: Regexp

UNICODE_CODE_POINT: Integer

def convert: (String | Symbol how, String what) -> Array[String]

private

def escape_css: (String string) -> String
end
end
end
end
end

0 comments on commit 2e378ee

Please sign in to comment.