2017-12-13 19:13:44 -05:00
|
|
|
FactoryBot.define do
|
2016-04-16 15:09:08 -04:00
|
|
|
factory :award_emoji do
|
|
|
|
name "thumbsup"
|
|
|
|
user
|
|
|
|
awardable factory: :issue
|
2016-04-25 14:10:20 -04:00
|
|
|
|
2018-04-06 14:19:37 -04:00
|
|
|
after(:create) do |award, evaluator|
|
|
|
|
award.awardable.project.add_guest(evaluator.user)
|
|
|
|
end
|
|
|
|
|
2016-04-25 14:10:20 -04:00
|
|
|
trait :upvote
|
|
|
|
trait :downvote do
|
|
|
|
name "thumbsdown"
|
|
|
|
end
|
2016-04-16 15:09:08 -04:00
|
|
|
end
|
|
|
|
end
|