Class | Capybara::Node::Simple |
In: |
lib/capybara/node/simple.rb
|
Parent: | Object |
A {Capybara::Node::Simple} is a simpler version of {Capybara::Node::Base} which includes only {Capybara::Node::Finders} and {Capybara::Node::Matchers} and does not include {Capybara::Node::Actions}. This type of node is returned when using {Capybara.string}.
It is useful in that it does not require a session, an application or a driver, but can still use Capybara‘s finders and matchers on any string that contains HTML.
native | [R] |
Retrieve the given attribute
element[:title] # => HTML title attribute
@param [Symbol] attribute The attribute to retrieve @return [String] The value of the attribute
An XPath expression describing where on the page the element can be found
@return [String] An XPath expression
Whether or not the element is visible. Does not support CSS, so the result may be inaccurate.
@return [Boolean] Whether the element is visible