Add support for roles in zuul

This adds support for Ansible roles in Zuul-managed repos.  It
is currently limited to repos within the same source, which is
something we should fix.

We also plan to add support for roles from Ansible Galaxy in a
future change.

Change-Id: I7af4dc1333db0dcb9d4a8318a4a95b9564cd1dd8
diff --git a/tests/fixtures/config/ansible/git/bare-role/tasks/main.yaml b/tests/fixtures/config/ansible/git/bare-role/tasks/main.yaml
new file mode 100644
index 0000000..75943b1
--- /dev/null
+++ b/tests/fixtures/config/ansible/git/bare-role/tasks/main.yaml
@@ -0,0 +1,3 @@
+- file:
+    path: "{{zuul._test.test_root}}/{{zuul.uuid}}.bare-role.flag"
+    state: touch
diff --git a/tests/fixtures/config/ansible/git/common-config/playbooks/python27.yaml b/tests/fixtures/config/ansible/git/common-config/playbooks/python27.yaml
index 408810e..6b79a78 100644
--- a/tests/fixtures/config/ansible/git/common-config/playbooks/python27.yaml
+++ b/tests/fixtures/config/ansible/git/common-config/playbooks/python27.yaml
@@ -6,3 +6,5 @@
     - copy:
         src: "{{zuul._test.test_root}}/{{zuul.uuid}}.flag"
         dest: "{{zuul._test.test_root}}/{{zuul.uuid}}.copied"
+  roles:
+    - bare-role
diff --git a/tests/fixtures/config/ansible/git/common-config/zuul.yaml b/tests/fixtures/config/ansible/git/common-config/zuul.yaml
index 7964243..7373eff 100644
--- a/tests/fixtures/config/ansible/git/common-config/zuul.yaml
+++ b/tests/fixtures/config/ansible/git/common-config/zuul.yaml
@@ -40,3 +40,5 @@
     name: python27
     pre-run: pre
     post-run: post
+    roles:
+      - zuul: bare-role
diff --git a/tests/fixtures/config/ansible/main.yaml b/tests/fixtures/config/ansible/main.yaml
index d9868fa..8df99f4 100644
--- a/tests/fixtures/config/ansible/main.yaml
+++ b/tests/fixtures/config/ansible/main.yaml
@@ -6,3 +6,4 @@
           - common-config
         project-repos:
           - org/project
+          - bare-role