That article suggests the goal is to test the "contents" of the file.
That is a slightly different concern than what I would usually
consider "testing for send file in a controller", which I typically
understand as: was the response what I expected?
# ...
get :show, :id => @report.to_param, :format => "pdf"
end
should_respond_with :success
should_respond_with_content_type "application/pdf"
or:
# ...
get :show, :id => @ticket.to_param, :format => "gif"
end
should_respond_with :success
should_respond_with_content_type "image/gif"
--
Dan Croak
@Croaky