Feat!: Update JJB version to 6x
[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: !include-raw:
38           - include-raw-integration-install-robotframework.sh
39
40 - builder:
41     name: integration-install-robotframework-py3
42     builders:
43       - shell: !include-raw-escape:
44           - include-raw-integration-install-robotframework-py3.sh
45
46 - builder:
47     name: integration-run-test
48     builders:
49       - shell: |
50           git clone https://gerrit.onap.org/r/ci-management /tmp/ci-management
51           cp /tmp/ci-management/jjb/integration/*csit.sh "$WORKSPACE"
52           "$WORKSPACE/run-csit.sh" "$TESTPLAN" "$TESTOPTIONS"
53
54 - builder:
55     name: integration-run-project-test
56     builders:
57       - shell: "$WORKSPACE/csit/run-project-csit.sh $TESTOPTIONS"
58
59 - builder:
60     name: integration-autorelease-fix-relativepaths
61     builders:
62       - shell: "${WORKSPACE}/autorelease/scripts/fix-relativepaths.sh"
63
64 - builder:
65     name: integration-autorelease-set-version
66     builders:
67       - shell: "${WORKSPACE}/autorelease/scripts/set-version.sh"
68
69 - builder:
70     name: integration-install-vagrant
71     builders:
72       - shell: |
73           #!/bin/bash
74           set -ex # Fail build if any setup step fails
75           sudo add-apt-repository --yes ppa:tiagohillebrandt/vagrant
76           sudo apt update
77           sudo apt --yes install libxslt-dev libxml2-dev libvirt-dev zlib1g-dev ruby-dev vagrant
78           vagrant plugin install vagrant-libvirt
79           vagrant plugin install vagrant-disksize
80           vagrant plugin install vagrant-sshfs
81           vagrant plugin install vagrant-reload
82           mkdir -p ~/.ssh
83
84 - builder:
85     name: integration-docker-compose-logs
86     builders:
87       - shell: !include-raw: shell/docker-compose-logs.sh
88
89 - publisher:
90     name: integration-robot
91     publishers:
92       - robot:
93           output-path: "archives"
94           output-xml: "**/output.xml"
95           report-html: "**/report.html"
96           log-html: "**/log.html"
97           other-files: ""
98           unstable-threshold: "{unstable-if}"
99           pass-threshold: "{pass-if}"
100           only-critical: false
101
102 - publisher:
103     name: integration-project-robot
104     publishers:
105       - robot:
106           output-path: "csit/archives"
107           output-xml: "**/output.xml"
108           report-html: "**/report.html"
109           log-html: "**/log.html"
110           other-files: ""
111           unstable-threshold: "{unstable-if}"
112           pass-threshold: "{pass-if}"
113           only-critical: false
114
115 - publisher:
116     name: integration-docker-compose-logs
117     publishers:
118       - postbuildscript:
119           builders:
120             - role: BOTH
121               build-on:
122                 - FAILURE
123                 - SUCCESS
124                 - UNSTABLE
125               build-steps:
126                 - integration-docker-compose-logs