This repository has been archived by the owner on Jan 12, 2023. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 1
/
run-integration-tests.groovy
127 lines (120 loc) · 4.1 KB
/
run-integration-tests.groovy
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
/*****************************************************************************
* *
* Copyright FUJITSU LIMITED 2020 *
* *
* Creation Date: 16-07-2020 *
* *
****************************************************************************/
/**
How to use:
1. Create a job of type Pipeline
2. As the pipeline script paste this script
3. Create the following parameters (adjust defaults as you wish):
Required environment variables:
===
Name: NODE_NAME
Type: Option list
Default: -
Description: Nodes used to run the pipeline.
===
Name: DOCKER_TAG
Type: String
Default: latest
Description: Docker tag name for created images
===
Name: DOCKER_ORGANIZATION
Type: String
Default: oscmdocker
Description: Organization name for the final Docker image. Example: <DOCKER_REGISTRY>/<DOCKER_ORGANIZATION>/oscm-core:<DOCKER_TAG>
===
Name: REPO_TAG_OSCM
Type: String
Default: master
Description: Branch or tag in the oscm git repository: https://github.com/servicecatalog/oscm
===
Name: REPO_TAG_DOCKERBUILD
Type: String
Default: master
Description: Branch or tag in the oscm-dockerbuild git repository: https://github.com/servicecatalog/oscm-dockerbuild
===
Name: REPO_TAG_OSCM_APP
Type: String
Default: master
Description: Branch or tag in the oscm-app git repository: https://github.com/servicecatalog/oscm-app
===
Name: REPO_TAG_APP_SHELL
Type: String
Default: master
Description: Branch or tag in the oscm-app-shell git repository: https://github.com/servicecatalog/oscm-app-shell
===
Name: REPO_TAG_APPROVAL
Type: String
Default: master
Description: Branch or tag in the oscm-approval git repository: https://github.com/servicecatalog/oscm-approval
===
Name: REPO_TAG_IDENTITY
Type: String
Default: master
Description: Branch or tag in the oscm-identity git repository: https://github.com/servicecatalog/oscm-identity
===
Name: REPO_TAG_REST_API
Type: String
Default: master
Description: Branch or tag in the oscm-identity git repository: https://github.com/servicecatalog/oscm-rest-api
===
Name: REPO_TAG_DOCUMENTATION
Type: String
Default: master
Description: Branch or tag in the documentation git repository" https://github.com/servicecatalog/documentation
===
Name: TRUSTED_CERTS_PATH
Type: String
Default: /opt/trusted_certs
Description: Path to the directory with certificates that will be imported as trusted by oscm
===
Name: SAMPLE_DATA
Type: boolean
Default: false
Description: Load sample data?
===
Name: TOMEE_DEBUG
Type: boolean
Default: false
Description: Value ignored when glassfish chosen.
===
Name: AUTH_MODE
Type: Option list (INTERNAL, OIDC)
Default: INTERNAL
Description: Auth mode used to communicate with OSCM web services.
===
Name: COMPLETE_CLEANUP
Default: enabled
Description: Delete the database and whole workspace
===
Name: TECH_SERVICE_PATH
Type: String
Default: /build/oscm-ui-tests/src/test/resources/TechnicalService.xml
Description: Localization of Technical Service definition stored in .xml file
===
Name: WEBTEST_PROPERTIES_LOCALIZATION
Type: String
Default: $WORKSPACE/oscm-ui-tests/src/test/resources/webtest.properties
Description: Localization of webtest.properties file from oscm-ui-tests oscm module
===
**/
node("${NODE_NAME}") {
// Pull and start
def clean = evaluate readTrusted('shared/cleanup.groovy')
def defVariables = evaluate readTrusted('shared/proxyvariables.groovy')
def pull = evaluate readTrusted('shared/pull.groovy')
def checkoutTests = evaluate readTrusted('shared/checkout-tests.groovy')
def start = evaluate readTrusted('shared/start.groovy')
// Run integration tests
def tests = evaluate readTrusted('tests/portal-integration-tests.groovy')
clean.execute()
defVariables.execute()
pull.execute()
checkoutTests.execute()
start.execute('localhost', true)
tests.execute()
}