mirror of
https://github.com/rails/rails.git
synced 2022-11-09 12:12:34 -05:00
Fix generators tests.
Signed-off-by: Jeremy Kemper <jeremy@bitsweat.net>
This commit is contained in:
parent
292363c75f
commit
a176263ebc
1 changed files with 3 additions and 2 deletions
|
@ -5,6 +5,7 @@ require 'active_support'
|
|||
require 'active_support/core_ext/object/blank'
|
||||
require 'active_support/core_ext/object/metaclass'
|
||||
require 'active_support/core_ext/array/extract_options'
|
||||
require 'active_support/core_ext/hash/deep_merge'
|
||||
require 'active_support/core_ext/module/attribute_accessors'
|
||||
require 'active_support/core_ext/string/inflections'
|
||||
|
||||
|
@ -94,7 +95,7 @@ module Rails
|
|||
end
|
||||
|
||||
def self.plugins_generators_paths #:nodoc:
|
||||
return [] unless defined?(Rails.root)
|
||||
return [] unless defined?(Rails.root) && Rails.root
|
||||
Dir[File.join(Rails.root, "vendor", "plugins", "*", "lib", "{generators,rails_generators}")]
|
||||
end
|
||||
|
||||
|
@ -135,7 +136,7 @@ module Rails
|
|||
def self.load_paths
|
||||
@load_paths ||= begin
|
||||
paths = []
|
||||
paths += Dir[File.join(Rails.root, "lib", "{generators,rails_generators}")] if defined?(Rails.root)
|
||||
paths += Dir[File.join(Rails.root, "lib", "{generators,rails_generators}")] if defined?(Rails.root) && Rails.root
|
||||
paths += Dir[File.join(Thor::Util.user_home, ".rails", "{generators,rails_generators}")]
|
||||
paths += self.plugins_generators_paths
|
||||
paths += self.gems_generators_paths
|
||||
|
|
Loading…
Reference in a new issue