1
0
Fork 0
mirror of https://github.com/thoughtbot/factory_bot_rails.git synced 2022-11-09 11:49:18 -05:00

Load factories from /factories at the Rails root, just like the default definition_file_paths.

This commit is contained in:
Chris Griego 2011-08-27 16:41:27 -05:00
parent cec108dbeb
commit a38b0dd62d

View file

@ -5,6 +5,7 @@ module FactoryGirl
class Railtie < Rails::Railtie
config.after_initialize do
FactoryGirl.definition_file_paths = [
File.join(Rails.root, 'factories'),
File.join(Rails.root, 'test', 'factories'),
File.join(Rails.root, 'spec', 'factories')
]