diff options
author | Łukasz Strzałkowski <lukasz.strzalkowski@gmail.com> | 2013-08-07 00:47:49 +0200 |
---|---|---|
committer | Łukasz Strzałkowski <lukasz.strzalkowski@gmail.com> | 2013-08-25 11:39:14 +0200 |
commit | 313f1f196a40c526f88c58b1c5311f7cd8263ee2 (patch) | |
tree | f526ac5b01e5f62718ddeb690b8d3c5c356c5271 /actionpack | |
parent | 1e001b1db38bf0597b89ae566e1440f9e195060a (diff) | |
download | rails-313f1f196a40c526f88c58b1c5311f7cd8263ee2.tar.gz rails-313f1f196a40c526f88c58b1c5311f7cd8263ee2.tar.bz2 rails-313f1f196a40c526f88c58b1c5311f7cd8263ee2.zip |
Basic rendering test
Diffstat (limited to 'actionpack')
-rw-r--r-- | actionpack/test/controller/basic_rendering_test.rb | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/actionpack/test/controller/basic_rendering_test.rb b/actionpack/test/controller/basic_rendering_test.rb new file mode 100644 index 0000000000..2db3cff395 --- /dev/null +++ b/actionpack/test/controller/basic_rendering_test.rb @@ -0,0 +1,19 @@ +require 'abstract_unit' + +class BasicRenderingController < ActionController::Base + def render_hello_world + render text: "Hello World!" + end +end + +class BasicRenderingTest < ActionController::TestCase + tests BasicRenderingController + + def test_render_hello_world + get :render_hello_world + + assert_equal "Hello World!", @response.body + assert_equal "text/plain", @response.content_type + end +end +
\ No newline at end of file |