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
c206ad40
Commit
c206ad40
authored
Mar 22, 2018
by
Grzegorz Bizon
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix multi-project pipelines after services refactoring
parent
2f054c2d
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
8 additions
and
3 deletions
+8
-3
app/services/ci/pipeline_trigger_service.rb
app/services/ci/pipeline_trigger_service.rb
+2
-3
spec/requests/api/triggers_spec.rb
spec/requests/api/triggers_spec.rb
+6
-0
No files found.
app/services/ci/pipeline_trigger_service.rb
View file @
c206ad40
...
...
@@ -37,14 +37,13 @@ module Ci
pipeline
=
Ci
::
CreatePipelineService
.
new
(
project
,
job
.
user
,
ref:
params
[
:ref
])
.
execute
(
:pipeline
,
ignore_skip_ci:
true
)
do
|
pipeline
|
# TODO this needs a solution and specs
job
.
sourced_pipelines
.
build
(
source
=
job
.
sourced_pipelines
.
build
(
source_pipeline:
job
.
pipeline
,
source_project:
job
.
project
,
pipeline:
pipeline
,
project:
project
)
pipeline
.
source_pipeline
=
source
pipeline
.
variables
.
build
(
variables
)
end
...
...
spec/requests/api/triggers_spec.rb
View file @
c206ad40
...
...
@@ -185,6 +185,12 @@ describe API::Triggers do
expect
(
response
).
to
have_http_status
(
201
)
expect
(
Ci
::
Pipeline
.
last
.
source
).
to
eq
(
'pipeline'
)
expect
(
Ci
::
Pipeline
.
last
.
triggered_by_pipeline
).
not_to
be_nil
expect
(
Ci
::
Sources
::
Pipeline
.
last
).
to
have_attributes
(
pipeline_id:
(
a_value
>
0
),
source_pipeline_id:
(
a_value
>
0
),
source_job_id:
(
a_value
>
0
),
source_project_id:
(
a_value
>
0
)
)
end
context
'when build is complete'
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