[rspec-users] [rspec][webrat] Bug? in have_tag for <a href="name">

Evgeny Bogdanov evgeny.bogdanov at gmail.com
Mon Jul 6 08:05:05 EDT 2009


I am writing a spec for the following html code:
<a href="/home">Home</a>
<a href="/logout">Logout</a>

and I use webrat have_tag for specying it:
response.body.should have_tag('a', :href => "/home", :content =>
response.body.should have_tag('a', :href => "/logout", :content =>

If I put :href to be "/home2" or :content to be "Home1" the spec still
though it shouldn't as I understand.

Does somebody know what I am doing wrong?
Thank you in advance,

More information about the rspec-users mailing list