summaryrefslogtreecommitdiff
path: root/spec/finders
diff options
context:
space:
mode:
authorSean McGivern <sean@gitlab.com>2018-11-01 11:07:09 +0000
committerSean McGivern <sean@gitlab.com>2018-11-01 11:07:09 +0000
commitc49f57fe430edeac9a5f2423dac7afb80ff72576 (patch)
tree23c8e45711083748f18d81a9f40f3b464e4b62cb /spec/finders
parentf7c0a18b8a061bfea650897b22dce24d712c6439 (diff)
parent8df7e6021b0da30e3b7550ca83cd9ab3f991c235 (diff)
downloadgitlab-ce-c49f57fe430edeac9a5f2423dac7afb80ff72576.tar.gz
Merge branch 'engwan/gitlab-ce-44012-filter-reactions-none-any'
Diffstat (limited to 'spec/finders')
-rw-r--r--spec/finders/issues_finder_spec.rb16
1 files changed, 16 insertions, 0 deletions
diff --git a/spec/finders/issues_finder_spec.rb b/spec/finders/issues_finder_spec.rb
index 0b3e2709ade..c0488c83bd8 100644
--- a/spec/finders/issues_finder_spec.rb
+++ b/spec/finders/issues_finder_spec.rb
@@ -372,6 +372,22 @@ describe IssuesFinder do
end
context 'filtering by reaction name' do
+ context 'user searches by no reaction' do
+ let(:params) { { my_reaction_emoji: 'None' } }
+
+ it 'returns issues that the user did not react to' do
+ expect(issues).to contain_exactly(issue2, issue4)
+ end
+ end
+
+ context 'user searches by any reaction' do
+ let(:params) { { my_reaction_emoji: 'Any' } }
+
+ it 'returns issues that the user reacted to' do
+ expect(issues).to contain_exactly(issue1, issue3)
+ end
+ end
+
context 'user searches by "thumbsup" reaction' do
let(:params) { { my_reaction_emoji: 'thumbsup' } }