Make all configuration in-repo configuration
We need a way to get the ansible playbooks onto the ansible launch
servers. That's easy for jobs defined in-repo because their repo
will already be on the launch server by definition. But for the
tenant-global config, those playbooks (and roles, etc) need to be
made available as well. Rather than shipping them around on the
gearman bus which is inefficient, let's just say that those will
also be in a repo. Probably the same repo that defines the jobs,
ie in our case, the project-config repo.
In other words -- by making the global config one or more repos
that zuul knows about, the merger component of the launch server
can prepare *that* repo as well as the others involved in any
job, so that the playbooks are available to ansible.
This also has the potential upside of making changes that Depends-On
zuul configuration or ansible playbook changes much more natural
to implement.
We also keep track of the source repo for job definitions so that
we can potentially use that to tell the launch server what repos
should be included for playbooks, though this is not plumbed through
yet.
This adds some features to the test framework to copy a directory
in the fixtures dir into a git repo since we're going to have a
lot more 'git repo content' that should just be in the fixtures dir.
It also removes the merge worker from the tests because it was
racing with the ansible launcher cat handler. The merge worker
can probably be completely removed in a later change.
Change-Id: I8fc5a8f627e3d915d54d15e70b7960655a6332a1
diff --git a/tests/test_v3.py b/tests/test_v3.py
index 8425383..8874015 100644
--- a/tests/test_v3.py
+++ b/tests/test_v3.py
@@ -38,6 +38,8 @@
self.waitUntilSettled()
self.assertEqual(self.getJobFromHistory('project1-test1').result,
'SUCCESS')
+ self.assertEqual(self.getJobFromHistory('python27').result,
+ 'SUCCESS')
self.assertEqual(A.data['status'], 'MERGED')
self.assertEqual(A.reported, 2,
"A should report start and success")
@@ -50,6 +52,9 @@
B.addApproval('CRVW', 2)
self.fake_gerrit.addEvent(B.addApproval('APRV', 1))
self.waitUntilSettled()
+ self.assertEqual(self.getJobFromHistory('python27',
+ 'org/project2').result,
+ 'SUCCESS')
self.assertEqual(self.getJobFromHistory('project2-test1').result,
'SUCCESS')
self.assertEqual(B.data['status'], 'MERGED')