Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
gitlab-ce
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
1
Merge Requests
1
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
gitlab-ce
Commits
4b963016
Commit
4b963016
authored
Oct 02, 2020
by
Felipe Artur
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Hide test cases from issue boards
Do not list test cases under issue boards
parent
cf2bca62
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
17 additions
and
0 deletions
+17
-0
app/services/boards/issues/list_service.rb
app/services/boards/issues/list_service.rb
+5
-0
ee/spec/services/ee/boards/issues/list_service_spec.rb
ee/spec/services/ee/boards/issues/list_service_spec.rb
+12
-0
No files found.
app/services/boards/issues/list_service.rb
View file @
4b963016
...
...
@@ -80,6 +80,7 @@ module Boards
set_scope
set_non_archived
set_attempt_search_optimizations
set_issue_types
params
end
...
...
@@ -116,6 +117,10 @@ module Boards
end
end
def
set_issue_types
params
[
:issue_types
]
=
Issue
::
TYPES_FOR_LIST
end
# rubocop: disable CodeReuse/ActiveRecord
def
board_label_ids
@board_label_ids
||=
board
.
lists
.
movable
.
pluck
(
:label_id
)
...
...
ee/spec/services/ee/boards/issues/list_service_spec.rb
View file @
4b963016
...
...
@@ -180,6 +180,18 @@ RSpec.describe Boards::Issues::ListService, services: true do
expect
(
issues
).
to
contain_exactly
(
opened_issue1
,
opened_issue2
,
reopened_issue1
)
end
end
context
'when test cases are present'
do
it
'filters out test cases'
do
create
(
:quality_test_case
,
project:
project
,
milestone:
m1
,
title:
'Test Case 1'
,
labels:
[
development
])
incident
=
create
(
:incident
,
project:
project
,
milestone:
m1
,
title:
'Incident 1'
,
labels:
[
development
])
params
=
{
board_id:
board
.
id
,
id:
list1
.
id
}
issues
=
described_class
.
new
(
parent
,
user
,
params
).
execute
expect
(
issues
).
to
match_array
([
list1_issue1
,
list1_issue2
,
list1_issue3
,
incident
])
end
end
end
end
end
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment