Ensure route matcher works with namespaced controllers

This commit is contained in:
Elliot Winkler 2014-11-18 17:23:04 +08:00
parent abb087e6bb
commit 47a0392b77
1 changed files with 15 additions and 0 deletions

View File

@ -107,4 +107,19 @@ describe 'Shoulda::Matchers::ActionController::RouteMatcher', type: :controller
end
end
end
context 'given a controller that is namespaced' do
it_behaves_like 'a controller with a defined route' do
def controller
@_controller ||= begin
define_module('Admin')
define_controller('Admin::Examples').new
end
end
def controller_name
'admin/examples'
end
end
end
end