appium / ruby_lib_core

Core library for the Ruby client
Apache License 2.0
31 stars 24 forks source link

Note to make less diff between selenium Ruby binding and this lib #429

Open KazuCocoa opened 1 year ago

KazuCocoa commented 1 year ago
KazuCocoa commented 1 year ago

Only Python client defines shortcut actions such as https://github.com/appium/python-client/blob/677c1a2121053a0435f3e0d8f7798077a41aa067/appium/webdriver/extensions/action_helpers.py#L132, but not in Ruby and other ones. Action builders can provide such high-level action shortcuts for users.

p0deje commented 1 year ago

From the Selenium side, the following changes are needed:

  1. HTTPClient: a. There should be a way to pass extra HTTP headers to the new session. b. There should be a way to change the default User-Agent.
  2. Bridge: a. There should be a way to update the bridge so that it can point to a new URL. b. There should be a way to add a new command that is a bridge request and extra methods to implement more on top of that. c. There should be a way to alter locator conversion. d. There should be a way to unwrap elements from the executeScript response. It seems like it should already work, but needs to be double-checked.
  3. Driver: a. There should be a way to define methods on Driver which simply delegate to Bridge. b. There should be a way to define different defaults for action builder (touch instead of mouse, smaller duration). Or there should be a way to completely redefine action builder implementations.
  4. Capabilities: a. There should be a way to process capabilities before creating a new session.
  5. SearchContext: a. There should be a way to register extra finders (e.g. accessibility_id).