summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorFelipe Artur <felipefac@gmail.com>2018-04-05 15:14:04 -0300
committerFelipe Artur <felipefac@gmail.com>2018-04-05 15:14:04 -0300
commitb9c0cf1318d663edc3af593f88521e86e0614824 (patch)
treec1f90c814e8eeb1d190f3ea202f091fb775be21d
parent7c6f4adac9bc2f0bba46a4267f1081c7542e4dc4 (diff)
downloadgitlab-ce-b9c0cf1318d663edc3af593f88521e86e0614824.tar.gz
Improve specs and docs
-rw-r--r--app/services/issues/update_service.rb2
-rw-r--r--doc/user/project/issue_board.md3
-rw-r--r--spec/services/issues/update_service_spec.rb6
3 files changed, 6 insertions, 5 deletions
diff --git a/app/services/issues/update_service.rb b/app/services/issues/update_service.rb
index 4161932ad2a..1374f10c586 100644
--- a/app/services/issues/update_service.rb
+++ b/app/services/issues/update_service.rb
@@ -90,7 +90,7 @@ module Issues
issue =
if board_group_id
- IssuesFinder.new(current_user, group_id: board_group_id).find_by(id: id)
+ IssuesFinder.new(current_user, group_id: board_group_id, include_subgroups: true).find_by(id: id)
else
project.issues.find(id)
end
diff --git a/doc/user/project/issue_board.md b/doc/user/project/issue_board.md
index b4a842f33d6..7eab825fa32 100644
--- a/doc/user/project/issue_board.md
+++ b/doc/user/project/issue_board.md
@@ -240,8 +240,7 @@ Issue Board, that is create/delete lists and drag issues around.
>Introduced in GitLab 10.6
Group issue board is analogous to project-level issue board and it is accessible at the group
-navigation level. A group-level issue board allows you to view all issues from all projects in that group
-(currently, it does not see issues from projects in subgroups). Similarly, you can only filter by group labels for these
+navigation level. A group-level issue board allows you to view all issues from all projects in that group or descendant subgroups. Similarly, you can only filter by group labels for these
boards. When updating milestones and labels for an issue through the sidebar update mechanism, again only
group-level objects are available.
diff --git a/spec/services/issues/update_service_spec.rb b/spec/services/issues/update_service_spec.rb
index f95474208f3..23b1134b5a3 100644
--- a/spec/services/issues/update_service_spec.rb
+++ b/spec/services/issues/update_service_spec.rb
@@ -97,11 +97,13 @@ describe Issues::UpdateService, :mailer do
expect(issue.relative_position).to be_between(issue1.relative_position, issue2.relative_position)
end
- context 'when moving issue between issues from different projects' do
+ context 'when moving issue between issues from different projects', :nested_groups do
let(:group) { create(:group) }
+ let(:subgroup) { create(:group, parent: group) }
+
let(:project_1) { create(:project, namespace: group) }
let(:project_2) { create(:project, namespace: group) }
- let(:project_3) { create(:project, namespace: group) }
+ let(:project_3) { create(:project, namespace: subgroup) }
let(:issue_1) { create(:issue, project: project_1) }
let(:issue_2) { create(:issue, project: project_2) }