As stated, how do I take everything ever rendered from a controller action in Rails through a method in a gem so I can parse the output for specific text?
答案 0 :(得分:0)
Try using
response.body
According to http://api.rubyonrails.org/classes/ActionDispatch/Response.html#method-i-body this returns the content of the response as a string. This contains the contents of any calls to render.