Make test organization names more unique
The addition of a uniqueness validation on Organization#name is causing a lot of random failures; the Organization factory uses a Faker value, but appears to be producing repetitive results, so I've added a FactoryGirl sequence to ensure uniqueness.
This commit is contained in:
parent
b1960c08ef
commit
44fd794416
1 changed files with 1 additions and 1 deletions
|
|
@ -1,6 +1,6 @@
|
||||||
FactoryGirl.define do
|
FactoryGirl.define do
|
||||||
factory :organization do
|
factory :organization do
|
||||||
name { Faker::Company.name }
|
sequence(:name) { |n| "#{Faker::Company.name} #{n}" }
|
||||||
description { Faker::Lorem.paragraph }
|
description { Faker::Lorem.paragraph }
|
||||||
|
|
||||||
# after(:create) do |organization|
|
# after(:create) do |organization|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue