demarches-normaliennes/spec/factories/user.rb
2020-07-23 16:20:16 +02:00

12 lines
273 B
Ruby

FactoryBot.define do
sequence(:user_email) { |n| "user#{n}@user.com" }
factory :user do
email { generate(:user_email) }
password { 'my-s3cure-p4ssword' }
confirmed_at { Time.zone.now }
trait :unconfirmed do
confirmed_at { nil }
end
end
end