Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGitLab Bot <gitlab-bot@gitlab.com>2020-01-28 18:08:36 +0300
committerGitLab Bot <gitlab-bot@gitlab.com>2020-01-28 18:08:36 +0300
commitfedf978f9aa1909ed7bb3fad767ad120a1c6bd7b (patch)
tree1bd0f0b301ad96feda1910abe34eb89c46cc55cd /spec/finders
parentdb24ab2b72dbff24c201410a0561e929ae7e8061 (diff)
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'spec/finders')
-rw-r--r--spec/finders/issues_finder_spec.rb23
1 files changed, 14 insertions, 9 deletions
diff --git a/spec/finders/issues_finder_spec.rb b/spec/finders/issues_finder_spec.rb
index 056795a50d0..7a102cb479e 100644
--- a/spec/finders/issues_finder_spec.rb
+++ b/spec/finders/issues_finder_spec.rb
@@ -33,17 +33,22 @@ describe IssuesFinder do
before do
project2.add_developer(user3)
- issue3.assignees = [user2, user3]
+ issue2.assignees = [user2]
+ issue3.assignees = [user3]
end
it_behaves_like 'assignee username filter' do
- let(:params) { { assignee_username: [user2.username, user3.username] } }
- let(:expected_issuables) { [issue3] }
+ let(:params) { { assignee_username: [user2.username] } }
+ let(:expected_issuables) { [issue2] }
end
it_behaves_like 'assignee NOT username filter' do
- let(:params) { { not: { assignee_username: [user2.username, user3.username] } } }
- let(:expected_issuables) { [issue1, issue2, issue4] }
+ before do
+ issue2.assignees = [user2]
+ end
+
+ let(:params) { { not: { assignee_username: [user.username, user2.username] } } }
+ let(:expected_issuables) { [issue3, issue4] }
end
end
@@ -395,8 +400,8 @@ describe IssuesFinder do
context 'using NOT' do
let(:params) { { not: { label_name: [label.title, label2.title].join(',') } } }
- it 'returns issues that do not have ALL labels provided' do
- expect(issues).to contain_exactly(issue1, issue3, issue4)
+ it 'returns issues that do not have any of the labels provided' do
+ expect(issues).to contain_exactly(issue1, issue4)
end
end
end
@@ -417,8 +422,8 @@ describe IssuesFinder do
context 'using NOT' do
let(:params) { { not: { label_name: [label.title, label2.title].join(',') } } }
- it 'returns issues that do not have ALL labels provided' do
- expect(issues).to contain_exactly(issue1, issue3, issue4)
+ it 'returns issues that do not have ANY ONE of the labels provided' do
+ expect(issues).to contain_exactly(issue1, issue4)
end
end
end