vidpush/spec/models/factories_spec.rb

14 lines
345 B
Ruby
Raw Normal View History

2014-04-07 18:41:34 +00:00
require 'spec_helper'
describe 'factories' do
FactoryGirl.factories.map(&:name).each do |factory_name|
specify "#{factory_name} factory is valid", :factory do
factory = build(factory_name)
if factory.respond_to?(:valid?)
expect(factory).to be_valid, factory.errors.full_messages.join(',')
end
end
end
end