With the latest version of FactoryGirl, you can use FactoryGirl.lint
instead of explicitly testing your factories in a separate rake task. Just update to the latest version and add this to your spec_helper.rb
:
RSpec.configure do |config|
config.before(:suite) do
FactoryGirl.lint
end
end
More info is in the Getting Started Guide.