class method
self.with_controllers
Ruby on Rails 2.3.18
Since v2.2.3 Last seen in v2.3.18Available in: v2.2.3 v2.3.18
Signature
self.with_controllers(names)
Expects an array of controller names as the first argument. Executes the passed block with only the named controllers named available. This method is used in internal Rails testing.
Parameters
-
namesreq
Source
# File actionpack/lib/action_controller/routing.rb, line 290
def with_controllers(names)
prior_controllers = @possible_controllers
use_controllers! names
yield
ensure
use_controllers! prior_controllers
end
Defined in actionpack/lib/action_controller/routing.rb line 290
· View on GitHub
· Improve this page
· Find usages on GitHub
Defined in ActionController::Routing