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
694f31dd
Commit
694f31dd
authored
May 08, 2017
by
Grzegorz Bizon
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix skipped manual actions issue in pipeline processing
parent
62b0eb2c
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
27 additions
and
1 deletion
+27
-1
app/services/ci/process_pipeline_service.rb
app/services/ci/process_pipeline_service.rb
+1
-1
changelogs/unreleased/fix-gb-fix-skipped-manual-actions.yml
changelogs/unreleased/fix-gb-fix-skipped-manual-actions.yml
+4
-0
spec/services/ci/process_pipeline_service_spec.rb
spec/services/ci/process_pipeline_service_spec.rb
+22
-0
No files found.
app/services/ci/process_pipeline_service.rb
View file @
694f31dd
...
...
@@ -50,7 +50,7 @@ module Ci
when
'always'
%w[success failed skipped]
when
'manual'
%w[success]
%w[success
skipped
]
else
[]
end
...
...
changelogs/unreleased/fix-gb-fix-skipped-manual-actions.yml
0 → 100644
View file @
694f31dd
---
title
:
Fix skipped manual actions problem when processing the pipeline
merge_request
:
11164
author
:
spec/services/ci/process_pipeline_service_spec.rb
View file @
694f31dd
...
...
@@ -268,6 +268,24 @@ describe Ci::ProcessPipelineService, '#execute', :services do
end
end
context
'when there are only manual actions in stages'
do
before
do
create_build
(
'image'
,
stage_idx:
0
,
when:
'manual'
,
allow_failure:
true
)
create_build
(
'build'
,
stage_idx:
1
,
when:
'manual'
,
allow_failure:
true
)
create_build
(
'deploy'
,
stage_idx:
2
,
when:
'manual'
)
create_build
(
'check'
,
stage_idx:
3
)
process_pipeline
end
it
'processes all jobs until blocking actions encountered'
do
expect
(
all_builds_statuses
).
to
eq
(
%w[manual manual manual created]
)
expect
(
all_builds_names
).
to
eq
(
%w[image build deploy check]
)
expect
(
pipeline
.
reload
).
to
be_blocked
end
end
context
'when blocking manual actions are defined'
do
before
do
create_build
(
'code:test'
,
stage_idx:
0
)
...
...
@@ -441,6 +459,10 @@ describe Ci::ProcessPipelineService, '#execute', :services do
builds
.
pluck
(
:name
)
end
def
all_builds_names
all_builds
.
pluck
(
:name
)
end
def
builds_statuses
builds
.
pluck
(
:status
)
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