From c4e3344a26dce5d2bc15e788c75140356a40537c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jos=C3=A9=20Valim?= Date: Tue, 12 Jan 2010 11:23:26 +0100 Subject: Revert "Add a generator_paths config option" This reverts commit 8665c754cb61c947cd55f8886c28188050aed78d. --- railties/lib/rails/configuration.rb | 12 +++++------- railties/test/plugins/configuration_test.rb | 6 ------ 2 files changed, 5 insertions(+), 13 deletions(-) (limited to 'railties') diff --git a/railties/lib/rails/configuration.rb b/railties/lib/rails/configuration.rb index 08f5dda8ee..eed9834203 100644 --- a/railties/lib/rails/configuration.rb +++ b/railties/lib/rails/configuration.rb @@ -22,17 +22,15 @@ module Rails end end - attr_reader :middleware, :generator_paths + attr_reader :middleware def initialize(base = nil) if base - @options = base.options.dup - @middleware = base.middleware.dup - @generator_paths = base.generator_paths.dup + @options = base.options.dup + @middleware = base.middleware.dup else - @options = Hash.new { |h,k| h[k] = ActiveSupport::OrderedOptions.new } - @middleware = self.class.default_middleware_stack - @generator_paths = [] + @options = Hash.new { |h,k| h[k] = ActiveSupport::OrderedOptions.new } + @middleware = self.class.default_middleware_stack end end diff --git a/railties/test/plugins/configuration_test.rb b/railties/test/plugins/configuration_test.rb index 03c738971f..25bf24eb3b 100644 --- a/railties/test/plugins/configuration_test.rb +++ b/railties/test/plugins/configuration_test.rb @@ -24,12 +24,6 @@ module PluginsTest assert_equal "hello", AppTemplate::Application.config.foo.greetings end - test "plugins can provide generators" do - class Foo < Rails::Railtie ; config.generator_paths << "/foo" ; end - require "#{app_path}/config/application" - assert_eqaul ["/foo"], AppTemplate::Application.config.generator_paths - end - test "plugin config merges are deep" do class Foo < Rails::Railtie ; config.foo.greetings = 'hello' ; end class MyApp < Rails::Application -- cgit v1.2.3