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
0
Merge Requests
0
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
Boxiang Sun
gitlab-ce
Commits
d7b8b38d
Commit
d7b8b38d
authored
Jul 12, 2017
by
tauriedavis
Committed by
Phil Hughes
Jul 28, 2017
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
try and fix some tests
parent
aaaa252e
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
16 additions
and
6 deletions
+16
-6
app/views/projects/_merge_request_settings.html.haml
app/views/projects/_merge_request_settings.html.haml
+1
-1
spec/features/projects/features_visibility_spec.rb
spec/features/projects/features_visibility_spec.rb
+9
-3
spec/features/projects/project_settings_spec.rb
spec/features/projects/project_settings_spec.rb
+6
-2
No files found.
app/views/projects/_merge_request_settings.html.haml
View file @
d7b8b38d
spec/features/projects/features_visibility_spec.rb
View file @
d7b8b38d
...
@@ -20,17 +20,23 @@ describe 'Edit Project Settings' do
...
@@ -20,17 +20,23 @@ describe 'Edit Project Settings' do
visit
edit_project_path
(
project
)
visit
edit_project_path
(
project
)
select
'Disabled'
,
from:
"project_project_feature_attributes_
#{
tool_name
}
_access_level"
select
'Disabled'
,
from:
"project_project_feature_attributes_
#{
tool_name
}
_access_level"
page
.
within
(
'.sharing-permissions'
)
do
click_button
'Save changes'
click_button
'Save changes'
end
wait_for_requests
wait_for_requests
expect
(
page
).
not_to
have_selector
(
".shortcuts-
#{
shortcut_name
}
"
)
expect
(
page
).
not_to
have_selector
(
".shortcuts-
#{
shortcut_name
}
"
)
select
'Everyone with access'
,
from:
"project_project_feature_attributes_
#{
tool_name
}
_access_level"
select
'Everyone with access'
,
from:
"project_project_feature_attributes_
#{
tool_name
}
_access_level"
page
.
within
(
'.sharing-permissions'
)
do
click_button
'Save changes'
click_button
'Save changes'
end
wait_for_requests
wait_for_requests
expect
(
page
).
to
have_selector
(
".shortcuts-
#{
shortcut_name
}
"
)
expect
(
page
).
to
have_selector
(
".shortcuts-
#{
shortcut_name
}
"
)
select
'Only team members'
,
from:
"project_project_feature_attributes_
#{
tool_name
}
_access_level"
select
'Only team members'
,
from:
"project_project_feature_attributes_
#{
tool_name
}
_access_level"
page
.
within
(
'.sharing-permissions'
)
do
click_button
'Save changes'
click_button
'Save changes'
end
wait_for_requests
wait_for_requests
expect
(
page
).
to
have_selector
(
".shortcuts-
#{
shortcut_name
}
"
)
expect
(
page
).
to
have_selector
(
".shortcuts-
#{
shortcut_name
}
"
)
...
...
spec/features/projects/project_settings_spec.rb
View file @
d7b8b38d
...
@@ -14,7 +14,9 @@ describe 'Edit Project Settings' do
...
@@ -14,7 +14,9 @@ describe 'Edit Project Settings' do
it
'shows errors for invalid project name'
do
it
'shows errors for invalid project name'
do
visit
edit_project_path
(
project
)
visit
edit_project_path
(
project
)
fill_in
'project_name_edit'
,
with:
'foo&bar'
fill_in
'project_name_edit'
,
with:
'foo&bar'
page
.
within
(
'.general-settings'
)
do
click_button
'Save changes'
click_button
'Save changes'
end
expect
(
page
).
to
have_field
'project_name_edit'
,
with:
'foo&bar'
expect
(
page
).
to
have_field
'project_name_edit'
,
with:
'foo&bar'
expect
(
page
).
to
have_content
"Name can contain only letters, digits, emojis, '_', '.', dash, space. It must start with letter, digit, emoji or '_'."
expect
(
page
).
to
have_content
"Name can contain only letters, digits, emojis, '_', '.', dash, space. It must start with letter, digit, emoji or '_'."
expect
(
page
).
to
have_button
'Save changes'
expect
(
page
).
to
have_button
'Save changes'
...
@@ -23,7 +25,9 @@ describe 'Edit Project Settings' do
...
@@ -23,7 +25,9 @@ describe 'Edit Project Settings' do
it
'shows a successful notice when the project is updated'
do
it
'shows a successful notice when the project is updated'
do
visit
edit_project_path
(
project
)
visit
edit_project_path
(
project
)
fill_in
'project_name_edit'
,
with:
'hello world'
fill_in
'project_name_edit'
,
with:
'hello world'
page
.
within
(
'.general-settings'
)
do
click_button
'Save changes'
click_button
'Save changes'
end
expect
(
page
).
to
have_content
"Project 'hello world' was successfully updated."
expect
(
page
).
to
have_content
"Project 'hello world' was successfully updated."
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