Best Selenium code snippet using Selenium.WebDriver.Support.options
selenium-webdriver@4.1.0.rbi
Source:selenium-webdriver@4.1.0.rbi
...91 def profile=(_arg0); end92 private93 def binary_path; end94 def camelize?(key); end95 def enable_logging(browser_options); end96 def encode_extension(path); end97 def process_browser_options(browser_options); end98 def validate_extension(path); end99end100Selenium::WebDriver::Chrome::Options::BROWSER = T.let(T.unsafe(nil), String)101Selenium::WebDriver::Chrome::Options::CAPABILITIES = T.let(T.unsafe(nil), Hash)102Selenium::WebDriver::Chrome::Options::KEY = T.let(T.unsafe(nil), String)103class Selenium::WebDriver::Chrome::Profile104 include ::Selenium::WebDriver::ProfileHelper105 extend ::Selenium::WebDriver::ProfileHelper::ClassMethods106 def initialize(model = T.unsafe(nil)); end107 def [](key); end108 def []=(key, value); end109 def add_encoded_extension(encoded); end110 def add_extension(path); end111 def as_json(*_arg0); end112 def directory; end113 def layout_on_disk; end114 private115 def prefs; end116 def prefs_file_for(dir); end117 def read_model_prefs; end118 def write_prefs_to(dir); end119end120class Selenium::WebDriver::Chrome::Service < ::Selenium::WebDriver::Service121 private122 def extract_service_args(driver_opts); end123end124Selenium::WebDriver::Chrome::Service::DEFAULT_PORT = T.let(T.unsafe(nil), Integer)125Selenium::WebDriver::Chrome::Service::EXECUTABLE = T.let(T.unsafe(nil), String)126Selenium::WebDriver::Chrome::Service::MISSING_TEXT = T.let(T.unsafe(nil), String)127Selenium::WebDriver::Chrome::Service::SHUTDOWN_SUPPORTED = T.let(T.unsafe(nil), TrueClass)128class Selenium::WebDriver::DevTools129 def initialize(url:); end130 def callbacks; end131 def close; end132 def method_missing(method, *_args); end133 def send_cmd(method, **params); end134 private135 def attach_socket_listener; end136 def callback_thread(params); end137 def error_message(error); end138 def incoming_frame; end139 def next_id; end140 def process_frame(frame); end141 def process_handshake; end142 def respond_to_missing?(method, *_args); end143 def socket; end144 def start_session; end145 def wait; end146 def ws; end147end148class Selenium::WebDriver::DevTools::ConsoleEvent149 def initialize(type:, timestamp:, args:); end150 def args; end151 def args=(_arg0); end152 def timestamp; end153 def timestamp=(_arg0); end154 def type; end155 def type=(_arg0); end156end157class Selenium::WebDriver::DevTools::ExceptionEvent158 def initialize(description:, timestamp:, stacktrace:); end159 def description; end160 def description=(_arg0); end161 def stacktrace; end162 def stacktrace=(_arg0); end163 def timestamp; end164 def timestamp=(_arg0); end165end166class Selenium::WebDriver::DevTools::MutationEvent167 def initialize(element:, attribute_name:, current_value:, old_value:); end168 def attribute_name; end169 def attribute_name=(_arg0); end170 def current_value; end171 def current_value=(_arg0); end172 def element; end173 def element=(_arg0); end174 def old_value; end175 def old_value=(_arg0); end176end177class Selenium::WebDriver::DevTools::PinnedScript178 def initialize(script); end179 def callable; end180 def devtools_identifier; end181 def devtools_identifier=(_arg0); end182 def key; end183 def key=(_arg0); end184 def remove; end185 def script; end186 def script=(_arg0); end187 def to_json(*_arg0); end188end189Selenium::WebDriver::DevTools::RESPONSE_WAIT_INTERVAL = T.let(T.unsafe(nil), Float)190Selenium::WebDriver::DevTools::RESPONSE_WAIT_TIMEOUT = T.let(T.unsafe(nil), Integer)191class Selenium::WebDriver::DevTools::Request192 def initialize(id:, url:, method:, headers:, post_data:); end193 def ==(other); end194 def headers; end195 def headers=(_arg0); end196 def id; end197 def inspect; end198 def method; end199 def method=(_arg0); end200 def post_data; end201 def post_data=(_arg0); end202 def url; end203 def url=(_arg0); end204 class << self205 def from(id, params); end206 end207end208class Selenium::WebDriver::DevTools::Response209 def initialize(id:, code:, body:, headers:); end210 def ==(other); end211 def body; end212 def body=(_arg0); end213 def code; end214 def code=(_arg0); end215 def headers; end216 def headers=(_arg0); end217 def id; end218 def inspect; end219 class << self220 def from(id, encoded_body, params); end221 end222end223class Selenium::WebDriver::Dimension < ::Struct224 def height; end225 def height=(_); end226 def width; end227 def width=(_); end228 class << self229 def [](*_arg0); end230 def inspect; end231 def keyword_init?; end232 def members; end233 def new(*_arg0); end234 end235end236class Selenium::WebDriver::Driver237 include ::Selenium::WebDriver::SearchContext238 include ::Selenium::WebDriver::TakesScreenshot239 def initialize(bridge: T.unsafe(nil), listener: T.unsafe(nil), **opts); end240 def [](sel); end241 def action; end242 def all(*args); end243 def browser; end244 def capabilities; end245 def close; end246 def current_url; end247 def execute_async_script(script, *args); end248 def execute_script(script, *args); end249 def first(*args); end250 def get(url); end251 def inspect; end252 def keyboard; end253 def manage; end254 def mouse; end255 def navigate; end256 def page_source; end257 def quit; end258 def ref; end259 def script(script, *args); end260 def status; end261 def switch_to; end262 def title; end263 def window_handle; end264 def window_handles; end265 private266 def add_extensions(browser); end267 def bridge; end268 def create_bridge(**opts); end269 def generate_capabilities(cap_array); end270 def screenshot; end271 def service_url(opts); end272 class << self273 def for(browser, opts = T.unsafe(nil)); end274 end275end276module Selenium::WebDriver::DriverExtensions; end277module Selenium::WebDriver::DriverExtensions::DownloadsFiles278 def download_path=(path); end279end280module Selenium::WebDriver::DriverExtensions::FullPageScreenshot281 def save_full_page_screenshot(path); end282 private283 def full_screenshot; end284end285module Selenium::WebDriver::DriverExtensions::HasAddons286 def install_addon(path, temporary = T.unsafe(nil)); end287 def uninstall_addon(id); end288end289module Selenium::WebDriver::DriverExtensions::HasApplePermissions290 def permissions; end291 def permissions=(permissions); end292end293module Selenium::WebDriver::DriverExtensions::HasAuthentication294 def register(username:, password:, uri: T.unsafe(nil)); end295 private296 def auth_handlers; end297 def authenticate(request_id, url); end298end299module Selenium::WebDriver::DriverExtensions::HasCDP300 def execute_cdp(cmd, **params); end301end302module Selenium::WebDriver::DriverExtensions::HasCasting303 def cast_issue_message; end304 def cast_sink_to_use=(name); end305 def cast_sinks; end306 def start_cast_tab_mirroring(name); end307 def stop_casting(name); end308end309module Selenium::WebDriver::DriverExtensions::HasContext310 def context; end311 def context=(value); end312end313module Selenium::WebDriver::DriverExtensions::HasDebugger314 def attach_debugger; end315end316module Selenium::WebDriver::DriverExtensions::HasDevTools317 def devtools; end318end319module Selenium::WebDriver::DriverExtensions::HasLaunching320 def launch_app(id); end321end322module Selenium::WebDriver::DriverExtensions::HasLocation323 def location; end324 def location=(*_arg0); end325 def set_location; end326end327module Selenium::WebDriver::DriverExtensions::HasLogEvents328 include ::Selenium::WebDriver::Atoms329 def on_log_event(kind, &block); end330 private331 def log_console_events; end332 def log_exception_events; end333 def log_listeners; end334 def log_mutation_event(params); end335 def log_mutation_events; end336 def mutation_listener; end337end338Selenium::WebDriver::DriverExtensions::HasLogEvents::KINDS = T.let(T.unsafe(nil), Array)339module Selenium::WebDriver::DriverExtensions::HasLogs340 def logs; end341end342module Selenium::WebDriver::DriverExtensions::HasNetworkConditions343 def delete_network_conditions; end344 def network_conditions; end345 def network_conditions=(conditions); end346end347module Selenium::WebDriver::DriverExtensions::HasNetworkConnection348 def network_connection_type; end349 def network_connection_type=(*_arg0); end350end351module Selenium::WebDriver::DriverExtensions::HasNetworkInterception352 def intercept(&block); end353 private354 def fetch_response_body(id); end355 def intercept_request(id, params, &block); end356 def intercept_response(id, params); end357 def pending_response_requests; end358end359module Selenium::WebDriver::DriverExtensions::HasPermissions360 def add_permission(name, value); end361 def add_permissions(opt); end362end363module Selenium::WebDriver::DriverExtensions::HasPinnedScripts364 def pin_script(script); end365 def pinned_scripts; end366 def unpin_script(script); end367end368module Selenium::WebDriver::DriverExtensions::HasRemoteStatus369 def remote_status; end370end371module Selenium::WebDriver::DriverExtensions::HasSessionId372 def session_id; end373end374module Selenium::WebDriver::DriverExtensions::HasWebStorage375 def local_storage; end376 def session_storage; end377end378module Selenium::WebDriver::DriverExtensions::PrintsPage379 def print_page(**options); end380 def save_print_page(path, **options); end381end382module Selenium::WebDriver::DriverExtensions::UploadsFiles383 def file_detector=(detector); end384end385module Selenium::WebDriver::Edge386 class << self387 def path; end388 def path=(path); end389 end390end391class Selenium::WebDriver::Edge::Driver < ::Selenium::WebDriver::Chrome::Driver392 def browser; end393 private394 def devtools_address; end395end396module Selenium::WebDriver::Edge::Features397 include ::Selenium::WebDriver::Chrome::Features398 def commands(command); end399end400Selenium::WebDriver::Edge::Features::EDGE_COMMANDS = T.let(T.unsafe(nil), Hash)401class Selenium::WebDriver::Edge::Options < ::Selenium::WebDriver::Chrome::Options402 protected403 def enable_logging(browser_options); end404 private405 def binary_path; end406end407Selenium::WebDriver::Edge::Options::BROWSER = T.let(T.unsafe(nil), String)408Selenium::WebDriver::Edge::Options::KEY = T.let(T.unsafe(nil), String)409class Selenium::WebDriver::Edge::Profile < ::Selenium::WebDriver::Chrome::Profile; end410class Selenium::WebDriver::Edge::Service < ::Selenium::WebDriver::Chrome::Service; end411Selenium::WebDriver::Edge::Service::DEFAULT_PORT = T.let(T.unsafe(nil), Integer)412Selenium::WebDriver::Edge::Service::EXECUTABLE = T.let(T.unsafe(nil), String)413Selenium::WebDriver::Edge::Service::MISSING_TEXT = T.let(T.unsafe(nil), String)414Selenium::WebDriver::Edge::Service::SHUTDOWN_SUPPORTED = T.let(T.unsafe(nil), TrueClass)415class Selenium::WebDriver::Element416 include ::Selenium::WebDriver::SearchContext417 include ::Selenium::WebDriver::TakesScreenshot418 def initialize(bridge, id); end419 def ==(other); end420 def [](name); end421 def accessible_name; end422 def all(*args); end423 def aria_role; end424 def as_json(*_arg0); end425 def attribute(name); end426 def clear; end427 def click; end428 def css_value(prop); end429 def displayed?; end430 def dom_attribute(name); end431 def enabled?; end432 def eql?(other); end433 def first(*args); end434 def hash; end435 def inspect; end436 def location; end437 def location_once_scrolled_into_view; end438 def property(name); end439 def rect; end440 def ref; end441 def selected?; end442 def send_key(*args); end443 def send_keys(*args); end444 def shadow_root; end445 def size; end446 def style(prop); end447 def submit; end448 def tag_name; end449 def text; end450 def to_json(*_arg0); end451 private452 def bridge; end453 def screenshot; end454 def selectable?; end455end456Selenium::WebDriver::Element::ELEMENT_KEY = T.let(T.unsafe(nil), String)457module Selenium::WebDriver::Error458 class << self459 def for_error(error); end460 end461end462class Selenium::WebDriver::Error::DetachedShadowRootError < ::Selenium::WebDriver::Error::WebDriverError; end463class Selenium::WebDriver::Error::ElementClickInterceptedError < ::Selenium::WebDriver::Error::WebDriverError; end464class Selenium::WebDriver::Error::ElementNotInteractableError < ::Selenium::WebDriver::Error::WebDriverError; end465class Selenium::WebDriver::Error::InsecureCertificateError < ::Selenium::WebDriver::Error::WebDriverError; end466class Selenium::WebDriver::Error::InvalidArgumentError < ::Selenium::WebDriver::Error::WebDriverError; end467class Selenium::WebDriver::Error::InvalidCookieDomainError < ::Selenium::WebDriver::Error::WebDriverError; end468class Selenium::WebDriver::Error::InvalidElementStateError < ::Selenium::WebDriver::Error::WebDriverError; end469class Selenium::WebDriver::Error::InvalidSelectorError < ::Selenium::WebDriver::Error::WebDriverError; end470class Selenium::WebDriver::Error::InvalidSessionIdError < ::Selenium::WebDriver::Error::WebDriverError; end471class Selenium::WebDriver::Error::JavascriptError < ::Selenium::WebDriver::Error::WebDriverError; end472class Selenium::WebDriver::Error::MoveTargetOutOfBoundsError < ::Selenium::WebDriver::Error::WebDriverError; end473class Selenium::WebDriver::Error::NoSuchAlertError < ::Selenium::WebDriver::Error::WebDriverError; end474class Selenium::WebDriver::Error::NoSuchCookieError < ::Selenium::WebDriver::Error::WebDriverError; end475class Selenium::WebDriver::Error::NoSuchElementError < ::Selenium::WebDriver::Error::WebDriverError; end476class Selenium::WebDriver::Error::NoSuchFrameError < ::Selenium::WebDriver::Error::WebDriverError; end477class Selenium::WebDriver::Error::NoSuchShadowRootError < ::Selenium::WebDriver::Error::WebDriverError; end478class Selenium::WebDriver::Error::NoSuchWindowError < ::Selenium::WebDriver::Error::WebDriverError; end479class Selenium::WebDriver::Error::ScriptTimeoutError < ::Selenium::WebDriver::Error::WebDriverError; end480class Selenium::WebDriver::Error::ServerError < ::StandardError481 def initialize(response); end482end483class Selenium::WebDriver::Error::SessionNotCreatedError < ::Selenium::WebDriver::Error::WebDriverError; end484class Selenium::WebDriver::Error::StaleElementReferenceError < ::Selenium::WebDriver::Error::WebDriverError; end485class Selenium::WebDriver::Error::TimeoutError < ::Selenium::WebDriver::Error::WebDriverError; end486class Selenium::WebDriver::Error::UnableToCaptureScreenError < ::Selenium::WebDriver::Error::WebDriverError; end487class Selenium::WebDriver::Error::UnableToSetCookieError < ::Selenium::WebDriver::Error::WebDriverError; end488class Selenium::WebDriver::Error::UnexpectedAlertOpenError < ::Selenium::WebDriver::Error::WebDriverError; end489class Selenium::WebDriver::Error::UnknownCommandError < ::Selenium::WebDriver::Error::WebDriverError; end490class Selenium::WebDriver::Error::UnknownError < ::Selenium::WebDriver::Error::WebDriverError; end491class Selenium::WebDriver::Error::UnknownMethodError < ::Selenium::WebDriver::Error::WebDriverError; end492class Selenium::WebDriver::Error::UnsupportedOperationError < ::Selenium::WebDriver::Error::WebDriverError; end493class Selenium::WebDriver::Error::WebDriverError < ::StandardError; end494module Selenium::WebDriver::FileReaper495 class << self496 def <<(file); end497 def reap(file); end498 def reap!; end499 def reap=(_arg0); end500 def reap?; end501 def tmp_files; end502 end503end504module Selenium::WebDriver::Firefox505 class << self506 def driver_path; end507 def driver_path=(path); end508 def path; end509 def path=(path); end510 end511end512Selenium::WebDriver::Firefox::DEFAULT_ASSUME_UNTRUSTED_ISSUER = T.let(T.unsafe(nil), TrueClass)513Selenium::WebDriver::Firefox::DEFAULT_PORT = T.let(T.unsafe(nil), Integer)514Selenium::WebDriver::Firefox::DEVTOOLS_VERSION = T.let(T.unsafe(nil), Integer)515class Selenium::WebDriver::Firefox::Driver < ::Selenium::WebDriver::Driver516 def browser; end517 private518 def devtools_url; end519 def devtools_version; end520end521Selenium::WebDriver::Firefox::Driver::EXTENSIONS = T.let(T.unsafe(nil), Array)522class Selenium::WebDriver::Firefox::Extension523 def initialize(path); end524 def write_to(extensions_dir); end525 private526 def applications_gecko_id(manifest); end527 def create_root; end528 def name_and_version(manifest); end529 def read_id(directory); end530 def read_id_from_install_rdf(directory); end531 def read_id_from_manifest_json(directory); end532end533Selenium::WebDriver::Firefox::Extension::NAMESPACE = T.let(T.unsafe(nil), String)534module Selenium::WebDriver::Firefox::Features535 def commands(command); end536 def context; end537 def context=(context); end538 def full_screenshot; end539 def install_addon(path, temporary); end540 def uninstall_addon(id); end541end542Selenium::WebDriver::Firefox::Features::FIREFOX_COMMANDS = T.let(T.unsafe(nil), Hash)543class Selenium::WebDriver::Firefox::Options < ::Selenium::WebDriver::Options544 def initialize(log_level: T.unsafe(nil), **opts); end545 def add_argument(arg); end546 def add_preference(name, value); end547 def debugger_address; end548 def debugger_address=(_arg0); end549 def enable_android(package: T.unsafe(nil), serial_number: T.unsafe(nil), activity: T.unsafe(nil), intent_arguments: T.unsafe(nil)); end550 def headless!; end551 def log_level; end552 def log_level=(level); end553 def profile; end554 def profile=(profile); end555 private556 def camelize?(key); end557 def process_browser_options(browser_options); end558 def process_profile(profile); end559end560Selenium::WebDriver::Firefox::Options::BROWSER = T.let(T.unsafe(nil), String)561Selenium::WebDriver::Firefox::Options::CAPABILITIES = T.let(T.unsafe(nil), Hash)562Selenium::WebDriver::Firefox::Options::KEY = T.let(T.unsafe(nil), String)563class Selenium::WebDriver::Firefox::Profile564 include ::Selenium::WebDriver::ProfileHelper565 extend ::Selenium::WebDriver::ProfileHelper::ClassMethods566 def initialize(model = T.unsafe(nil)); end567 def []=(key, value); end568 def add_extension(path, name = T.unsafe(nil)); end569 def as_json; end570 def layout_on_disk; end571 def load_no_focus_lib=(_arg0); end572 def log_file; end573 def log_file=(file); end574 def name; end575 def port=(port); end576 def proxy=(proxy); end577 def secure_ssl=(_arg0); end578 private579 def delete_extensions_cache(directory); end580 def delete_lock_files(directory); end581 def extension_name_for(path); end582 def install_extensions(directory); end583 def read_model_prefs; end584 def read_user_prefs(path); end585 def set_manual_proxy_preference(key, value); end586 def stringified?(str); end587 def update_user_prefs_in(directory); end588 def write_prefs(prefs, path); end589 class << self590 def decoded(json); end591 def from_name(name); end592 def ini; end593 end594end595Selenium::WebDriver::Firefox::Profile::DEFAULT_PREFERENCES = T.let(T.unsafe(nil), Hash)596Selenium::WebDriver::Firefox::Profile::VALID_PREFERENCE_TYPES = T.let(T.unsafe(nil), Array)597class Selenium::WebDriver::Firefox::ProfilesIni598 def initialize; end599 def [](name); end600 def refresh; end601 private602 def parse; end603 def path_for(name, is_relative, path); end604end605class Selenium::WebDriver::Firefox::Service < ::Selenium::WebDriver::Service606 private607 def extract_service_args(driver_opts); end608end609Selenium::WebDriver::Firefox::Service::DEFAULT_PORT = T.let(T.unsafe(nil), Integer)610Selenium::WebDriver::Firefox::Service::EXECUTABLE = T.let(T.unsafe(nil), String)611Selenium::WebDriver::Firefox::Service::MISSING_TEXT = T.let(T.unsafe(nil), String)612module Selenium::WebDriver::HTML5; end613class Selenium::WebDriver::HTML5::LocalStorage614 include ::Enumerable615 include ::Selenium::WebDriver::HTML5::SharedWebStorage616 def initialize(bridge); end617 def [](key); end618 def []=(key, value); end619 def clear; end620 def delete(key); end621 def keys; end622 def size; end623end624class Selenium::WebDriver::HTML5::SessionStorage625 include ::Enumerable626 include ::Selenium::WebDriver::HTML5::SharedWebStorage627 def initialize(bridge); end628 def [](key); end629 def []=(key, value); end630 def clear; end631 def delete(key); end632 def keys; end633 def size; end634end635module Selenium::WebDriver::HTML5::SharedWebStorage636 include ::Enumerable637 def each; end638 def empty?; end639 def fetch(key); end640 def has_key?(key); end641 def key?(key); end642 def member?(key); end643end644module Selenium::WebDriver::IE645 class << self646 def driver_path; end647 def driver_path=(path); end648 end649end650class Selenium::WebDriver::IE::Driver < ::Selenium::WebDriver::Driver651 def browser; end652end653Selenium::WebDriver::IE::Driver::EXTENSIONS = T.let(T.unsafe(nil), Array)654class Selenium::WebDriver::IE::Options < ::Selenium::WebDriver::Options655 def initialize(**opts); end656 def add_argument(arg); end657 def args; end658 private659 def process_browser_options(browser_options); end660end661Selenium::WebDriver::IE::Options::BROWSER = T.let(T.unsafe(nil), String)662Selenium::WebDriver::IE::Options::CAPABILITIES = T.let(T.unsafe(nil), Hash)663Selenium::WebDriver::IE::Options::KEY = T.let(T.unsafe(nil), String)664Selenium::WebDriver::IE::Options::SCROLL_BOTTOM = T.let(T.unsafe(nil), Integer)665Selenium::WebDriver::IE::Options::SCROLL_TOP = T.let(T.unsafe(nil), Integer)666class Selenium::WebDriver::IE::Service < ::Selenium::WebDriver::Service667 private668 def extract_service_args(driver_opts); end669end670Selenium::WebDriver::IE::Service::DEFAULT_PORT = T.let(T.unsafe(nil), Integer)671Selenium::WebDriver::IE::Service::EXECUTABLE = T.let(T.unsafe(nil), String)672Selenium::WebDriver::IE::Service::MISSING_TEXT = T.let(T.unsafe(nil), String)673Selenium::WebDriver::IE::Service::SHUTDOWN_SUPPORTED = T.let(T.unsafe(nil), TrueClass)674module Selenium::WebDriver::Interactions675 class << self676 def key(name); end677 def none(name = T.unsafe(nil)); end678 def pointer(kind, **kwargs); end679 end680end681class Selenium::WebDriver::Interactions::InputDevice682 def initialize(name = T.unsafe(nil)); end683 def actions; end684 def add_action(action); end685 def clear_actions; end686 def create_pause(duration = T.unsafe(nil)); end687 def name; end688 def no_actions?; end689end690class Selenium::WebDriver::Interactions::Interaction691 def initialize(source); end692 def source; end693end694Selenium::WebDriver::Interactions::Interaction::PAUSE = T.let(T.unsafe(nil), Symbol)695Selenium::WebDriver::Interactions::KEY = T.let(T.unsafe(nil), Symbol)696class Selenium::WebDriver::Interactions::KeyInput < ::Selenium::WebDriver::Interactions::InputDevice697 def create_key_down(key); end698 def create_key_up(key); end699 def encode; end700 def type; end701end702Selenium::WebDriver::Interactions::KeyInput::SUBTYPES = T.let(T.unsafe(nil), Hash)703class Selenium::WebDriver::Interactions::KeyInput::TypingInteraction < ::Selenium::WebDriver::Interactions::Interaction704 def initialize(source, type, key); end705 def assert_type(type); end706 def encode; end707 def type; end708end709Selenium::WebDriver::Interactions::NONE = T.let(T.unsafe(nil), Symbol)710class Selenium::WebDriver::Interactions::NoneInput < ::Selenium::WebDriver::Interactions::InputDevice711 def encode; end712 def type; end713end714Selenium::WebDriver::Interactions::POINTER = T.let(T.unsafe(nil), Symbol)715class Selenium::WebDriver::Interactions::Pause < ::Selenium::WebDriver::Interactions::Interaction716 def initialize(source, duration = T.unsafe(nil)); end717 def encode; end718 def type; end719end720class Selenium::WebDriver::Interactions::PointerCancel < ::Selenium::WebDriver::Interactions::Interaction721 def encode; end722 def type; end723end724class Selenium::WebDriver::Interactions::PointerInput < ::Selenium::WebDriver::Interactions::InputDevice725 def initialize(kind, name: T.unsafe(nil)); end726 def assert_kind(pointer); end727 def create_pointer_cancel; end728 def create_pointer_down(button); end729 def create_pointer_move(duration: T.unsafe(nil), x: T.unsafe(nil), y: T.unsafe(nil), element: T.unsafe(nil), origin: T.unsafe(nil)); end730 def create_pointer_up(button); end731 def encode; end732 def kind; end733 def type; end734end735Selenium::WebDriver::Interactions::PointerInput::KIND = T.let(T.unsafe(nil), Hash)736class Selenium::WebDriver::Interactions::PointerMove < ::Selenium::WebDriver::Interactions::Interaction737 def initialize(source, duration, x, y, element: T.unsafe(nil), origin: T.unsafe(nil)); end738 def encode; end739 def type; end740end741Selenium::WebDriver::Interactions::PointerMove::ORIGINS = T.let(T.unsafe(nil), Array)742Selenium::WebDriver::Interactions::PointerMove::POINTER = T.let(T.unsafe(nil), Symbol)743Selenium::WebDriver::Interactions::PointerMove::VIEWPORT = T.let(T.unsafe(nil), Symbol)744class Selenium::WebDriver::Interactions::PointerPress < ::Selenium::WebDriver::Interactions::Interaction745 def initialize(source, direction, button); end746 def assert_button(button); end747 def assert_direction(direction); end748 def encode; end749 def type; end750end751Selenium::WebDriver::Interactions::PointerPress::BUTTONS = T.let(T.unsafe(nil), Hash)752Selenium::WebDriver::Interactions::PointerPress::DIRECTIONS = T.let(T.unsafe(nil), Hash)753Selenium::WebDriver::Interactions::SOURCE_TYPES = T.let(T.unsafe(nil), Array)754module Selenium::WebDriver::KeyActions755 def key_down(*args, device: T.unsafe(nil)); end756 def key_up(*args, device: T.unsafe(nil)); end757 def send_keys(*args, device: T.unsafe(nil)); end758 private759 def key_action(*args, action: T.unsafe(nil), device: T.unsafe(nil)); end760end761module Selenium::WebDriver::Keys762 class << self763 def [](key); end764 def encode(keys); end765 def encode_key(key); end766 end767end768Selenium::WebDriver::Keys::KEYS = T.let(T.unsafe(nil), Hash)769class Selenium::WebDriver::Location < ::Struct770 def altitude; end771 def altitude=(_); end772 def latitude; end773 def latitude=(_); end774 def longitude; end775 def longitude=(_); end776 class << self777 def [](*_arg0); end778 def inspect; end779 def keyword_init?; end780 def members; end781 def new(*_arg0); end782 end783end784class Selenium::WebDriver::LogEntry785 def initialize(level, timestamp, message); end786 def as_json(*_arg0); end787 def level; end788 def message; end789 def time; end790 def timestamp; end791 def to_s; end792end793class Selenium::WebDriver::Logger794 extend ::Forwardable795 def initialize(progname = T.unsafe(nil)); end796 def close(*args, **_arg1, &block); end797 def debug(*args, **_arg1, &block); end798 def debug?(*args, **_arg1, &block); end799 def deprecate(old, new = T.unsafe(nil), id: T.unsafe(nil), reference: T.unsafe(nil), &block); end800 def error(*args, **_arg1, &block); end801 def error?(*args, **_arg1, &block); end802 def fatal(*args, **_arg1, &block); end803 def fatal?(*args, **_arg1, &block); end804 def ignore(id); end805 def info(*args, **_arg1, &block); end806 def info?(*args, **_arg1, &block); end807 def io; end808 def level(*args, **_arg1, &block); end809 def level=(*args, **_arg1, &block); end810 def output=(io); end811 def warn(message, id: T.unsafe(nil)); end812 def warn?(*args, **_arg1, &block); end813 private814 def create_logger(name); end815 def default_level; end816end817class Selenium::WebDriver::Logs818 def initialize(bridge); end819 def available_types; end820 def get(type); end821end822class Selenium::WebDriver::Manager823 def initialize(bridge); end824 def add_cookie(opts = T.unsafe(nil)); end825 def all_cookies; end826 def cookie_named(name); end827 def delete_all_cookies; end828 def delete_cookie(name); end829 def logs; end830 def new_window(type = T.unsafe(nil)); end831 def timeouts; end832 def window; end833 private834 def convert_cookie(cookie); end835 def datetime_at(int); end836 def seconds_from(obj); end837 def strip_port(str); end838end839Selenium::WebDriver::Manager::SECONDS_PER_DAY = T.let(T.unsafe(nil), Float)840class Selenium::WebDriver::Navigation841 def initialize(bridge); end842 def back; end843 def forward; end844 def refresh; end845 def to(url); end846end847class Selenium::WebDriver::Options848 def initialize(options: T.unsafe(nil), **opts); end849 def ==(other); end850 def add_option(name, value = T.unsafe(nil)); end851 def as_json(*_arg0); end852 def eql?(other); end853 def options; end854 def options=(_arg0); end855 private856 def camel_case(str); end857 def camelize?(_key); end858 def convert_json_key(key, camelize: T.unsafe(nil)); end859 def generate_as_json(value, camelize_keys: T.unsafe(nil)); end860 def process_browser_options(_browser_options); end861 def process_json_hash(value, camelize_keys); end862 def process_w3c_options(options); end863 def w3c?(key); end864 class << self865 def chrome(**opts); end866 def driver_path; end867 def edge(**opts); end868 def firefox(**opts); end869 def ie(**opts); end870 def internet_explorer(**opts); end871 def microsoftedge(**opts); end872 def safari(**opts); end873 def set_capabilities; end874 end875end876Selenium::WebDriver::Options::W3C_OPTIONS = T.let(T.unsafe(nil), Array)877module Selenium::WebDriver::Platform878 private879 def assert_executable(path); end880 def assert_file(path); end881 def bitsize; end882 def ci; end883 def cygwin?; end884 def cygwin_path(path, **opts); end885 def engine; end886 def exit_hook; end887 def find_binary(*binary_names); end888 def find_in_program_files(*binary_names); end889 def home; end890 def interfaces; end891 def ip; end892 def jruby?; end893 def linux?; end894 def localhost; end895 def mac?; end896 def make_writable(file); end897 def null_device; end898 def os; end899 def ruby_version; end900 def unix_path(path); end901 def windows?; end902 def windows_path(path); end903 def wrap_in_quotes_if_necessary(str); end904 def wsl?; end905 class << self906 def assert_executable(path); end907 def assert_file(path); end908 def bitsize; end909 def ci; end910 def cygwin?; end911 def cygwin_path(path, **opts); end912 def engine; end913 def exit_hook; end914 def find_binary(*binary_names); end915 def find_in_program_files(*binary_names); end916 def home; end917 def interfaces; end918 def ip; end919 def jruby?; end920 def linux?; end921 def localhost; end922 def mac?; end923 def make_writable(file); end924 def null_device; end925 def os; end926 def ruby_version; end927 def unix_path(path); end928 def windows?; end929 def windows_path(path); end930 def wrap_in_quotes_if_necessary(str); end931 def wsl?; end932 end933end934class Selenium::WebDriver::Point < ::Struct935 def x; end936 def x=(_); end937 def y; end938 def y=(_); end939 class << self940 def [](*_arg0); end941 def inspect; end942 def keyword_init?; end943 def members; end944 def new(*_arg0); end945 end946end947module Selenium::WebDriver::PointerActions948 def click(element = T.unsafe(nil), device: T.unsafe(nil)); end949 def click_and_hold(element = T.unsafe(nil), device: T.unsafe(nil)); end950 def context_click(element = T.unsafe(nil), device: T.unsafe(nil)); end951 def default_move_duration; end952 def default_move_duration=(_arg0); end953 def double_click(element = T.unsafe(nil), device: T.unsafe(nil)); end954 def drag_and_drop(source, target, device: T.unsafe(nil)); end955 def drag_and_drop_by(source, right_by, down_by, device: T.unsafe(nil)); end956 def move_by(right_by, down_by, device: T.unsafe(nil)); end957 def move_to(element, right_by = T.unsafe(nil), down_by = T.unsafe(nil), device: T.unsafe(nil)); end958 def move_to_location(x, y, device: T.unsafe(nil)); end959 def pointer_down(button, device: T.unsafe(nil)); end960 def pointer_up(button, device: T.unsafe(nil)); end961 def release(device: T.unsafe(nil)); end962 private963 def button_action(button, action: T.unsafe(nil), device: T.unsafe(nil)); end964 def get_pointer(device = T.unsafe(nil)); end965end966class Selenium::WebDriver::PortProber967 class << self968 def above(port); end969 def free?(port); end970 end971end972Selenium::WebDriver::PortProber::IGNORED_ERRORS = T.let(T.unsafe(nil), Array)973module Selenium::WebDriver::ProfileHelper974 mixes_in_class_methods ::Selenium::WebDriver::ProfileHelper::ClassMethods975 def as_json(*_arg0); end976 def encoded; end977 def to_json(*_arg0); end978 private979 def create_tmp_copy(directory); end980 def verify_model(model); end981 class << self982 def decoded(json); end983 def included(base); end984 end985end986module Selenium::WebDriver::ProfileHelper::ClassMethods987 def from_json(json); end988end989class Selenium::WebDriver::Proxy990 def initialize(opts = T.unsafe(nil)); end991 def ==(other); end992 def as_json(*_arg0); end993 def auto_detect; end994 def auto_detect=(bool); end995 def eql?(other); end996 def ftp; end997 def ftp=(value); end998 def http; end999 def http=(value); end1000 def no_proxy; end1001 def no_proxy=(value); end1002 def pac; end1003 def pac=(url); end1004 def socks; end1005 def socks=(value); end1006 def socks_password; end1007 def socks_password=(value); end1008 def socks_username; end1009 def socks_username=(value); end1010 def socks_version; end1011 def socks_version=(value); end1012 def ssl; end1013 def ssl=(value); end1014 def to_json(*_arg0); end1015 def type; end1016 def type=(type); end1017 class << self1018 def json_create(data); end1019 end1020end1021Selenium::WebDriver::Proxy::ALLOWED = T.let(T.unsafe(nil), Hash)1022Selenium::WebDriver::Proxy::TYPES = T.let(T.unsafe(nil), Hash)1023class Selenium::WebDriver::Rectangle < ::Struct1024 def height; end1025 def height=(_); end1026 def width; end1027 def width=(_); end1028 def x; end1029 def x=(_); end1030 def y; end1031 def y=(_); end1032 class << self1033 def [](*_arg0); end1034 def inspect; end1035 def keyword_init?; end1036 def members; end1037 def new(*_arg0); end1038 end1039end1040module Selenium::WebDriver::Remote; end1041class Selenium::WebDriver::Remote::Bridge1042 include ::Selenium::WebDriver::Atoms1043 def initialize(url:, http_client: T.unsafe(nil)); end1044 def accept_alert; end1045 def action(async = T.unsafe(nil)); end1046 def actions(async = T.unsafe(nil)); end1047 def active_element; end1048 def add_cookie(cookie); end1049 def alert=(keys); end1050 def alert_text; end1051 def browser; end1052 def capabilities; end1053 def clear_element(element); end1054 def clear_local_storage; end1055 def clear_session_storage; end1056 def click_element(element); end1057 def close; end1058 def cookie(name); end1059 def cookies; end1060 def create_session(capabilities); end1061 def delete_all_cookies; end1062 def delete_cookie(name); end1063 def dismiss_alert; end1064 def element_aria_label(element); end1065 def element_aria_role(element); end1066 def element_attribute(element, name); end1067 def element_displayed?(element); end1068 def element_dom_attribute(element, name); end1069 def element_enabled?(element); end1070 def element_location(element); end1071 def element_location_once_scrolled_into_view(element); end1072 def element_property(element, name); end1073 def element_rect(element); end1074 def element_screenshot(element); end1075 def element_selected?(element); end1076 def element_size(element); end1077 def element_tag_name(element); end1078 def element_text(element); end1079 def element_value(element); end1080 def element_value_of_css_property(element, prop); end1081 def execute_async_script(script, *args); end1082 def execute_script(script, *args); end1083 def file_detector; end1084 def file_detector=(_arg0); end1085 def find_element_by(how, what, parent_ref = T.unsafe(nil)); end1086 def find_elements_by(how, what, parent_ref = T.unsafe(nil)); end1087 def full_screen_window; end1088 def get(url); end1089 def go_back; end1090 def go_forward; end1091 def http; end1092 def http=(_arg0); end1093 def keyboard; end1094 def local_storage_item(key, value = T.unsafe(nil)); end1095 def local_storage_keys; end1096 def local_storage_size; end1097 def manage; end1098 def maximize_window(handle = T.unsafe(nil)); end1099 def minimize_window; end1100 def mouse; end1101 def new_window(type); end1102 def page_source; end1103 def print_page(options = T.unsafe(nil)); end1104 def quit; end1105 def refresh; end1106 def release_actions; end1107 def remove_local_storage_item(key); end1108 def remove_session_storage_item(key); end1109 def reposition_window(x, y); end1110 def resize_window(width, height, handle = T.unsafe(nil)); end1111 def screenshot; end1112 def send_actions(data); end1113 def send_keys_to_element(element, keys); end1114 def session_id; end1115 def session_storage_item(key, value = T.unsafe(nil)); end1116 def session_storage_keys; end1117 def session_storage_size; end1118 def set_window_rect(x: T.unsafe(nil), y: T.unsafe(nil), width: T.unsafe(nil), height: T.unsafe(nil)); end1119 def shadow_root(element); end1120 def status; end1121 def submit_element(element); end1122 def switch_to_active_element; end1123 def switch_to_default_content; end1124 def switch_to_frame(id); end1125 def switch_to_parent_frame; end1126 def switch_to_window(name); end1127 def timeouts; end1128 def timeouts=(timeouts); end1129 def title; end1130 def upload(local_file); end1131 def url; end1132 def window_handle; end1133 def window_handles; end1134 def window_position; end1135 def window_rect; end1136 def window_size(handle = T.unsafe(nil)); end1137 private1138 def commands(command); end1139 def convert_locator(how, what); end1140 def element_id_from(id); end1141 def escape_css(string); end1142 def escaper; end1143 def execute(command, opts = T.unsafe(nil), command_hash = T.unsafe(nil)); end1144 def prepare_capabilities_payload(capabilities); end1145 def shadow_root_id_from(id); end1146 def unwrap_script_result(arg); end1147end1148Selenium::WebDriver::Remote::Bridge::COMMANDS = T.let(T.unsafe(nil), Hash)1149Selenium::WebDriver::Remote::Bridge::ESCAPE_CSS_REGEXP = T.let(T.unsafe(nil), Regexp)1150Selenium::WebDriver::Remote::Bridge::PORT = T.let(T.unsafe(nil), Integer)1151Selenium::WebDriver::Remote::Bridge::QUIT_ERRORS = T.let(T.unsafe(nil), Array)1152Selenium::WebDriver::Remote::Bridge::UNICODE_CODE_POINT = T.let(T.unsafe(nil), Integer)1153class Selenium::WebDriver::Remote::Capabilities1154 def initialize(opts = T.unsafe(nil)); end1155 def ==(other); end1156 def [](key); end1157 def []=(key, value); end1158 def accept_insecure_certs; end1159 def accept_insecure_certs=(value); end1160 def as_json(*_arg0); end1161 def browser_name; end1162 def browser_name=(value); end1163 def browser_version; end1164 def browser_version=(value); end1165 def eql?(other); end1166 def implicit_timeout; end1167 def implicit_timeout=(timeout); end1168 def merge!(other); end1169 def page_load_strategy; end1170 def page_load_strategy=(value); end1171 def page_load_timeout; end1172 def page_load_timeout=(timeout); end1173 def platform; end1174 def platform=(value); end1175 def platform_name; end1176 def platform_name=(value); end1177 def proxy; end1178 def proxy=(proxy); end1179 def remote_session_id; end1180 def remote_session_id=(value); end1181 def script_timeout; end1182 def script_timeout=(timeout); end1183 def set_window_rect; end1184 def set_window_rect=(value); end1185 def strict_file_interactability; end1186 def strict_file_interactability=(value); end1187 def timeouts; end1188 def timeouts=(timeouts); end1189 def to_json(*_arg0); end1190 def unhandled_prompt_behavior; end1191 def unhandled_prompt_behavior=(value); end1192 def version; end1193 def version=(value); end1194 def web_socket_url; end1195 def web_socket_url=(value); end1196 protected1197 def capabilities; end1198 private1199 def convert_key(key); end1200 def convert_value(key, value); end1201 def process_capabilities(key, value, hash); end1202 class << self1203 def always_match(capabilities); end1204 def camel_case(str_or_sym); end1205 def chrome(opts = T.unsafe(nil)); end1206 def edge(opts = T.unsafe(nil)); end1207 def ff(opts = T.unsafe(nil)); end1208 def firefox(opts = T.unsafe(nil)); end1209 def first_match(*capabilities); end1210 def htmlunit(opts = T.unsafe(nil)); end1211 def ie(opts = T.unsafe(nil)); end1212 def internet_explorer(opts = T.unsafe(nil)); end1213 def json_create(data); end1214 def microsoftedge(opts = T.unsafe(nil)); end1215 def safari(opts = T.unsafe(nil)); end1216 private1217 def process_timeouts(caps, timeouts); end1218 end1219end1220Selenium::WebDriver::Remote::Capabilities::KNOWN = T.let(T.unsafe(nil), Array)1221class Selenium::WebDriver::Remote::Driver < ::Selenium::WebDriver::Driver1222 include ::Selenium::WebDriver::DriverExtensions::UploadsFiles1223 include ::Selenium::WebDriver::DriverExtensions::HasSessionId1224 include ::Selenium::WebDriver::DriverExtensions::HasRemoteStatus1225 def initialize(bridge: T.unsafe(nil), listener: T.unsafe(nil), **opts); end1226 private1227 def devtools_url; end1228 def devtools_version; end1229end1230module Selenium::WebDriver::Remote::Http; end1231class Selenium::WebDriver::Remote::Http::Common1232 def call(verb, url, command_hash); end1233 def close; end1234 def quit_errors; end1235 def server_url=(_arg0); end1236 private1237 def create_response(code, body, content_type); end1238 def request(*_arg0); end1239 def server_url; end1240end1241Selenium::WebDriver::Remote::Http::Common::CONTENT_TYPE = T.let(T.unsafe(nil), String)1242Selenium::WebDriver::Remote::Http::Common::DEFAULT_HEADERS = T.let(T.unsafe(nil), Hash)1243Selenium::WebDriver::Remote::Http::Common::MAX_REDIRECTS = T.let(T.unsafe(nil), Integer)1244class Selenium::WebDriver::Remote::Http::Default < ::Selenium::WebDriver::Remote::Http::Common1245 def initialize(open_timeout: T.unsafe(nil), read_timeout: T.unsafe(nil)); end1246 def close; end1247 def open_timeout; end1248 def open_timeout=(_arg0); end1249 def proxy=(_arg0); end1250 def read_timeout; end1251 def read_timeout=(_arg0); end1252 private1253 def http; end1254 def new_http_client; end1255 def new_request_for(verb, url, headers, payload); end1256 def proxy; end1257 def request(verb, url, headers, payload, redirects = T.unsafe(nil)); end1258 def response_for(request); end1259 def start(http); end1260 def use_proxy?; end1261end1262Selenium::WebDriver::Remote::Http::Default::MAX_RETRIES = T.let(T.unsafe(nil), Integer)1263class Selenium::WebDriver::Remote::Response1264 def initialize(code, payload = T.unsafe(nil)); end1265 def [](key); end1266 def code; end1267 def error; end1268 def payload; end1269 private1270 def add_backtrace(ex, server_trace); end1271 def assert_ok; end1272 def backtrace_from_remote(server_trace); end1273 def process_error; end1274end1275module Selenium::WebDriver::Safari1276 class << self1277 def driver_path; end1278 def driver_path=(path); end1279 def path; end1280 def path=(path); end1281 def technology_preview; end1282 def technology_preview!; end1283 def technology_preview?; end1284 def use_technology_preview; end1285 def use_technology_preview=(_arg0); end1286 end1287end1288class Selenium::WebDriver::Safari::Driver < ::Selenium::WebDriver::Driver1289 def browser; end1290end1291Selenium::WebDriver::Safari::Driver::EXTENSIONS = T.let(T.unsafe(nil), Array)1292module Selenium::WebDriver::Safari::Features1293 def attach_debugger; end1294 def commands(command); end1295 def permissions; end1296 def permissions=(permissions); end1297end1298Selenium::WebDriver::Safari::Features::SAFARI_COMMANDS = T.let(T.unsafe(nil), Hash)1299class Selenium::WebDriver::Safari::Options < ::Selenium::WebDriver::Options1300 def add_option(name, value = T.unsafe(nil)); end1301 def options; end1302 def options=(_arg0); end1303end1304Selenium::WebDriver::Safari::Options::BROWSER = T.let(T.unsafe(nil), String)1305Selenium::WebDriver::Safari::Options::CAPABILITIES = T.let(T.unsafe(nil), Hash)1306class Selenium::WebDriver::Safari::Service < ::Selenium::WebDriver::Service; end1307Selenium::WebDriver::Safari::Service::DEFAULT_PORT = T.let(T.unsafe(nil), Integer)1308Selenium::WebDriver::Safari::Service::EXECUTABLE = T.let(T.unsafe(nil), String)1309Selenium::WebDriver::Safari::Service::MISSING_TEXT = T.let(T.unsafe(nil), String)1310module Selenium::WebDriver::SearchContext1311 def find_element(*args); end1312 def find_elements(*args); end1313 private1314 def extract_args(args); end1315end1316Selenium::WebDriver::SearchContext::FINDERS = T.let(T.unsafe(nil), Hash)1317class Selenium::WebDriver::Service1318 def initialize(path: T.unsafe(nil), port: T.unsafe(nil), args: T.unsafe(nil)); end1319 def executable_path; end1320 def extra_args; end1321 def host; end1322 def host=(_arg0); end1323 def launch; end1324 def port; end1325 def shutdown_supported; end1326 protected1327 def extract_service_args(driver_opts); end1328 private1329 def binary_path(path = T.unsafe(nil)); end1330 class << self1331 def chrome(**opts); end1332 def driver_path; end1333 def driver_path=(path); end1334 def edge(**opts); end1335 def firefox(**opts); end1336 def ie(**opts); end1337 def internet_explorer(**opts); end1338 def microsoftedge(**opts); end1339 def safari(**opts); end1340 end1341end1342class Selenium::WebDriver::ServiceManager1343 def initialize(config); end1344 def start; end1345 def stop; end1346 def uri; end1347 private1348 def build_process(*command); end1349 def cannot_connect_error_text; end1350 def connect_to_server; end1351 def connect_until_stable; end1352 def find_free_port; end1353 def process_exited?; end1354 def process_running?; end1355 def socket_lock; end1356 def start_process; end1357 def stop_process; end1358 def stop_server; end1359end1360Selenium::WebDriver::ServiceManager::SOCKET_LOCK_TIMEOUT = T.let(T.unsafe(nil), Integer)1361Selenium::WebDriver::ServiceManager::START_TIMEOUT = T.let(T.unsafe(nil), Integer)1362Selenium::WebDriver::ServiceManager::STOP_TIMEOUT = T.let(T.unsafe(nil), Integer)1363class Selenium::WebDriver::ShadowRoot1364 include ::Selenium::WebDriver::SearchContext1365 def initialize(bridge, id); end1366 def ==(other); end1367 def as_json(*_arg0); end1368 def eql?(other); end1369 def hash; end1370 def inspect; end1371 def ref; end1372 def to_json(*_arg0); end1373 private1374 def bridge; end1375end1376Selenium::WebDriver::ShadowRoot::ROOT_KEY = T.let(T.unsafe(nil), String)1377class Selenium::WebDriver::SocketLock1378 def initialize(port, timeout); end1379 def locked; end1380 private1381 def can_lock?; end1382 def current_time; end1383 def did_lock?; end1384 def lock; end1385 def release; end1386end1387class Selenium::WebDriver::SocketPoller1388 def initialize(host, port, timeout = T.unsafe(nil), interval = T.unsafe(nil)); end1389 def closed?; end1390 def connected?; end1391 private1392 def conn_completed?(sock); end1393 def current_time; end1394 def listening?; end1395 def socket_writable?(sock); end1396 def with_timeout; end1397end1398Selenium::WebDriver::SocketPoller::CONNECTED_ERRORS = T.let(T.unsafe(nil), Array)1399Selenium::WebDriver::SocketPoller::CONNECT_TIMEOUT = T.let(T.unsafe(nil), Integer)1400Selenium::WebDriver::SocketPoller::NOT_CONNECTED_ERRORS = T.let(T.unsafe(nil), Array)1401module Selenium::WebDriver::Support; end1402class Selenium::WebDriver::Support::AbstractEventListener1403 def after_change_value_of(element, driver); end1404 def after_click(element, driver); end1405 def after_close(driver); end1406 def after_execute_script(script, driver); end1407 def after_find(by, what, driver); end1408 def after_navigate_back(driver); end1409 def after_navigate_forward(driver); end1410 def after_navigate_to(url, driver); end1411 def after_quit(driver); end1412 def before_change_value_of(element, driver); end1413 def before_click(element, driver); end1414 def before_close(driver); end1415 def before_execute_script(script, driver); end1416 def before_find(by, what, driver); end1417 def before_navigate_back(driver); end1418 def before_navigate_forward(driver); end1419 def before_navigate_to(url, driver); end1420 def before_quit(driver); end1421end1422class Selenium::WebDriver::Support::BlockEventListener1423 def initialize(callback); end1424 def method_missing(meth, *args); end1425end1426class Selenium::WebDriver::Support::Color1427 def initialize(red, green, blue, alpha = T.unsafe(nil)); end1428 def ==(other); end1429 def alpha; end1430 def blue; end1431 def eql?(other); end1432 def green; end1433 def hash; end1434 def hex; end1435 def red; end1436 def rgb; end1437 def rgba; end1438 class << self1439 def from_hsl(h, s, l, a); end1440 def from_string(str); end1441 def hue_to_rgb(lum1, lum2, hue); end1442 end1443end1444Selenium::WebDriver::Support::Color::HEX3_PATTERN = T.let(T.unsafe(nil), Regexp)1445Selenium::WebDriver::Support::Color::HEX_PATTERN = T.let(T.unsafe(nil), Regexp)1446Selenium::WebDriver::Support::Color::HSLA_PATTERN = T.let(T.unsafe(nil), Regexp)1447Selenium::WebDriver::Support::Color::HSL_PATTERN = T.let(T.unsafe(nil), Regexp)1448Selenium::WebDriver::Support::Color::RGBA_PATTERN = T.let(T.unsafe(nil), Regexp)1449Selenium::WebDriver::Support::Color::RGBA_PCT_PATTERN = T.let(T.unsafe(nil), Regexp)1450Selenium::WebDriver::Support::Color::RGB_PATTERN = T.let(T.unsafe(nil), Regexp)1451Selenium::WebDriver::Support::Color::RGB_PCT_PATTERN = T.let(T.unsafe(nil), Regexp)1452module Selenium::WebDriver::Support::Escaper1453 class << self1454 def escape(str); end1455 end1456end1457class Selenium::WebDriver::Support::EventFiringBridge1458 def initialize(delegate, listener); end1459 def clear_element(ref); end1460 def click_element(ref); end1461 def close; end1462 def execute_script(script, *args); end1463 def find_element_by(how, what, parent = T.unsafe(nil)); end1464 def find_elements_by(how, what, parent = T.unsafe(nil)); end1465 def get(url); end1466 def go_back; end1467 def go_forward; end1468 def quit; end1469 def send_keys_to_element(ref, keys); end1470 private1471 def create_element(ref); end1472 def dispatch(name, *args); end1473 def driver; end1474 def method_missing(meth, *args, &blk); end1475end1476class Selenium::WebDriver::Support::RelativeLocator1477 def initialize(locator); end1478 def as_json; end1479end1480Selenium::WebDriver::Support::RelativeLocator::KEYS = T.let(T.unsafe(nil), Array)1481class Selenium::WebDriver::Support::Select1482 def initialize(element); end1483 def deselect_all; end1484 def deselect_by(how, what); end1485 def first_selected_option; end1486 def multiple?; end1487 def options; end1488 def select_all; end1489 def select_by(how, what); end1490 def selected_options; end1491 private1492 def deselect_by_index(index); end1493 def deselect_by_text(text); end1494 def deselect_by_value(value); end1495 def deselect_option(option); end1496 def deselect_options(opts); end1497 def find_by_index(index); end1498 def find_by_text(text); end1499 def find_by_value(value); end1500 def select_by_index(index); end1501 def select_by_text(text); end1502 def select_by_value(value); end1503 def select_option(option); end1504 def select_options(opts); end1505end1506module Selenium::WebDriver::TakesScreenshot1507 def save_screenshot(png_path, full_page: T.unsafe(nil)); end1508 def screenshot_as(format, full_page: T.unsafe(nil)); end1509end1510class Selenium::WebDriver::TargetLocator1511 def initialize(bridge); end1512 def active_element; end1513 def alert; end1514 def default_content; end1515 def frame(id); end1516 def new_window(type = T.unsafe(nil)); end1517 def parent_frame; end1518 def window(id); end...
selenium_spec_safari.rb
Source:selenium_spec_safari.rb
...9 ::Selenium::WebDriver::Safari::Service10else11 ::Selenium::WebDriver::Safari12end.driver_path = '/Applications/Safari Technology Preview.app/Contents/MacOS/safaridriver'13browser_options = ::Selenium::WebDriver::Safari::Options.new14# browser_options.headless! if ENV['HEADLESS']15# browser_options.add_option(:w3c, !!ENV['W3C'])16Capybara.register_driver :selenium_safari do |app|17 Capybara::Selenium::Driver.new(app, browser: :safari, options: browser_options, timeout: 30).tap do |driver|18 # driver.browser.download_path = Capybara.save_path19 end20end21Capybara.register_driver :selenium_safari_not_clear_storage do |app|22 safari_options = {23 browser: :safari,24 options: browser_options25 }26 Capybara::Selenium::Driver.new(app, safari_options.merge(clear_local_storage: false, clear_session_storage: false))27end28module TestSessions29 Safari = Capybara::Session.new(SAFARI_DRIVER, TestApp)30end31skipped_tests = %i[response_headers status_code trigger windows drag]32Capybara::SpecHelper.log_selenium_driver_version(Selenium::WebDriver::Safari) if ENV['CI']33Capybara::SpecHelper.run_specs TestSessions::Safari, SAFARI_DRIVER.to_s, capybara_skip: skipped_tests do |example|34 case example.metadata[:full_description]35 when /click_link can download a file/36 skip "safaridriver doesn't provide a way to set the download directory"37 when /Capybara::Session selenium_safari Capybara::Window#maximize/38 pending "Safari headless doesn't support maximize" if ENV['HEADLESS']39 when /Capybara::Session selenium_safari #visit without a server/,40 /Capybara::Session selenium_safari #visit with Capybara.app_host set should override server/,...
selenium_spec_ie.rb
Source:selenium_spec_ie.rb
...21 ENV.fetch('SERVER_HOST', '10.24.4.135')22end23Capybara.register_driver :selenium_ie do |app|24 # ::Selenium::WebDriver.logger.level = "debug"25 options = ::Selenium::WebDriver::IE::Options.new26 # options.require_window_focus = true27 # options.add_option("log", {"level": "trace"})28 if ENV['REMOTE']29 Capybara.server_host = server_host30 url = "http://#{selenium_host}:#{selenium_port}/wd/hub"31 Capybara::Selenium::Driver.new(app,32 browser: :remote,33 options: options,34 url: url)35 else36 Capybara::Selenium::Driver.new(37 app,38 browser: :ie,39 options: options40 )41 end42end43module TestSessions44 SeleniumIE = Capybara::Session.new(:selenium_ie, TestApp)45end46TestSessions::SeleniumIE.current_window.resize_to(800, 500)47skipped_tests = %i[response_headers status_code trigger modals hover form_attribute windows]48Capybara::SpecHelper.log_selenium_driver_version(Selenium::WebDriver::IE) if ENV['CI']49TestSessions::SeleniumIE.current_window.resize_to(1600, 1200)50Capybara::SpecHelper.run_specs TestSessions::SeleniumIE, 'selenium', capybara_skip: skipped_tests do |example|51 case example.metadata[:full_description]52 when /#refresh it reposts$/53 skip 'IE insists on prompting without providing a way to suppress'54 when /#click_link can download a file$/55 skip 'Not sure how to configure IE for automatic downloading'56 when /#fill_in with Date /57 pending "IE 11 doesn't support date input types"58 when /#click_link_or_button with :disabled option happily clicks on links which incorrectly have the disabled attribute$/59 skip 'IE 11 obeys non-standard disabled attribute on anchor tag'60 when /#right_click should allow modifiers$/61 skip "Windows can't :meta click because :meta triggers start menu"62 when /#click should allow modifiers$/63 pending "Doesn't work with IE for some unknown reason$"64 when /#double_click should allow modifiers$/65 pending "Doesn't work with IE for some unknown reason$"66 when /#click should allow multiple modifiers$/67 skip "Windows can't :meta click because :meta triggers start menu"68 when /#double_click should allow multiple modifiers$/69 skip "Windows can't :alt double click due to being properties shortcut"70 when /#has_css\? should support case insensitive :class and :id options$/71 pending "IE doesn't support case insensitive CSS selectors"72 when /#reset_session! removes ALL cookies$/73 pending "IE driver doesn't provide a way to remove ALL cookies"74 when /#click_button should send button in document order$/75 pending "IE 11 doesn't support the 'form' attribute"76 when /#click_button should follow permanent redirects that maintain method$/77 pending "Window 7 and 8.1 don't support 308 http status code"78 when /#scroll_to can scroll an element to the center of the viewport$/,79 /#scroll_to can scroll an element to the center of the scrolling element$/80 pending " IE doesn't support ScrollToOptions"81 when /#attach_file with multipart form should fire change once for each set of files uploaded$/,82 /#attach_file with multipart form should fire change once when uploading multiple files from empty$/,83 /#attach_file with multipart form should not break when using HTML5 multiple file input uploading multiple files$/84 pending "IE requires all files be uploaded from same directory. Selenium doesn't provide that." if ENV['REMOTE']...
options
Using AI Code Generation
1 @driver.get(@base_url + "/")2 @driver.find_element(:id, "gbqfq").clear3 @driver.find_element(:id, "gbqfq").send_keys "Selenium"4 @driver.find_element(:id, "gbqfb").click5 @driver.find_element(:link, "Selenium - Web Browser Automation").click6 @driver.find_element(:link, "Downloads").click7 @driver.find_element(:link, "Download").click8 @driver.find_element(:link, "Download").click9 @driver.find_element(:link, "Download").click10 @driver.find_element(:link, "Download").click11 @driver.find_element(:link, "Download").click12 @driver.get(@base_url + "/")13 @driver.find_element(:id, "gbqfq").clear14 @driver.find_element(:id, "gbqfq").send_keys "Selenium"15 @driver.find_element(:id, "gbqfb").click16 @driver.find_element(:link, "Selenium - Web Browser Automation").click17 @driver.find_element(:link, "Downloads").click18 @driver.find_element(:link, "Download").click19 @driver.find_element(:link
options
Using AI Code Generation
1options.add_argument('--disable-notifications')2driver = Selenium::WebDriver.for :chrome, options: Selenium::WebDriver::Chrome::Options.new(args: ['disable-notifications'])3capabilities = Selenium::WebDriver::Remote::Capabilities.chrome('chromeOptions' => {'args' => ['disable-notifications']})4capabilities = Selenium::WebDriver::Remote::Capabilities.chrome('chromeOptions' => {'prefs' => {'profile' => {'default_content_setting_values' => {'notifications' => 2}}}})5options.add_preference(:profile, default_content_setting_values: {notifications: 2})6options.add_preference(:profile, default_content_setting_values: {notifications: 1})7options.add_preference(:profile, default_content_setting_values: {notifications: 0})
options
Using AI Code Generation
1wait = Selenium::WebDriver::Wait.new(:timeout => 10)2wait.until {driver.find_element(:id, "lst-ib").displayed?}3driver.find_element(:id, "lst-ib").send_keys "Selenium webdriver"4wait.until {driver.find_element(:name, "btnK").displayed?}5driver.find_element(:name, "btnK").click6wait.until {driver.find_element(:partial_link_text, "Selenium - Web Browser Automation").displayed?}7driver.find_element(:partial_link_text, "Selenium - Web Browser Automation").click8wait.until {driver.find_element(:xpath, "//a[text()='Download']").displayed?}9driver.find_element(:xpath, "//a[text()='Download']").click10wait.until {driver.find_element(:link_text, "Downloads").displayed?}11driver.find_element(:link_text, "Downloads").click12wait.until {driver.find_element(:xpath, "//a[text()='Download']").displayed?}13driver.find_element(:xpath, "//a[text()='Download']").click14wait.until {driver.find_element(:link_text, "Downloads").displayed?}15driver.find_element(:link_text, "Downloads").click16wait.until {driver.find_element(:xpath, "//a[text()='Download']").displayed?}17driver.find_element(:xpath, "//a[text()='Download']").click18wait.until {driver.find_element(:link_text, "Downloads").displayed?}19driver.find_element(:link_text, "Downloads").click20wait.until {driver.find_element(:xpath, "//a[text()='Download']").displayed?}21driver.find_element(:xpath, "//a[text()='Download']").click22wait.until {driver.find_element(:link_text, "Downloads").displayed?}23driver.find_element(:link_text, "Downloads").click24wait.until {driver.find_element(:xpath, "//a[text()='Download']").displayed?}25driver.find_element(:xpath, "//a[text()='Download']").click26wait.until {driver.find_element(:link_text, "Downloads").displayed?}27driver.find_element(:link_text, "Downloads").click28wait.until {driver.find_element(:xpath
options
Using AI Code Generation
1driver.find_element(:name, 'q').send_keys('Selenium')2driver.find_element(:name, 'btnK').click3driver.find_element(:name, 'q').send_keys('Selenium')4driver.find_element(:name, 'btnK').click5driver.find_element(:name, 'q').send_keys('Selenium')6driver.find_element(:name, 'btnK').click7driver.find_element(:name, 'q').send_keys('Selenium')8driver.find_element(:name, 'btnK').click9driver.find_element(:name, 'q').send_keys('Selenium')10driver.find_element(:name, 'btnK').click
options
Using AI Code Generation
1element = driver.find_element(:name, 'q')2element = driver.find_element(:name, 'q')3element = driver.find_element(:name, 'q')4element = driver.find_element(:name, 'q')5element = driver.find_element(:name, 'q')6element = driver.find_element(:name, 'q')
options
Using AI Code Generation
1options.add_argument('--headless')2options.add_argument('--disable-gpu')3options.add_argument('--no-sandbox')4options.add_argument('--disable-dev-shm-usage')5options.add_argument('--disable-extensions')6options.add_argument('--window-size=1920,1080')7options.add_argument('--disable-dev-shm-usage')8options.add_argument('--disable-gpu')9options.add_argument('--disable-extensions')10options.add_argument('--disable-setuid-sandbox')11options.add_argument('--no-first-run')12options.add_argument('--no-sandbox')13options.add_argument('--no-zygote')14options.add_argument('--single-process')15options.add_argument('--ignore-certificate-errors')16options.add_argument('--ignore-ssl-errors')17options.add_argument('--user-data-dir')18options.add_argument('--disable-web-security')19options.add_argument('--allow-running-insecure-content')20options.add_argument('--allow-insecure-localhost')21options.add_argument('--allow-insecure-localhost')22options.add_argument('--allow-insecure-localhost')23options.add_argument('--allow-insecure-localhost')24options.add_argument('--allow-insecure-localhost')25options.add_argument('--allow-insecure-localhost')26options.add_argument('--allow-insecure-localhost')27options.add_argument('--allow-insecure-localhost')28options.add_argument('--allow-insecure-localhost')29options.add_argument('--allow-insecure-localhost')30options.add_argument('--allow-insecure-localhost')31options.add_argument('--allow-insecure-localhost')32options.add_argument('--allow-insecure-localhost')33options.add_argument('--allow-insecure-localhost')34options.add_argument('--allow-insecure-localhost')35options.add_argument('--allow-insecure-localhost')36options.add_argument('--allow-insecure-localhost')37options.add_argument('--allow-insecure-localhost')38options.add_argument('--allow-insecure-localhost')39options.add_argument('--allow-insecure-localhost')40options.add_argument('--allow-insecure-localhost')41options.add_argument('--allow-insecure-localhost')42options.add_argument('--allow-insecure-localhost')43options.add_argument('--allow-insecure-localhost')44options.add_argument('--allow-insecure-localhost')45options.add_argument('--allow-insecure-localhost')46options.add_argument('--allow-insecure-localhost')47options.add_argument('--allow-insecure-localhost')48options.add_argument('--allow-insecure-localhost')49options.add_argument('--allow-insecure-localhost')
options
Using AI Code Generation
1options.add_argument('--headless')2options.add_argument('--disable-gpu')3options.add_argument('--no-sandbox')4options.add_argument('--disable-dev-shm-usage')5options.add_argument('--disable-extensions')6options.add_argument('--window-size=1920,1080')7options.add_argument('--disable-dev-shm-usage')8options.add_argument('--disable-gpu')9options.add_argument('--disable-extensions')10options.add_argument('--disable-setuid-sandbox')11options.add_argument('--no-first-run')12options.add_argument('--no-sandbox')13options.add_argument('--no-zygote')14options.add_argument('--single-process')15options.add_argument('--ignore-certificate-errors')16options.add_argument('--ignore-ssl-errors')17options.add_argument('--user-data-dir')18options.add_argument('--disable-web-security')19options.add_argument('--allow-running-insecure-content')20options.add_argument('--allow-insecure-localhost')21options.add_argument('--allow-insecure-localhost')22options.add_argument('--allow-insecure-localhost')23options.add_argument('--allow-insecure-localhost')24options.add_argument('--allow-insecure-localhost')25options.add_argument('--allow-insecure-localhost')26options.add_argument('--allow-insecure-localhost')27options.add_argument('--allow-insecure-localhost')28options.add_argument('--allow-insecure-localhost')29options.add_argument('--allow-insecure-localhost')30options.add_argument('--allow-insecure-localhost')31options.add_argument('--allow-insecure-localhost')32options.add_argument('--allow-insecure-localhost')33options.add_argument('--allow-insecure-localhost')34options.add_argument('--allow-insecure-localhost')35options.add_argument('--allow-insecure-localhost')36options.add_argument('--allow-insecure-localhost')37options.add_argument('--allow-insecure-localhost')38options.add_argument('--allow-insecure-localhost')39options.add_argument('--allow-insecure-localhost')40options.add_argument('--allow-insecure-localhost')41options.add_argument('--allow-insecure-localhost')42options.add_argument('--allow-insecure-localhost')43options.add_argument('--allow-insecure-localhost')44options.add_argument('--allow-insecure-localhost')45options.add_argument('--allow-insecure-localhost')46options.add_argument('--allow-insecure-localhost')47options.add_argument('--allow-insecure-localhost')48options.add_argument('--allow-insecure-localhost')49options.add_argument('--allow-insecure-localhost')
Learn to execute automation testing from scratch with LambdaTest Learning Hub. Right from setting up the prerequisites to run your first automation test, to following best practices and diving deeper into advanced test scenarios. LambdaTest Learning Hubs compile a list of step-by-step guides to help you be proficient with different test automation frameworks i.e. Selenium, Cypress, TestNG etc.
You could also refer to video tutorials over LambdaTest YouTube channel to get step by step demonstration from industry experts.
Get 100 minutes of automation test minutes FREE!!