From b59ff24207c39ec69ab2d792c5ebb4e77c871f51 Mon Sep 17 00:00:00 2001 From: Aaron Patterson Date: Wed, 12 Aug 2015 13:43:32 -0700 Subject: pull `via` extraction up We're going to try pulling this up further, and check `via` validity sooner. This way we don't have to do a bunch of processing on `options` hashes only to find out that the route is incorrect --- actionpack/test/dispatch/mapper_test.rb | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'actionpack/test/dispatch') diff --git a/actionpack/test/dispatch/mapper_test.rb b/actionpack/test/dispatch/mapper_test.rb index b0815c41c8..5376ed70dd 100644 --- a/actionpack/test/dispatch/mapper_test.rb +++ b/actionpack/test/dispatch/mapper_test.rb @@ -41,8 +41,8 @@ module ActionDispatch end def test_mapping_requirements - options = { :via => :get } - m = Mapper::Mapping.build({}, FakeSet.new, '/store/:name(*rest)', nil, 'foo', 'bar', nil, options) + options = { } + m = Mapper::Mapping.build({}, FakeSet.new, '/store/:name(*rest)', nil, 'foo', 'bar', nil, [:get], options) _, _, requirements, _ = m.to_route assert_equal(/.+?/, requirements[:rest]) end -- cgit v1.2.3