Re-enable test_nonvoting_pipeline
Here we enabled our nonvoting pipeline test again. It seems we also needed to create a check pipeline noop job, otherwise our pipeline queues (for check) would not be empty. Change-Id: I1269e8de632f847dbacbde187d609bbab1ac8179 Signed-off-by: Paul Belanger <pabelanger@redhat.com>
This commit is contained in:
parent
2e2a0496cc
commit
15e3e20936
@ -36,6 +36,19 @@
|
||||
verified: 0
|
||||
precedence: high
|
||||
|
||||
- pipeline:
|
||||
name: experimental
|
||||
manager: independent
|
||||
source:
|
||||
gerrit
|
||||
trigger:
|
||||
gerrit:
|
||||
- event: patchset-created
|
||||
success:
|
||||
gerrit: {}
|
||||
failure:
|
||||
gerrit: {}
|
||||
|
||||
- job:
|
||||
name: project-merge
|
||||
hold-following-changes: true
|
||||
@ -56,6 +69,9 @@
|
||||
- job:
|
||||
name: project-test2
|
||||
|
||||
- job:
|
||||
name: experimental-project-test
|
||||
|
||||
- project:
|
||||
name: org/project
|
||||
gate:
|
||||
@ -84,3 +100,11 @@
|
||||
jobs:
|
||||
- project-test1
|
||||
- project-test2
|
||||
|
||||
- project:
|
||||
name: org/experimental-project
|
||||
experimental:
|
||||
jobs:
|
||||
- project-merge:
|
||||
jobs:
|
||||
- experimental-project-test
|
||||
|
1
tests/fixtures/config/single-tenant/git/org_experimental-project/README
vendored
Normal file
1
tests/fixtures/config/single-tenant/git/org_experimental-project/README
vendored
Normal file
@ -0,0 +1 @@
|
||||
test
|
@ -3884,7 +3884,6 @@ For CI problems and help debugging, contact ci@example.org"""
|
||||
running_items = client.get_running_jobs()
|
||||
self.assertEqual(0, len(running_items))
|
||||
|
||||
@skip("Disabled for early v3 development")
|
||||
def test_nonvoting_pipeline(self):
|
||||
"Test that a nonvoting pipeline (experimental) can still report"
|
||||
|
||||
@ -3892,6 +3891,9 @@ For CI problems and help debugging, contact ci@example.org"""
|
||||
'master', 'A')
|
||||
self.fake_gerrit.addEvent(A.getPatchsetCreatedEvent(1))
|
||||
self.waitUntilSettled()
|
||||
|
||||
self.assertEqual(self.getJobFromHistory('project-merge').result,
|
||||
'SUCCESS')
|
||||
self.assertEqual(
|
||||
self.getJobFromHistory('experimental-project-test').result,
|
||||
'SUCCESS')
|
||||
|
@ -29,8 +29,6 @@ class IndependentPipelineManager(PipelineManager):
|
||||
# creates a new change queue for every change
|
||||
if existing:
|
||||
return DynamicChangeQueueContextManager(existing)
|
||||
if change.project not in self.pipeline.getProjects():
|
||||
self.pipeline.addProject(change.project)
|
||||
change_queue = model.ChangeQueue(self.pipeline)
|
||||
change_queue.addProject(change.project)
|
||||
self.pipeline.addQueue(change_queue)
|
||||
|
@ -1770,9 +1770,13 @@ class Layout(object):
|
||||
|
||||
def createJobTree(self, item):
|
||||
project_config = self.project_configs[item.change.project.name]
|
||||
project_tree = project_config.pipelines[item.pipeline.name].job_tree
|
||||
ret = JobTree(None)
|
||||
self._createJobTree(item.change, project_tree.job_trees, ret)
|
||||
# NOTE(pabelanger): It is possible for a foreign project not to have a
|
||||
# configured pipeline, if so return an empty JobTree.
|
||||
if item.pipeline.name in project_config.pipelines:
|
||||
project_tree = \
|
||||
project_config.pipelines[item.pipeline.name].job_tree
|
||||
self._createJobTree(item.change, project_tree.job_trees, ret)
|
||||
return ret
|
||||
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user