In Rspec Capybara test I want to check that no H4, H5, ..., H9 selector exists.
I would expect the following solution:
visit "/"
expect(page).not_to have_css(/(h|H)\[4-9]d/)
But it fails due to Nokogiri parsing
I also noticed that:
has_css?("h1")
# is not equal to
has_css?("H1")