Upgrade to Rails 2.0.2
Upgraded to Rails 2.0.2, except that we maintain vendor/rails/actionpack/lib/action_controller/routing.rb from Rail 1.2.6 (at least for now), so that Routes don't change. We still get to enjoy Rails's many new features. Also fixed a bug in Chunk-handling: disable WikiWord processing in tags (for real this time).
This commit is contained in:
parent
0f6889e09f
commit
6873fc8026
1083 changed files with 52810 additions and 41058 deletions
|
@ -37,6 +37,8 @@ class VerificationTest < Test::Unit::TestCase
|
|||
verify :only => :guarded_one_for_named_route_test, :params => "one",
|
||||
:redirect_to => :foo_url
|
||||
|
||||
verify :only => :no_default_action, :params => "santa"
|
||||
|
||||
def guarded_one
|
||||
render :text => "#{params[:one]}"
|
||||
end
|
||||
|
@ -89,6 +91,10 @@ class VerificationTest < Test::Unit::TestCase
|
|||
render :text => "Was a post!"
|
||||
end
|
||||
|
||||
def no_default_action
|
||||
# Will never run
|
||||
end
|
||||
|
||||
protected
|
||||
def rescue_action(e) raise end
|
||||
|
||||
|
@ -229,6 +235,11 @@ class VerificationTest < Test::Unit::TestCase
|
|||
assert_equal "Was a post!", @response.body
|
||||
end
|
||||
|
||||
def test_default_failure_should_be_a_bad_request
|
||||
post :no_default_action
|
||||
assert_response :bad_request
|
||||
end
|
||||
|
||||
def test_guarded_post_and_calls_render_fails_and_sets_allow_header
|
||||
get :must_be_post
|
||||
assert_response 405
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue