Sha256: 0558967abb78c22cd8122940e33ec72654f6ead9e59fc48ab0f0b5a8e85ad055

Contents?: true

Size: 612 Bytes

Versions: 18

Compression:

Stored size: 612 Bytes

Contents

module Appium::Capybara
  class Appium::Capybara::Node < Capybara::Selenium::Node
    def label
      native.label
    end

    def name
      native.name
    end

    # Override
    def set(value, _options = {})
      native.clear
      send_keys(value)
    end

    def long_press
      action = Appium::TouchAction.new
      action.long_press(element: native, duration: 2000)
      action.perform
    end

    def find_custom(finder, locator)
      native.find_elements(finder, locator).map { |n| self.class.new(driver, n) }
    end

    def inspect
      %(#<#{self.class} name="#{name}">)
    end
  end
end

Version data entries

18 entries across 18 versions & 1 rubygems

Version Path
appium_capybara-3.1.2 lib/appium_capybara/driver/appium/node.rb
appium_capybara-3.1.1 lib/appium_capybara/driver/appium/node.rb
appium_capybara-3.1.0 lib/appium_capybara/driver/appium/node.rb
appium_capybara-3.0.0 lib/appium_capybara/driver/appium/node.rb
appium_capybara-2.1.1 lib/appium_capybara/driver/appium/node.rb
appium_capybara-2.1.0 lib/appium_capybara/driver/appium/node.rb
appium_capybara-2.0.2 lib/appium_capybara/driver/appium/node.rb
appium_capybara-2.0.1 lib/appium_capybara/driver/appium/node.rb
appium_capybara-2.0.0 lib/appium_capybara/driver/appium/node.rb
appium_capybara-2.0.0.rc2 lib/appium_capybara/driver/appium/node.rb
appium_capybara-2.0.0.rc1 lib/appium_capybara/driver/appium/node.rb
appium_capybara-1.10.0 lib/appium_capybara/driver/appium/node.rb
appium_capybara-1.9.0 lib/appium_capybara/driver/appium/node.rb
appium_capybara-1.8.1 lib/appium_capybara/driver/appium/node.rb
appium_capybara-1.8.0 lib/appium_capybara/driver/appium/node.rb
appium_capybara-1.7.0 lib/appium_capybara/driver/appium/node.rb
appium_capybara-1.6.0 lib/appium_capybara/driver/appium/node.rb
appium_capybara-1.5.1 lib/appium_capybara/driver/appium/node.rb