diff options
author | Xavier Noria <fxn@hashref.com> | 2012-02-24 16:25:41 -0800 |
---|---|---|
committer | Xavier Noria <fxn@hashref.com> | 2012-02-24 16:25:41 -0800 |
commit | b7a094536de6fdeb428aa79d21f1e2128169f45e (patch) | |
tree | ec0af33cb15a1c70a3f3e71b954782068a2040dd /actionpack/test/dispatch | |
parent | 31ceb5e67b164eb98cddd5aef0bc87dad606a6bf (diff) | |
download | rails-b7a094536de6fdeb428aa79d21f1e2128169f45e.tar.gz rails-b7a094536de6fdeb428aa79d21f1e2128169f45e.tar.bz2 rails-b7a094536de6fdeb428aa79d21f1e2128169f45e.zip |
uses PATCH for the forms of persisted records, and routes PATCH and PUT to the update action of resources
Diffstat (limited to 'actionpack/test/dispatch')
-rw-r--r-- | actionpack/test/dispatch/routing_test.rb | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/actionpack/test/dispatch/routing_test.rb b/actionpack/test/dispatch/routing_test.rb index e8da790e50..eb495d30e5 100644 --- a/actionpack/test/dispatch/routing_test.rb +++ b/actionpack/test/dispatch/routing_test.rb @@ -1026,6 +1026,10 @@ class TestRoutingMapper < ActionDispatch::IntegrationTest assert_equal 'pasts#destroy', @response.body assert_equal '/past', past_path + patch '/present' + assert_equal 'presents#update', @response.body + assert_equal '/present', present_path + put '/present' assert_equal 'presents#update', @response.body assert_equal '/present', present_path @@ -1044,6 +1048,10 @@ class TestRoutingMapper < ActionDispatch::IntegrationTest assert_equal 'relationships#destroy', @response.body assert_equal '/relationships/1', relationship_path(1) + patch '/friendships/1' + assert_equal 'friendships#update', @response.body + assert_equal '/friendships/1', friendship_path(1) + put '/friendships/1' assert_equal 'friendships#update', @response.body assert_equal '/friendships/1', friendship_path(1) |