Fix snippet factory

Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
This commit is contained in:
Dmitriy Zaporozhets 2014-12-12 15:55:06 +02:00
parent 118bd7178b
commit bfebab1c10
No known key found for this signature in database
GPG Key ID: 161B5D6A44D3D88A
1 changed files with 6 additions and 2 deletions

View File

@ -5,10 +5,14 @@ FactoryGirl.define do
Faker::Lorem.sentence
end
sequence :name, aliases: [:file_name] do
sequence :name do
Faker::Name.name
end
sequence :file_name do
Faker::Internet.user_name
end
sequence(:url) { Faker::Internet.uri('http') }
factory :user, aliases: [:author, :assignee, :owner, :creator] do
@ -18,7 +22,7 @@ FactoryGirl.define do
password "12345678"
password_confirmation { password }
confirmed_at { Time.now }
confirmation_token { nil }
confirmation_token { nil }
trait :admin do
admin true