This question went unanswered on talk, I have the same question: Just curious as to why there isn''t any documentation in the RDoc on TestRequest and TestResponse. If I do something like render(:text=>@something.to_json) how do I use TestResponse to get the json data? It''s not well formed HTML, obviously. @response.inspect doesn''t show the json data. --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Core" group. To post to this group, send email to rubyonrails-core@googlegroups.com To unsubscribe from this group, send email to rubyonrails-core-unsubscribe@googlegroups.com For more options, visit this group at http://groups.google.com/group/rubyonrails-core?hl=en -~----------~----~----~----~------~----~------~--~---
> Just curious as to why there isn''t any documentation in the RDoc on > TestRequest and TestResponse.Good question. It''d be great if you could write something up.> If I do something like > > render(:text=>@something.to_json) > > how do I use TestResponse to get the json data? It''s not well formed > HTML, obviously. > > @response.inspect doesn''t show the json data.@response.body will contain what you''re looking for. -- Cheers Koz --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Core" group. To post to this group, send email to rubyonrails-core@googlegroups.com To unsubscribe from this group, send email to rubyonrails-core-unsubscribe@googlegroups.com For more options, visit this group at http://groups.google.com/group/rubyonrails-core?hl=en -~----------~----~----~----~------~----~------~--~---