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
Jérome Perrin
gitlab-ce
Commits
43f44d88
Commit
43f44d88
authored
Apr 25, 2018
by
Lin Jen-Shin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Clear local storage after test so it's not interfering
parent
9cc2123e
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
7 additions
and
1 deletion
+7
-1
qa/qa/page/project/settings/protected_branches.rb
qa/qa/page/project/settings/protected_branches.rb
+0
-1
qa/qa/specs/features/repository/protected_branches_spec.rb
qa/qa/specs/features/repository/protected_branches_spec.rb
+7
-0
No files found.
qa/qa/page/project/settings/protected_branches.rb
View file @
43f44d88
...
@@ -73,7 +73,6 @@ module QA
...
@@ -73,7 +73,6 @@ module QA
def
click_allow
(
action
,
text
)
def
click_allow
(
action
,
text
)
click_element
:"allowed_to_
#{
action
}
_select"
click_element
:"allowed_to_
#{
action
}
_select"
within_element
(
:"allowed_to_
#{
action
}
_dropdown"
)
do
within_element
(
:"allowed_to_
#{
action
}
_dropdown"
)
do
click_on
text
click_on
text
...
...
qa/qa/specs/features/repository/protected_branches_spec.rb
View file @
43f44d88
...
@@ -19,6 +19,13 @@ module QA
...
@@ -19,6 +19,13 @@ module QA
Page
::
Main
::
Login
.
act
{
sign_in_using_credentials
}
Page
::
Main
::
Login
.
act
{
sign_in_using_credentials
}
end
end
after
do
# We need to clear localStorage because we're using it for the dropdown,
# and capybara doesn't do this for us.
# https://github.com/teamcapybara/capybara/issues/1702
Capybara
.
execute_script
'localStorage.clear()'
end
scenario
'user is able to protect a branch'
do
scenario
'user is able to protect a branch'
do
protected_branch
=
Factory
::
Resource
::
Branch
.
fabricate!
do
|
resource
|
protected_branch
=
Factory
::
Resource
::
Branch
.
fabricate!
do
|
resource
|
resource
.
branch_name
=
branch_name
resource
.
branch_name
=
branch_name
...
...
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