Created
June 24, 2011 21:55
-
-
Save nbryan/1045773 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # Factory Girl doesn't traverse down directories, make sure these factories get loaded. | |
| Dir[File.join(File.dirname(__FILE__), 'factories', '**/*.rb')].each {|file| require file} |
Author
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
I put this in my spec_helper.rb file. It looks like Factory Girl only traverses the top-level factories directory if it exists and no subdirectories.