@@ -100,7 +100,75 @@ jobs:
100
100
BUILD_ZOO_HANDLER_spring_cloud_dataflow_buildname : ${{ env.BUILD_ZOO_HANDLER_spring_cloud_dataflow_buildname }}
101
101
BUILD_ZOO_HANDLER_spring_cloud_dataflow_buildnumber : ${{ env.BUILD_ZOO_HANDLER_spring_cloud_dataflow_buildnumber }}
102
102
BUILD_ZOO_HANDLER_spring_cloud_skipper_version : ${{ env.BUILD_ZOO_HANDLER_spring_cloud_skipper_version }}
103
-
103
+ database-tests :
104
+ if : github.repository_owner == 'spring-cloud'
105
+ runs-on : ubuntu-latest
106
+ strategy :
107
+ matrix :
108
+ db : [ 'ORACLE', 'DB2' ]
109
+ steps :
110
+ - uses : actions/checkout@v4
111
+ - uses : actions/cache@v3
112
+ with :
113
+ path : ~/.m2/repository
114
+ key : ${{ runner.os }}-m2-${{ hashFiles('**/pom.xml') }}
115
+ restore-keys : |
116
+ ${{ runner.os }}-m2-${{ matrix.db }}
117
+ - uses : actions/setup-java@v3
118
+ with :
119
+ java-version : ' 8'
120
+ distribution : ' liberica'
121
+ - uses : jvalkeal/setup-maven@v1
122
+ with :
123
+ maven-version : 3.8.8
124
+ maven-mirror : ' https://dlcdn.apache.org/maven/maven-3/'
125
+ - uses : jfrog/setup-jfrog-cli@v1
126
+ with :
127
+ version : 1.46.4
128
+ env :
129
+ JF_ARTIFACTORY_SPRING : ${{ secrets.JF_ARTIFACTORY_SPRING }}
130
+ - name : Login dockerhub
131
+ uses : docker/login-action@v3
132
+ with :
133
+ username : ${{ secrets.DOCKERHUB_USERNAME }}
134
+ password : ${{ secrets.DOCKERHUB_TOKEN }}
135
+ - name : Configure JFrog Cli
136
+ run : |
137
+ jfrog rt mvnc \
138
+ --server-id-resolve=repo.spring.io \
139
+ --server-id-deploy=repo.spring.io \
140
+ --repo-resolve-releases=libs-milestone \
141
+ --repo-resolve-snapshots=libs-snapshot \
142
+ --repo-deploy-releases=libs-release-local \
143
+ --repo-deploy-snapshots=libs-snapshot-local
144
+ - uses : ./.github/actions/install-xmlutils
145
+ - name : Test
146
+ shell : bash
147
+ timeout-minutes : 75
148
+ run : |
149
+ jfrog rt mvn clean install -s .settings.xml -DskipTests -am -pl :spring-cloud-dataflow-server,:spring-cloud-skipper-server
150
+ export ENABLE_${{ matrix.db }}=true
151
+ jfrog rt mvn test -s .settings.xml -pl :spring-cloud-dataflow-server,:spring-cloud-skipper-server -Dgroups=${{ matrix.db }}
152
+ - name : Test Report
153
+ uses : dorny/test-reporter@v1
154
+ if : ${{ success() || failure() }}
155
+ with :
156
+ name : Unit Tests
157
+ path : ' **/surefire-reports/*.xml'
158
+ reporter : java-junit
159
+ list-tests : failed
160
+ - name : Capture Test Results
161
+ if : ${{ always() }}
162
+ uses : actions/upload-artifact@v3
163
+ with :
164
+ name : test-results
165
+ path : ' **/target/surefire-reports/**/*.*'
166
+ retention-days : 7
167
+ if-no-files-found : ignore
168
+ # clean m2 cache
169
+ - name : Clean cache
170
+ run : |
171
+ find ~/.m2/repository -type d -name '*SNAPSHOT' | xargs rm -fr
104
172
images :
105
173
name : Build and Publish Images
106
174
needs : [ build ]
@@ -113,7 +181,7 @@ jobs:
113
181
GCR_JSON_KEY : ${{ secrets.GCR_JSON_KEY }}
114
182
115
183
wrap :
116
- needs : [ build, images ]
184
+ needs : [ build, images, database-tests ]
117
185
runs-on : ubuntu-latest
118
186
steps :
119
187
- name : Save env
0 commit comments