Add integration-replace-block-text macro
[releng/builder.git] / jjb / integration / integration-test-jobs.yaml
1 - project:
2     name: integration-test
3     jobs:
4         - '{project-name}-verify-tox-{stream}'
5         - 'integration-csit-verify-1node-library'
6         - 'integration-distribution-test-{stream}'
7         - 'integration-patch-test-{stream}'
8         - 'integration-multipatch-test-{stream}'
9
10     project: integration/test
11     project-name: integration-test
12
13     # CSIT Lists in releng-defaults.yaml
14     stream:
15         - carbon:
16             branch: 'master'
17             jdk: 'openjdk8'
18             jre: 'openjdk8'
19             csit-list: {csit-list-carbon}
20
21         - boron:
22             branch: 'stable/boron'
23             jdk: 'openjdk8'
24             jre: 'openjdk8'
25             csit-list: {csit-list-boron}
26
27         - beryllium:
28             branch: 'stable/beryllium'
29             jdk: 'openjdk7'
30             jre: 'openjdk7'
31             csit-list: {csit-list-beryllium}
32
33     # tools system image
34     tools_system_image: Ubuntu 14.04 - mininet-ovs-2.5 - 20170117-0004
35
36 # Template: integration-csit-verify-1node-library
37 # Goal: Verify changes in csit folder not covered by projects suite verify jobs (e.g. libraries or variables)
38 # Operation: This job template performs a base openflow test when there is a change in the libraries folder
39
40 - job-template:
41     name: 'integration-csit-verify-1node-library'
42
43     project-type: freestyle
44     node: centos7-robot-2c-2g
45
46     properties:
47         - opendaylight-infra-properties:
48             build-days-to-keep: '{build-days-to-keep}'
49
50     parameters:
51         - opendaylight-infra-parameters:
52             project: 'integration/test'
53             branch: '{branch}'
54             refspec: 'refs/heads/{branch}'
55             artifacts: '{archive-artifacts}'
56         # when upgrading to carbon you should replace odl-netconf-connector-all with odl-netconf-topology from
57         # controller-features and change USE_NETCONF_CONNECTOR to False in test-options
58         - integration-branch:
59             branch: 'stable/boron'
60         - integration-distribution-stream:
61             stream: 'boron'
62         - integration-bundleurl:
63             bundleurl: '{bundleurl}'
64         - integration-controller-scope:
65             controller-scope: 'only'
66         - integration-controller-features:
67             controller-features: >
68                 odl-clustering-test-app,
69                 odl-openflowplugin-flow-services-ui,
70                 odl-openflowplugin-app-table-miss-enforcer,
71                 odl-bgpcep-pcep,
72                 odl-bgpcep-bgp,
73                 odl-netconf-connector-all
74         - integration-test-options:
75             test-options: '-v TIMEOUT_BUG_4220:10s -v USE_NETCONF_CONNECTOR:True'
76         - integration-stream-test-plan:
77             stream-test-plan: 'test-libraries-boron.txt'
78         - integration-test-plan:
79             test-plan: 'test-libraries.txt'
80         - integration-patch-refspec:
81             branch: '$GERRIT_REFSPEC'
82         - integration-jdk-version:
83             jdkversion: 'openjdk8'
84
85     scm:
86         - integration-gerrit-scm:
87             basedir: 'test'
88             refspec: '$PATCHREFSPEC'
89             branch: 'master'
90
91     wrappers:
92         - opendaylight-infra-wrappers:
93             build-timeout: '{build-timeout}'
94
95     triggers:
96         - integration-trigger-patch-submitted:
97             server: '{server-name}'
98             project: '{project}'
99             branch: 'master'
100             files: 'csit/libraries/*'
101
102     builders:
103         - integration-infra-stack:
104             stack-template: '{stack-template}'
105             vm_0_count: '1'
106             vm_0_flavor: '{odl_system_flavor}'
107             vm_0_image: '{odl_system_image}'
108             vm_1_count: '{tools_system_count}'
109             vm_1_flavor: '{tools_system_flavor}'
110             vm_1_image: '{tools_system_image}'
111         - integration-install-robotframework
112         - inject:
113             properties-file: 'env.properties'
114         - integration-get-slave-addresses
115         - inject:
116             properties-file: 'slave_addresses.txt'
117         - integration-get-bundle-vars
118         - inject:
119             properties-file: 'bundle_vars.txt'
120         - integration-deploy-controller-run-test
121         - integration-cleanup-tmp
122
123     publishers:
124         - integration-robot:
125             unstable-if: 0.0
126             pass-if: 100.0
127         - email-notification:
128             email-recipients: '{email-recipients}'
129             email-prefix: '[integration]'
130         - integration-csit-archive-build
131         - opendaylight-infra-shiplogs:
132             maven-version: 'mvn33'
133
134 # Template: integration-distribution-test-{stream}
135 # Goal: Verify a distribution through all system test available
136 # Operation: This daily job template takes a distribution and passes all available system test
137
138 - job-template:
139     name: 'integration-distribution-test-{stream}'
140
141     project-type: freestyle
142     node: centos7-java-builder-2c-8g
143
144     properties:
145         - opendaylight-infra-properties:
146             build-days-to-keep: '{build-days-to-keep}'
147
148     parameters:
149         - integration-bundleurl:
150             bundleurl: '{bundleurl}'
151         - integration-jdk-version:
152             jdkversion: '{jre}'
153
154     triggers:
155         - timed: 'H H * * 6'
156
157     builders:
158         - trigger-builds:
159             - project: '{csit-list}'
160               block: true
161               predefined-parameters:
162                   BUNDLEURL=$BUNDLEURL
163
164     publishers:
165         - email-notification:
166             email-recipients: '{email-recipients}'
167             email-prefix: '[integration]'
168
169 # Template: integration-patch-test-{stream}
170 # Goal: Build a patch and run all available system test on a distribution containing the change
171 # Operation: This job template builds a patch, creates a distribution containing the patch, and
172 # triggers the distribution test when test-integration is used in gerrit comments
173
174 - job-template:
175     name: 'integration-patch-test-{stream}'
176
177     project-type: maven
178     node: centos7-java-builder-2c-8g
179     jdk: '{jdk}'
180
181     properties:
182         - opendaylight-infra-properties:
183             build-days-to-keep: '{build-days-to-keep}'
184
185     parameters:
186         - opendaylight-infra-parameters:
187             project: '$GERRIT_PROJECT'
188             branch: '{branch}'
189             refspec: '$GERRIT_REFSPEC'
190             artifacts: '{archive-artifacts} **/dependency_tree.txt'
191         - integration-branch:
192             branch: '{branch}'
193         - integration-distribution-git-url:
194             git-url: '{git-url}'
195
196     scm:
197         - integration-gerrit-scm:
198             basedir: '$GERRIT_PROJECT'
199             refspec: '$GERRIT_REFSPEC'
200             branch: '{branch}'
201         - integration-distribution-scm:
202             branch: '{branch}'
203
204     wrappers:
205         - opendaylight-infra-wrappers:
206             build-timeout: '720'
207
208     triggers:
209         - gerrit:
210             server-name: '{server-name}'
211             trigger-on:
212                 - comment-added-contains-event:
213                     comment-contains-value: 'test-integration'
214             projects:
215               - project-compare-type: 'ANT'
216                 project-pattern: '**'
217                 branches:
218                   - branch-compare-type: 'ANT'
219                     branch-pattern: '**/{branch}'
220             skip-vote:
221                 successful: true
222                 failed: true
223                 unstable: true
224                 notbuilt: true
225
226     prebuilders:
227         - integration-rebase-gerrit-patch
228         - integration-get-bundle-url
229         - inject:
230             properties-file: 'bundle.txt'
231         - wipe-org-opendaylight-repo
232         - provide-maven-settings:
233             global-settings-file: 'odl-global-settings'
234             settings-file: 'integration-settings'
235         - maven-target:
236             maven-version: 'mvn33'
237             pom: '$GERRIT_PROJECT/pom.xml'
238             goals: 'clean install dependency:tree -DoutputFile=dependency_tree.txt -V -B -Pq -Djenkins -Dmaven.repo.local=/tmp/r -Dorg.ops4j.pax.url.mvn.localRepository=/tmp/r -Dstream={stream}'
239             java-opts:
240                 - '-Xmx4096m -XX:MaxPermSize=1024m -Dmaven.compile.fork=true'
241             settings: 'integration-settings'
242             settings-type: cfp
243             global-settings: 'odl-global-settings'
244             global-settings-type: cfp
245
246     maven:
247         maven-name: 'mvn33'
248         root-pom: 'distribution/pom.xml'
249         goals: 'clean install dependency:tree -DoutputFile=dependency_tree.txt -V -B -Djenkins -Dmaven.repo.local=/tmp/r -Dorg.ops4j.pax.url.mvn.localRepository=/tmp/r'
250         maven-opts: '-Xmx1024m -XX:MaxPermSize=256m -Dmaven.compile.fork=true'
251         settings: 'integration-settings'
252         settings-type: cfp
253         global-settings: 'odl-global-settings'
254         global-settings-type: cfp
255         ignore-upstream-changes: true
256         post-step-run-condition: 'SUCCESS'
257
258     postbuilders:
259         - trigger-builds:
260             - project: '{csit-list}'
261               block: true
262               predefined-parameters:
263                   BUNDLEURL=$BUNDLEURL
264
265     publishers:
266         - opendaylight-infra-shiplogs:
267             maven-version: 'mvn33'
268         - email-notification:
269             email-recipients: '{email-recipients}'
270             email-prefix: '[$GERRIT_PROJECT]'
271
272 # Template: integration-multipatch-test-{stream}
273 # Goal: Build one or more patches and run all available system test on a distribution containing the change
274 # Operation: This job template checks out and builds each patch provided in job parameters, creates a distribution
275 # containing these patches, and triggers the distribution test job which includes most (if not all) available
276 # CSIT jobs
277
278 - job-template:
279     name: 'integration-multipatch-test-{stream}'
280
281     project-type: maven
282     node: centos7-java-builder-8c-8g
283     jdk: '{jdk}'
284
285     properties:
286         - opendaylight-infra-properties:
287             build-days-to-keep: '{build-days-to-keep}'
288
289     parameters:
290         - patches-to-build-parameter:
291             patches_to_build: '$PATCHES_TO_BUILD'
292         - integration-branch:
293             branch: '{branch}'
294         - opendaylight-infra-parameters:
295             project: 'integration/distribution'
296             branch: '{branch}'
297             refspec: 'refs/heads/{branch}'
298             artifacts: '{archive-artifacts} **/dependency_tree.txt'
299
300     prebuilders:
301         - wipe-org-opendaylight-repo
302         - integration-multipatch-builder
303         - inject:
304             properties-file: 'bundle.txt'
305         - provide-maven-settings:
306             global-settings-file: 'odl-global-settings'
307             settings-file: 'yangtools-settings'
308
309     wrappers:
310         - opendaylight-infra-wrappers:
311             build-timeout: '1200'
312
313     maven:
314         maven-name: 'mvn33'
315         root-pom: 'patch_tester/pom.xml'
316         # TODO: Make Maven options configurable. Currently tests are not skipped, everything else is.
317         goals: 'clean install dependency:tree -DoutputFile=dependency_tree.txt -f patch_tester/pom.xml -V -B -Pq -Djenkins -Dmaven.repo.local=/tmp/r -Dorg.ops4j.pax.url.mvn.localRepository=/tmp/r -Dstream={stream}'
318         maven-opts: '-Xmx7168m -XX:MaxPermSize=1024m -Dmaven.compile.fork=true'
319         settings: 'yangtools-settings'
320         settings-type: cfp
321         global-settings: 'odl-global-settings'
322         global-settings-type: cfp
323         post-step-run-condition: 'SUCCESS'
324
325     postbuilders:
326         - trigger-builds:
327             - project: '{csit-list}'
328               block: true
329               predefined-parameters:
330                   BUNDLEURL=$BUNDLEURL
331
332     publishers:
333         - opendaylight-infra-shiplogs:
334             maven-version: 'mvn33'
335         - email-notification:
336             email-recipients: '{email-recipients}'
337             email-prefix: '[int/dist]'