I'm testing an XHR, and until I discovered :chained_replace_html , the  
test wasn't seeing that a <div> was being hidden.
=== map_filter.rjs
22   page['map-filter-errors'].hide
===

Why does line 433 above fail?:
=== neighbourhoods_controller_spec.rb
432           do_xhr @xhr_params
433           assert_select_rjs :hide
=== The test's output
No RJS statement that replaces or inserts HTML content.
===

But when I change the test to this, the test succeeds:
=== neighbourhoods_controller_spec.rb
432           do_xhr @xhr_params
433           assert_select_rjs :chained_replace_html
===

I've googled around, read the source for #assert_select_rjs , but  
can't figure out what :chained_replace_html is, means, when it should  
be used, etc.

So, I have three questions:
1) Why does passing :hide to #assert_select_rjs fail to see the RJS  
change?
2) What is :chained_replace_html ?
3) When should :chained_replace_html be used?

Thanks!
Nick

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Ruby 
on Rails: Talk" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/rubyonrails-talk?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to