Class: ActionController::TestResponse

Inherits:
Response show all
Includes:
TestResponseBehavior
Defined in:
lib/action_controller/test_process.rb

Overview

Integration test methods such as ActionController::Integration::Session#get and ActionController::Integration::Session#post return objects of class TestResponse, which represent the HTTP response results of the requested controller actions.

See Response for more information on controller response objects.

Constant Summary

Constants inherited from Response

Response::DEFAULT_HEADERS

Instance Attribute Summary

Attributes inherited from Response

#assigns, #layout, #redirected_to, #redirected_to_method_params, #request, #session, #template

Instance Method Summary collapse

Methods included from TestResponseBehavior

#binary_content, #client_error?, #code, #cookies, #error?, #flash, #has_flash?, #has_flash_object?, #has_flash_with_contents?, #has_session_object?, #has_template_object?, #message, #missing?, #redirect?, #redirect_url, #redirect_url_match?, #rendered, #response_code, #success?, #template_objects

Methods inherited from Response

#assign_default_content_type_and_charset!, #charset, #charset=, #content_type, #content_type=, #each, #etag, #etag=, #etag?, #flush, #initialize, #last_modified, #last_modified=, #last_modified?, #location, #location=, #prepare!, #redirect, #sending_file?, #set_cookie, #write

Constructor Details

This class inherits a constructor from ActionController::Response

Instance Method Details

#recycle!Object



289
290
291
292
# File 'lib/action_controller/test_process.rb', line 289

def recycle!
  headers.delete('ETag')
  headers.delete('Last-Modified')
end