2010-07-09 14:08:33 -04:00
|
|
|
module Capybara
|
|
|
|
module Driver
|
|
|
|
class Node
|
|
|
|
attr_reader :driver, :node
|
|
|
|
|
|
|
|
def initialize(driver, node)
|
|
|
|
@driver = driver
|
|
|
|
@node = node
|
|
|
|
end
|
|
|
|
|
|
|
|
def text
|
|
|
|
raise NotImplementedError
|
|
|
|
end
|
|
|
|
|
|
|
|
def [](name)
|
|
|
|
raise NotImplementedError
|
|
|
|
end
|
|
|
|
|
|
|
|
def value
|
2010-07-09 21:11:54 -04:00
|
|
|
raise NotImplementedError
|
2010-07-09 14:08:33 -04:00
|
|
|
end
|
|
|
|
|
|
|
|
def set(value)
|
|
|
|
raise NotImplementedError
|
|
|
|
end
|
|
|
|
|
2010-07-09 19:18:39 -04:00
|
|
|
def select_option(option)
|
2010-07-09 14:08:33 -04:00
|
|
|
raise NotImplementedError
|
|
|
|
end
|
|
|
|
|
2010-07-09 19:18:39 -04:00
|
|
|
def unselect_option(option)
|
2010-07-09 14:08:33 -04:00
|
|
|
raise NotImplementedError
|
|
|
|
end
|
|
|
|
|
|
|
|
def click
|
|
|
|
raise NotImplementedError
|
|
|
|
end
|
|
|
|
|
|
|
|
def drag_to(element)
|
|
|
|
raise NotImplementedError
|
|
|
|
end
|
|
|
|
|
|
|
|
def tag_name
|
|
|
|
raise NotImplementedError
|
|
|
|
end
|
|
|
|
|
|
|
|
def visible?
|
|
|
|
raise NotImplementedError
|
|
|
|
end
|
|
|
|
|
|
|
|
def path
|
|
|
|
raise NotSupportedByDriverError
|
|
|
|
end
|
|
|
|
|
|
|
|
def trigger(event)
|
|
|
|
raise NotSupportedByDriverError
|
|
|
|
end
|
2010-07-10 10:34:33 -04:00
|
|
|
|
|
|
|
def inspect
|
|
|
|
%(#<Capybara::Driver::Node tag="#{tag_name}" path="#{path}">)
|
|
|
|
rescue NotSupportedByDriverError
|
|
|
|
%(#<Capybara::Driver::Node tag="#{tag_name}">)
|
|
|
|
end
|
2010-07-09 14:08:33 -04:00
|
|
|
end
|
|
|
|
end
|
|
|
|
end
|