Permalink
Browse files

Merge [5645] from 1.2.

git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@5646 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
  • Loading branch information...
1 parent 13e1d29 commit ec75642e137a8682b099009ab205f764fe70c51e @jeremy jeremy committed Nov 28, 2006
Showing with 6 additions and 4 deletions.
  1. +6 −4 actionpack/test/controller/action_pack_assertions_test.rb
@@ -4,7 +4,7 @@
class ActionPackAssertionsController < ActionController::Base
# this does absolutely nothing
- def nothing() render_text ""; end
+ def nothing() head :ok end
# a standard template
def hello_world() render "test/hello_world"; end
@@ -27,13 +27,13 @@ def redirect_to_named_route() redirect_to route_one_url end
def redirect_external() redirect_to_url "http://www.rubyonrails.org"; end
# a 404
- def response404() render_text "", "404 AWOL"; end
+ def response404() head '404 AWOL' end
# a 500
- def response500() render_text "", "500 Sorry"; end
+ def response500() head '500 Sorry' end
# a fictional 599
- def response599() render_text "", "599 Whoah!"; end
+ def response599() head '599 Whoah!' end
# putting stuff in the flash
def flash_me
@@ -402,7 +402,9 @@ def test_redirection_location
process :redirect_external
assert_equal 'http://www.rubyonrails.org', @response.redirect_url
+ end
+ def test_no_redirect_url
process :nothing
assert_nil @response.redirect_url
end

0 comments on commit ec75642

Please sign in to comment.