Permalink
Browse files

Rename RouteInspect to RoutesInspector for consistency

  • Loading branch information...
josevalim committed Jun 29, 2012
1 parent e39f218 commit dbc43bcce69aa4aaf0ae309bf410e2b786c4e3f6
@@ -62,7 +62,7 @@ def engine?
##
# This class is just used for displaying route information when someone
# executes `rake routes`. People should not use this class.
- class RouteInspector # :nodoc:
+ class RoutesInspector # :nodoc:
def initialize
@engines = Hash.new
end
@@ -1,4 +1,4 @@
-require 'rails/application/route_inspector'
+require 'rails/application/routes_inspector'
class Rails::InfoController < ActionController::Base
self.view_paths = File.join(File.dirname(__FILE__), 'templates')
@@ -15,7 +15,7 @@ def properties
end
def routes
- inspector = Rails::Application::RouteInspector.new
+ inspector = Rails::Application::RoutesInspector.new
@info = inspector.format(_routes.routes).join("\n")
end
@@ -1,7 +1,7 @@
desc 'Print out all defined routes in match order, with names. Target specific controller with CONTROLLER=x.'
task :routes => :environment do
all_routes = Rails.application.routes.routes
- require 'rails/application/route_inspector'
- inspector = Rails::Application::RouteInspector.new
+ require 'rails/application/routes_inspector'
+ inspector = Rails::Application::RoutesInspector.new
puts inspector.format(all_routes, ENV['CONTROLLER']).join "\n"
end
@@ -1,13 +1,13 @@
require 'minitest/autorun'
-require 'rails/application/route_inspector'
+require 'rails/application/routes_inspector'
require 'action_controller'
require 'rails/engine'
module ApplicationTests
class RouteInspectTest < ActiveSupport::TestCase
def setup
@set = ActionDispatch::Routing::RouteSet.new
- @inspector = Rails::Application::RouteInspector.new
+ @inspector = Rails::Application::RoutesInspector.new
app = ActiveSupport::OrderedOptions.new
app.config = ActiveSupport::OrderedOptions.new
app.config.assets = ActiveSupport::OrderedOptions.new

0 comments on commit dbc43bc

Please sign in to comment.