kucaahbe / rspec-html-matchers

Old school have_tag, with_tag(and more) matchers for rspec 3 (Nokogiri powered)
http://rubygems.org/gems/rspec-html-matchers
MIT License
199 stars 90 forks source link

Unexpected result with html tag and body tag #62

Closed PhilippePerret closed 4 years ago

PhilippePerret commented 7 years ago

describe 'unexpected wrong result' do
  it 'MUST be TRUE with negative and html' do
    expect("<p>My paragraph.</p>").not_to have_tag 'html' # => failure !ERROR!
  end
  it 'MUST be TRUE with negative and body' do
    expect("<p>My paragraph.</p>").not_to have_tag 'body' # => failure !ERROR!
  end
end
randoum commented 4 years ago

Please update to 0.9.3

kucaahbe commented 3 years ago

sorry for confusion, there is an issue about specifically matching these tags, please see #75 , in latest version (0.9.4) it's forbidden