diff options
| author | Carl Lerche <carllerche@mac.com> | 2010-04-18 13:02:37 -0700 |
|---|---|---|
| committer | Carl Lerche <carllerche@mac.com> | 2010-04-18 13:02:37 -0700 |
| commit | d32a4cbaa5174cc1a73d41a73f55145251c18c84 (patch) | |
| tree | 16e3ad82102aa6d290b8941dd69e27b1efaf14f6 /actionpack/test/dispatch/routing_test.rb | |
| parent | c16c248912e4ae3b6a64e6acdbf1a1e0dd2feb26 (diff) | |
| parent | 8c7e8976e97d96f514e22b04fc1afb9453134076 (diff) | |
| download | rails-d32a4cbaa5174cc1a73d41a73f55145251c18c84.tar.gz rails-d32a4cbaa5174cc1a73d41a73f55145251c18c84.tar.bz2 rails-d32a4cbaa5174cc1a73d41a73f55145251c18c84.zip | |
Merge branch 'master' of github.com:rails/rails
Diffstat (limited to 'actionpack/test/dispatch/routing_test.rb')
| -rw-r--r-- | actionpack/test/dispatch/routing_test.rb | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/actionpack/test/dispatch/routing_test.rb b/actionpack/test/dispatch/routing_test.rb index 8940990712..5bca476b27 100644 --- a/actionpack/test/dispatch/routing_test.rb +++ b/actionpack/test/dispatch/routing_test.rb @@ -54,6 +54,8 @@ class TestRoutingMapper < ActionDispatch::IntegrationTest match "/local/:action", :controller => "local" + match "/projects/status(.:format)" + constraints(:ip => /192\.168\.1\.\d\d\d/) do get 'admin' => "queenbee#index" end @@ -426,6 +428,13 @@ class TestRoutingMapper < ActionDispatch::IntegrationTest end end + def test_projects_status + with_test_routes do + assert_equal '/projects/status', url_for(:controller => 'projects', :action => 'status', :only_path => true) + assert_equal '/projects/status.json', url_for(:controller => 'projects', :action => 'status', :format => 'json', :only_path => true) + end + end + def test_projects with_test_routes do get '/projects' |
