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
f99cee8e
Commit
f99cee8e
authored
Jun 14, 2017
by
Lin Jen-Shin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix other renaming
parent
edc46ce3
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
11 additions
and
11 deletions
+11
-11
spec/features/projects/jobs_spec.rb
spec/features/projects/jobs_spec.rb
+11
-11
No files found.
spec/features/projects/jobs_spec.rb
View file @
f99cee8e
...
@@ -137,27 +137,27 @@ feature 'Jobs', :feature do
...
@@ -137,27 +137,27 @@ feature 'Jobs', :feature do
end
end
context
'when job is not running'
,
:js
do
context
'when job is not running'
,
:js
do
let
(
:
build
)
{
create
(
:ci_build
,
:success
,
pipeline:
pipeline
)
}
let
(
:
job
)
{
create
(
:ci_build
,
:success
,
pipeline:
pipeline
)
}
before
do
before
do
visit
namespace_project_job_path
(
project
.
namespace
,
project
,
build
)
visit
namespace_project_job_path
(
project
.
namespace
,
project
,
job
)
end
end
it
'shows retry button'
do
it
'shows retry button'
do
expect
(
page
).
to
have_link
(
'Retry'
)
expect
(
page
).
to
have_link
(
'Retry'
)
end
end
context
'if
build
passed'
do
context
'if
job
passed'
do
it
'does not show New issue button'
do
it
'does not show New issue button'
do
expect
(
page
).
not_to
have_link
(
'New issue'
)
expect
(
page
).
not_to
have_link
(
'New issue'
)
end
end
end
end
context
'if
build
failed'
do
context
'if
job
failed'
do
let
(
:
build
)
{
create
(
:ci_build
,
:failed
,
pipeline:
pipeline
)
}
let
(
:
job
)
{
create
(
:ci_build
,
:failed
,
pipeline:
pipeline
)
}
before
do
before
do
visit
namespace_project_job_path
(
namespace
,
project
,
build
)
visit
namespace_project_job_path
(
namespace
,
project
,
job
)
end
end
it
'shows New issue button'
do
it
'shows New issue button'
do
...
@@ -165,9 +165,9 @@ feature 'Jobs', :feature do
...
@@ -165,9 +165,9 @@ feature 'Jobs', :feature do
end
end
it
'links to issues/new with the title and description filled in'
do
it
'links to issues/new with the title and description filled in'
do
button_title
=
"Build Failed #
#{
build
.
id
}
"
button_title
=
"Build Failed #
#{
job
.
id
}
"
build_path
=
namespace_project_job_path
(
namespace
,
project
,
build
)
job_path
=
namespace_project_job_path
(
namespace
,
project
,
job
)
options
=
{
issue:
{
title:
button_title
,
description:
build
_path
}
}
options
=
{
issue:
{
title:
button_title
,
description:
job
_path
}
}
href
=
new_namespace_project_issue_path
(
namespace
,
project
,
options
)
href
=
new_namespace_project_issue_path
(
namespace
,
project
,
options
)
...
@@ -467,7 +467,7 @@ feature 'Jobs', :feature do
...
@@ -467,7 +467,7 @@ feature 'Jobs', :feature do
.
to
receive
(
:paths
)
.
to
receive
(
:paths
)
.
and_return
([
existing_file
])
.
and_return
([
existing_file
])
visit
namespace_project_job_path
(
namespace
,
project
,
build
)
visit
namespace_project_job_path
(
namespace
,
project
,
job
)
find
(
'.js-raw-link-controller'
).
click
find
(
'.js-raw-link-controller'
).
click
end
end
...
@@ -485,7 +485,7 @@ feature 'Jobs', :feature do
...
@@ -485,7 +485,7 @@ feature 'Jobs', :feature do
.
to
receive
(
:paths
)
.
to
receive
(
:paths
)
.
and_return
([])
.
and_return
([])
visit
namespace_project_job_path
(
namespace
,
project
,
build
)
visit
namespace_project_job_path
(
namespace
,
project
,
job
)
end
end
it
'sends the right headers'
do
it
'sends the right headers'
do
...
...
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