diff options
author | Douglas Barbosa Alexandre <dbalexandre@gmail.com> | 2016-02-17 16:32:02 +0300 |
---|---|---|
committer | Douglas Barbosa Alexandre <dbalexandre@gmail.com> | 2016-02-17 16:32:02 +0300 |
commit | 9823d00e0b13224ae9e820e7d3f9fade69201e99 (patch) | |
tree | 9a37f949fdfbd560e23150b1a42ca3979fe9c51e /spec/factories/notes.rb | |
parent | 943bed68bc42d02246ddea63a25432d3aba709e7 (diff) |
Add ability to see and sort on vote count from Issues and MR lists
Diffstat (limited to 'spec/factories/notes.rb')
-rw-r--r-- | spec/factories/notes.rb | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/spec/factories/notes.rb b/spec/factories/notes.rb index 35a20adeef3..32c202891d8 100644 --- a/spec/factories/notes.rb +++ b/spec/factories/notes.rb @@ -34,6 +34,8 @@ FactoryGirl.define do factory :note_on_merge_request_diff, traits: [:on_merge_request, :on_diff] factory :note_on_project_snippet, traits: [:on_project_snippet] factory :system_note, traits: [:system] + factory :downvote_note, traits: [:award, :downvote] + factory :upvote_note, traits: [:award, :upvote] trait :on_commit do project @@ -65,6 +67,18 @@ FactoryGirl.define do system true end + trait :award do + is_award true + end + + trait :downvote do + note "thumbsdown" + end + + trait :upvote do + note "thumbsup" + end + trait :with_attachment do attachment { fixture_file_upload(Rails.root + "spec/fixtures/dk.png", "`/png") } end |