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:
parent
cec108dbeb
commit
a38b0dd62d
1 changed files with 1 additions and 0 deletions
|
@ -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')
|
||||
]
|
||||
|
|
Loading…
Reference in a new issue