Class/Module Index [+]

Quicksearch

Capybara::RSpecMatchers::HaveSelector

Attributes

failure_message[R]
failure_message_for_should[R]
failure_message_for_should_not[R]
failure_message_when_negated[R]

Public Class Methods

new(*args) click to toggle source
# File lib/capybara/rspec/matchers.rb, line 18
def initialize(*args)
  @args = args
end

Public Instance Methods

description() click to toggle source
# File lib/capybara/rspec/matchers.rb, line 36
def description
  "have #{query.description}"
end
does_not_match?(actual) click to toggle source
# File lib/capybara/rspec/matchers.rb, line 29
def does_not_match?(actual)
  wrap(actual).assert_no_selector(*@args)
rescue Capybara::ExpectationNotMet => e
  @failure_message_when_negated = e.message
  return false
end
matches?(actual) click to toggle source
# File lib/capybara/rspec/matchers.rb, line 22
def matches?(actual)
  wrap(actual).assert_selector(*@args)
rescue Capybara::ExpectationNotMet => e
  @failure_message = e.message
  return false
end
query() click to toggle source
# File lib/capybara/rspec/matchers.rb, line 40
def query
  @query ||= Capybara::Query.new(*@args)
end

[Validate]

Generated with the Darkfish Rdoc Generator 2.