Remove Policy k8s jenkins job from ONAP
[ci-management.git] / jjb / integration / integration-macros.yaml
1 ---
2 - parameter:
3     name: integration-test-plan
4     parameters:
5       - string:
6           name: TESTPLAN
7           default: '{test-plan}'
8           description: 'General test plan we will run unless stream-specific one is found'
9
10 - parameter:
11     name: integration-test-options
12     parameters:
13       - string:
14           name: TESTOPTIONS
15           default: '{test-options}'
16           description: 'Robot command options'
17
18 - parameter:
19     name: html-publisher-dir
20     parameters:
21       - string:
22           name: HTMLDIR
23           default: '{html-dir}'
24           description: 'Directory location to be used by HTML publisher plugin'
25
26 - parameter:
27     name: html-publisher-files
28     parameters:
29       - string:
30           name: HTMLFILES
31           default: '{html-files}'
32           description: 'File name to be used by HTML publisher plugin to produce the report'
33
34 - builder:
35     name: integration-install-robotframework
36     builders:
37       - shell:
38           !include-raw:
39           - include-raw-integration-install-robotframework.sh
40
41 - builder:
42     name: integration-install-robotframework-py3
43     builders:
44       - shell:
45           !include-raw:
46           - include-raw-integration-install-robotframework-py3.sh
47
48 - builder:
49     name: integration-run-test
50     builders:
51       - shell: |
52           git clone https://gerrit.onap.org/r/ci-management /tmp/ci-management
53           cp /tmp/ci-management/jjb/integration/*csit.sh ${WORKSPACE}
54           ${WORKSPACE}/run-csit.sh ${TESTPLAN} ${TESTOPTIONS}
55
56 - builder:
57     name: integration-run-project-test
58     builders:
59       - shell: "${WORKSPACE}/csit/run-project-csit.sh ${TESTOPTIONS}"
60
61 - builder:
62     name: integration-autorelease-fix-relativepaths
63     builders:
64       - shell: "${WORKSPACE}/autorelease/scripts/fix-relativepaths.sh"
65
66 - builder:
67     name: integration-autorelease-set-version
68     builders:
69       - shell: "${WORKSPACE}/autorelease/scripts/set-version.sh"
70
71 - builder:
72     name: integration-install-vagrant
73     builders:
74       - shell: |
75           #!/bin/bash
76           set -ex # Fail build if any setup step fails
77           sudo add-apt-repository --yes ppa:tiagohillebrandt/vagrant
78           sudo apt update
79           sudo apt --yes install libxslt-dev libxml2-dev libvirt-dev zlib1g-dev ruby-dev vagrant
80           vagrant plugin install vagrant-libvirt
81           vagrant plugin install vagrant-disksize
82           vagrant plugin install vagrant-sshfs
83           vagrant plugin install vagrant-reload
84           mkdir -p ~/.ssh
85
86 - builder:
87     name: integration-docker-compose-logs
88     builders:
89       - shell: !include-raw: shell/docker-compose-logs.sh
90
91 - publisher:
92     name: integration-robot
93     publishers:
94       - robot:
95           output-path: 'archives'
96           output-xml: '**/output.xml'
97           report-html: '**/report.html'
98           log-html: '**/log.html'
99           other-files: ''
100           unstable-threshold: '{unstable-if}'
101           pass-threshold: '{pass-if}'
102           only-critical: false
103
104 - publisher:
105     name: integration-project-robot
106     publishers:
107       - robot:
108           output-path: 'csit/archives'
109           output-xml: '**/output.xml'
110           report-html: '**/report.html'
111           log-html: '**/log.html'
112           other-files: ''
113           unstable-threshold: '{unstable-if}'
114           pass-threshold: '{pass-if}'
115           only-critical: false
116
117 - publisher:
118     name: integration-docker-compose-logs
119     publishers:
120       - postbuildscript:
121           builders:
122             - role: BOTH
123               build-on:
124                 - FAILURE
125                 - SUCCESS
126                 - UNSTABLE
127               build-steps:
128                 - integration-docker-compose-logs