e7281b56af
Co-authored-by: viehlieb <pf@pragma-shift.net> Co-authored-by: Tobias Kneuker <tk@pragma-shift.net>
15 lines
309 B
Ruby
15 lines
309 B
Ruby
require 'factory_bot'
|
|
|
|
FactoryBot.define do
|
|
factory :invite do
|
|
user { create :user }
|
|
group { create :group }
|
|
email { Faker::Internet.email }
|
|
|
|
factory :expired_invite do
|
|
after :create do |invite|
|
|
invite.update_column(:expires_at, Time.now.yesterday)
|
|
end
|
|
end
|
|
end
|
|
end
|