Method: Capybara::Node::Matchers#has_no_css?

Defined in:
lib/capybara/node/matchers.rb

#has_no_css?(path, **options, &optional_filter_block) ⇒ Boolean

Checks if a given CSS selector is not on the page or a descendant of the current node. Usage is identical to #has_css?.

Parameters:

  • path (String)

    A CSS selector

  • options (Hash)

    a customizable set of options

Returns:

  • (Boolean)

321
322
323
# File 'lib/capybara/node/matchers.rb', line 321

def has_no_css?(path, **options, &optional_filter_block)
  has_no_selector?(:css, path, **options, &optional_filter_block)
end