Phlip
2006-Dec-17 03:21 UTC
assert_rjs :call on something more complex than ''foo'' ''bar''
Raileanos:
Suppose I want to insert JS into an RJS page object (which I call
''rjs'' to distinguish it from all the many other
''page'' objects in the
universe). The production code looks like this:
rjs << ''Element.setStyle("myDiv"), {
backgroundColor: "blue" };''
So what''s the test-side supposed to look like? This??
assert_rjs :call, ''Element.setStyle'',
''myDiv'', ''{ backgroundColor: "blue"
}''
That ain''t working. The {} jigger is JSON, right? How do we match the
{}?
--
Phlip
http://c2.com/cgi/wiki?ZeekLand <-- NOT a blog!!
--~--~---------~--~----~------------~-------~--~----~
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
rubyonrails-talk-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org
To unsubscribe from this group, send email to
rubyonrails-talk-unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org
For more options, visit this group at
http://groups.google.com/group/rubyonrails-talk?hl=en
-~----------~----~----~----~------~----~------~--~---