Methods
B
C
D
N
R
S
T
Instance Public methods
boom()
# File actionpack/test/controller/test_case_test.rb, line 157
def boom
  raise 'boom!'
end
create()
# File actionpack/test/controller/test_case_test.rb, line 136
def create
  head :created, location: 'created resource'
end
delete_flash()
# File actionpack/test/controller/test_case_test.rb, line 19
def delete_flash
  flash.delete("test")
  render plain: 'ignore me'
end
no_op()
# File actionpack/test/controller/test_case_test.rb, line 10
def no_op
  render plain: 'dummy'
end
redirect_to_different_controller()
# File actionpack/test/controller/test_case_test.rb, line 132
def redirect_to_different_controller
  redirect_to controller: 'fail', id: 5
end
redirect_to_same_controller()
# File actionpack/test/controller/test_case_test.rb, line 128
def redirect_to_same_controller
  redirect_to controller: 'test', action: 'test_uri', id: 5
end
render_body()
# File actionpack/test/controller/test_case_test.rb, line 45
def render_body
  render plain: request.body.read
end
render_raw_post()
# File actionpack/test/controller/test_case_test.rb, line 40
def render_raw_post
  raise ActiveSupport::TestCase::Assertion, "#raw_post is blank" if request.raw_post.blank?
  render plain: request.raw_post
end
reset_the_session()
# File actionpack/test/controller/test_case_test.rb, line 35
def reset_the_session
  reset_session
  render plain: 'ignore me'
end
set_flash()
# File actionpack/test/controller/test_case_test.rb, line 14
def set_flash
  flash["test"] = ">#{flash["test"]}<"
  render plain: 'ignore me'
end
set_flash_now()
# File actionpack/test/controller/test_case_test.rb, line 24
def set_flash_now
  flash.now["test_now"] = ">#{flash["test_now"]}<"
  render plain: 'ignore me'
end
set_session()
# File actionpack/test/controller/test_case_test.rb, line 29
def set_session
  session['string'] = 'A wonder'
  session[:symbol] = 'it works'
  render plain: 'Success'
end
test_file_upload()
# File actionpack/test/controller/test_case_test.rb, line 120
def test_file_upload
  render plain: params[:file].size
end
test_format()
# File actionpack/test/controller/test_case_test.rb, line 65
def test_format
  render plain: request.format
end
test_headers()
# File actionpack/test/controller/test_case_test.rb, line 77
def test_headers
  render plain: ::JSON.dump(request.headers.env)
end
test_html_output()
# File actionpack/test/controller/test_case_test.rb, line 81
    def test_html_output
      render plain: <<HTML
<html>
  <body>
    <a href="/"><img src="/images/button.png" /></a>
    <div id="foo">
      <ul>
        <li class="item">hello</li>
        <li class="item">goodbye</li>
      </ul>
    </div>
    <div id="bar">
      <form action="/somewhere">
        Name: <input type="text" name="person[name]" id="person_name" />
      </form>
    </div>
  </body>
</html>
HTML
    end
test_only_one_param()
# File actionpack/test/controller/test_case_test.rb, line 112
def test_only_one_param
  render plain: (params[:left] && params[:right]) ? "EEP, Both here!" : "OK"
end
test_params()
# File actionpack/test/controller/test_case_test.rb, line 49
def test_params
  render plain: ::JSON.dump(params.to_unsafe_h)
end
test_protocol()
# File actionpack/test/controller/test_case_test.rb, line 73
def test_protocol
  render plain: request.protocol
end
test_query_parameters()
# File actionpack/test/controller/test_case_test.rb, line 53
def test_query_parameters
  render plain: ::JSON.dump(request.query_parameters)
end
test_query_string()
# File actionpack/test/controller/test_case_test.rb, line 69
def test_query_string
  render plain: request.query_string
end
test_remote_addr()
# File actionpack/test/controller/test_case_test.rb, line 116
def test_remote_addr
  render plain: (request.remote_addr || "not specified")
end
test_request_parameters()
# File actionpack/test/controller/test_case_test.rb, line 57
def test_request_parameters
  render plain: request.request_parameters.inspect
end
test_send_file()
# File actionpack/test/controller/test_case_test.rb, line 124
def test_send_file
  send_file(File.expand_path(__FILE__))
end
test_uri()
# File actionpack/test/controller/test_case_test.rb, line 61
def test_uri
  render plain: request.fullpath
end
test_with_body()
# File actionpack/test/controller/test_case_test.rb, line 153
def test_with_body
  render html: '<body class="foo"></body>'.html_safe
end
test_without_body()
# File actionpack/test/controller/test_case_test.rb, line 149
def test_without_body
  render html: '<div class="foo"></div>'.html_safe
end
test_xml_output()
# File actionpack/test/controller/test_case_test.rb, line 102
    def test_xml_output
      response.content_type = "application/xml"
      render plain: <<XML
<?xml version="1.0" encoding="UTF-8"?>
<root>
  <area>area is an empty tag in HTML, raising an error if not in xml mode</area>
</root>
XML
    end