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
1ec51361
Commit
1ec51361
authored
Jul 19, 2017
by
Takuya Noguchi
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Hide description about protected branches to non-member
parent
3453bc32
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
16 additions
and
4 deletions
+16
-4
app/views/projects/branches/index.html.haml
app/views/projects/branches/index.html.haml
+4
-3
changelogs/unreleased/35253-desc-protected-branches-for-non-member.yml
...released/35253-desc-protected-branches-for-non-member.yml
+4
-0
spec/features/projects/branches_spec.rb
spec/features/projects/branches_spec.rb
+8
-1
No files found.
app/views/projects/branches/index.html.haml
View file @
1ec51361
...
...
@@ -4,6 +4,7 @@
%div
{
class:
container_class
}
.top-area.adjust
-
if
can?
(
current_user
,
:admin_project
,
@project
)
.nav-text
Protected branches can be managed in
=
link_to
'project settings'
,
project_protected_branches_path
(
@project
)
...
...
changelogs/unreleased/35253-desc-protected-branches-for-non-member.yml
0 → 100644
View file @
1ec51361
---
title
:
Hide description about protected branches to non-member
merge_request
:
12945
author
:
Takuya Noguchi
spec/features/projects/branches_spec.rb
View file @
1ec51361
...
...
@@ -24,7 +24,6 @@ describe 'Branches', feature: true do
repository
.
branches_sorted_by
(
:name
).
first
(
20
).
each
do
|
branch
|
expect
(
page
).
to
have_content
(
"
#{
branch
.
name
}
"
)
end
expect
(
page
).
to
have_content
(
"Protected branches can be managed in project settings"
)
end
it
'sorts the branches by name'
do
...
...
@@ -130,6 +129,14 @@ describe 'Branches', feature: true do
project
.
team
<<
[
user
,
:master
]
end
describe
'Initial branches page'
do
it
'shows description for admin'
do
visit
project_branches_path
(
project
)
expect
(
page
).
to
have_content
(
"Protected branches can be managed in project settings"
)
end
end
describe
'Delete protected branch'
do
before
do
visit
project_protected_branches_path
(
project
)
...
...
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