diff options
author | Heinrich Lee Yu <hleeyu@gmail.com> | 2018-10-26 20:37:52 +0800 |
---|---|---|
committer | Heinrich Lee Yu <hleeyu@gmail.com> | 2018-11-01 07:39:45 +0800 |
commit | e5a09709ea7c3104d5aad141132caabde097e1b3 (patch) | |
tree | 55ca57b60fbeea214d54629c81c950801249be48 /spec/finders/issues_finder_spec.rb | |
parent | 31733b6fc5a9ba4443a5dd279e787e2fd8e31c6d (diff) | |
download | gitlab-ce-e5a09709ea7c3104d5aad141132caabde097e1b3.tar.gz |
Update API to accept None and Any
Diffstat (limited to 'spec/finders/issues_finder_spec.rb')
-rw-r--r-- | spec/finders/issues_finder_spec.rb | 16 |
1 files changed, 14 insertions, 2 deletions
diff --git a/spec/finders/issues_finder_spec.rb b/spec/finders/issues_finder_spec.rb index 2f164ffa8b0..0b3e2709ade 100644 --- a/spec/finders/issues_finder_spec.rb +++ b/spec/finders/issues_finder_spec.rb @@ -144,19 +144,31 @@ describe IssuesFinder do end context 'filtering by no milestone' do - let(:params) { { milestone_title: Milestone::None.title } } + let(:params) { { milestone_title: 'None' } } it 'returns issues with no milestone' do expect(issues).to contain_exactly(issue2, issue3, issue4) end + + it 'returns issues with no milestone (deprecated)' do + params[:milestone_title] = Milestone::None.title + + expect(issues).to contain_exactly(issue2, issue3, issue4) + end end context 'filtering by any milestone' do - let(:params) { { milestone_title: Milestone::Any.title } } + let(:params) { { milestone_title: 'Any' } } it 'returns issues with any assigned milestone' do expect(issues).to contain_exactly(issue1) end + + it 'returns issues with any assigned milestone (deprecated)' do + params[:milestone_title] = Milestone::Any.title + + expect(issues).to contain_exactly(issue1) + end end context 'filtering by upcoming milestone' do |