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
454e9631
Commit
454e9631
authored
Nov 28, 2016
by
James Gregory
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
The admin user projects view now has a clickable group link
parent
a1556200
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
33 additions
and
1 deletion
+33
-1
app/views/admin/users/projects.html.haml
app/views/admin/users/projects.html.haml
+1
-1
changelogs/unreleased/feature-admin-user-groups-link.yml
changelogs/unreleased/feature-admin-user-groups-link.yml
+4
-0
spec/features/admin/admin_users_spec.rb
spec/features/admin/admin_users_spec.rb
+28
-0
No files found.
app/views/admin/users/projects.html.haml
View file @
454e9631
...
@@ -7,7 +7,7 @@
...
@@ -7,7 +7,7 @@
%ul
.well-list
%ul
.well-list
-
@user
.
groups
.
each
do
|
group
|
-
@user
.
groups
.
each
do
|
group
|
%li
%li
%strong
=
group
.
name
%strong
=
link_to
group
.
name
,
admin_group_path
(
group
)
–
access to
–
access to
#{
pluralize
(
group
.
projects
.
count
,
'project'
)
}
#{
pluralize
(
group
.
projects
.
count
,
'project'
)
}
...
...
changelogs/unreleased/feature-admin-user-groups-link.yml
0 → 100644
View file @
454e9631
---
title
:
The admin user projects view now has a clickable group link
merge_request
:
7620
author
:
James Gregory
spec/features/admin/admin_users_spec.rb
View file @
454e9631
...
@@ -225,4 +225,32 @@ describe "Admin::Users", feature: true do
...
@@ -225,4 +225,32 @@ describe "Admin::Users", feature: true do
end
end
end
end
end
end
describe
"GET /admin/users/:id/projects"
do
before
do
@group
=
create
(
:group
)
@project
=
create
(
:project
,
group:
@group
)
@simple_user
=
create
(
:user
)
@group
.
add_developer
(
@simple_user
)
visit
projects_admin_user_path
(
@simple_user
)
end
it
"lists group projects"
do
within
(
:css
,
'.append-bottom-default + .panel'
)
do
expect
(
page
).
to
have_content
'Group projects'
expect
(
page
).
to
have_link
@group
.
name
,
admin_group_path
(
@group
)
end
end
it
'allows navigation to the group details'
do
within
(
:css
,
'.append-bottom-default + .panel'
)
do
click_link
@group
.
name
end
within
(
:css
,
'h3.page-title'
)
do
expect
(
page
).
to
have_content
"Group:
#{
@group
.
name
}
"
end
expect
(
page
).
to
have_content
@project
.
name
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