Commit dc22dd8aded81f10b8b9fc06f8c423043aa01d0a
1 parent
b5f9d29f
Exists in
master
and in
4 other branches
Factories spec refactoring after #1616
Showing
1 changed file
with
3 additions
and
1 deletions
Show diff stats
spec/factories_spec.rb
| 1 | require 'spec_helper' | 1 | require 'spec_helper' |
| 2 | 2 | ||
| 3 | +INVALID_FACTORIES = [:key_with_a_space_in_the_middle] | ||
| 4 | + | ||
| 3 | FactoryGirl.factories.map(&:name).each do |factory_name| | 5 | FactoryGirl.factories.map(&:name).each do |factory_name| |
| 4 | - next if :key_with_a_space_in_the_middle == factory_name | 6 | + next if INVALID_FACTORIES.include?(factory_name) |
| 5 | describe "#{factory_name} factory" do | 7 | describe "#{factory_name} factory" do |
| 6 | it 'should be valid' do | 8 | it 'should be valid' do |
| 7 | build(factory_name).should be_valid | 9 | build(factory_name).should be_valid |