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
7b79ec07
Commit
7b79ec07
authored
Aug 21, 2017
by
Stan Hu
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix milestone Spinach tests by confirming modal only if it is present
parent
dda33bd7
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
12 additions
and
1 deletion
+12
-1
features/steps/project/issues/milestones.rb
features/steps/project/issues/milestones.rb
+2
-1
features/support/capybara_helpers.rb
features/support/capybara_helpers.rb
+10
-0
No files found.
features/steps/project/issues/milestones.rb
View file @
7b79ec07
...
@@ -3,6 +3,7 @@ class Spinach::Features::ProjectIssuesMilestones < Spinach::FeatureSteps
...
@@ -3,6 +3,7 @@ class Spinach::Features::ProjectIssuesMilestones < Spinach::FeatureSteps
include
SharedProject
include
SharedProject
include
SharedPaths
include
SharedPaths
include
SharedMarkdown
include
SharedMarkdown
include
CapybaraHelpers
step
'I should see milestone "v2.2"'
do
step
'I should see milestone "v2.2"'
do
milestone
=
@project
.
milestones
.
find_by
(
title:
"v2.2"
)
milestone
=
@project
.
milestones
.
find_by
(
title:
"v2.2"
)
...
@@ -63,7 +64,7 @@ class Spinach::Features::ProjectIssuesMilestones < Spinach::FeatureSteps
...
@@ -63,7 +64,7 @@ class Spinach::Features::ProjectIssuesMilestones < Spinach::FeatureSteps
end
end
step
'I click link to remove milestone'
do
step
'I click link to remove milestone'
do
c
lick_link
'Delete'
c
onfirm_modal_if_present
{
click_link
'Delete'
}
end
end
step
'I should see no milestones'
do
step
'I should see no milestones'
do
...
...
features/support/capybara_helpers.rb
0 → 100644
View file @
7b79ec07
module
CapybaraHelpers
def
confirm_modal_if_present
if
Capybara
.
current_driver
==
Capybara
.
javascript_driver
accept_confirm
{
yield
}
return
end
yield
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