Methods
A
T
Constants
Routes = ActionDispatch::Routing::RouteSet.new.tap do |app| app.draw do ok = lambda { |env| [200, { 'Content-Type' => 'text/plain' }, []] } get "/*id" => redirect("/not_cars"), :constraints => {id: /dummy/} get "/cars" => ok end end
 
APP = build_app Routes
 

include Routes.url_helpers

Instance Public methods
app()
# File actionpack/test/dispatch/routing_test.rb, line 4159
def app; APP end
test_glob_constraint()
# File actionpack/test/dispatch/routing_test.rb, line 4161
def test_glob_constraint
  get "/dummy"
  assert_equal "301", @response.code
  assert_equal "/not_cars", @response.header['Location'].match('/[^/]+$')[0]
end
test_glob_constraint_skip_all()
# File actionpack/test/dispatch/routing_test.rb, line 4171
def test_glob_constraint_skip_all
  get "/missing"
  assert_equal "404", @response.code
end
test_glob_constraint_skip_route()
# File actionpack/test/dispatch/routing_test.rb, line 4167
def test_glob_constraint_skip_route
  get "/cars"
  assert_equal "200", @response.code
end