Step 2: Change csit job templates to download 2 repositories
[releng/builder.git] / jjb / integration / integration-macros.yaml
index 960d3f057af16d8e474c69f4c03d4bdf4e0b489e..1952cd3cdcb97217810a3daf9e01596c5f6a8aac 100644 (file)
@@ -4,7 +4,7 @@
         - string:
             name: BRANCH
             default: '{branch}'
-            description: 'GIT branch'
+            description: 'Distribution GIT branch'
 
 - parameter:
     name: integration-bundleurl
@@ -63,7 +63,7 @@
             description: 'Integration Patch Refspec'
 
 # Macro: integration-gerrit-scm
-# Operation: this macro downloads a gerrit from any project and uses the project as basedir
+# Operation: this macro downloads a project gerrit and using the project name as basedir
 # Used by: integration-patch-test-{stream} job template
 
 - scm:
             skip-tag: true
             choosing-strategy: 'gerrit'
 
+# Macro: integration-gerrit-test-scm
+# Operation: this macro downloads an integration/test gerrit using test as basedir
+# Used by: {project}-verify-csit-* job templates
+
+- scm:
+    name: integration-gerrit-test-scm
+    scm:
+        - git:
+            credentials-id: '{credentials-id}'
+            url: '$GIT_BASE'
+            basedir: 'test'
+            refspec: '$GERRIT_REFSPEC'
+            branches:
+                - 'origin/{branch}'
+            skip-tag: true
+            choosing-strategy: 'gerrit'
+
 # Macro: integration-distribution-scm
-# Operation: this macro downloads the integration/distribution repo and uses distribution as basedir
+# Operation: this macro downloads the integration/distribution repo using distribution as basedir
 # Used by: {project}-csit-* and integration-patch-test-{stream} job templates
 
 - scm:
 # Used by: {project}-csit-* job templates
 
 - scm:
-    name: integration-patch-scm
+    name: integration-test-scm
     scm:
         - git:
             credentials-id: '{credentials-id}'
+            basedir: 'test'
             url: '$GIT_BASE'
             refspec: '$PATCHREFSPEC'
             branches:
                     branch-pattern: '**/{branch}'
                 file-paths:
                   - compare-type: 'ANT'
-                    pattern: 'test/csit/suites/{project}/**'
+                    pattern: 'csit/suites/{project}/**'
 
 # Macro: integration-csit-gerrit-trigger-patch-submitted
 # Operation: this macro sets a trigger for patch submit on test/csit/**
                     branch-pattern: '**/{branch}'
                 file-paths:
                   - compare-type: 'ANT'
-                    pattern: 'test/csit/**'
+                    pattern: 'csit/**'
 
 # Macro: integration-csit-gerrit-trigger-patch-merged
 # Operation: this macro sets a trigger for patch merged on test/csit/**
                     branch-pattern: '**/{branch}'
                 file-paths:
                   - compare-type: 'ANT'
-                    pattern: 'test/csit/**'
+                    pattern: 'csit/**'
 
 # Macro: integration-jclouds-controller-mininet
 # Operation: this macro will spin the controller and mininet vms