[rspec-users] assert_select - to do negative tests - need help with syntax please :)

David Chelimsky dchelimsky at gmail.com
Wed Oct 12 10:34:20 EDT 2011


On Oct 12, 2011, at 6:53 AM, Gordon Yeong wrote:

> What _will_ work is this:
> 
>  assert_select "input#brand_created_by", false

This ^^ does not include :name => "..."

> 
> 
> Hmmm. Sadly it does not work :( See below:
> 
> ---------------- extract start -------------------------
> 
>      Failure/Error: assert_select "input#brand_created_by", false, :name => "brand[created_by]"

This ^^ does include :name => "....".

What happens when you just run

  assert_select "input#brand_created_by", false
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://rubyforge.org/pipermail/rspec-users/attachments/20111012/8f523a1e/attachment.html>


More information about the rspec-users mailing list