@@ -103,35 +103,37 @@ jobs:
103
103
- name : Set up Maven
104
104
run : ./mvnw -v
105
105
106
- - name : Build code and run tests and basic checks
106
+ - name : Build code and run tests and basic checks (Standalone)
107
107
run : |
108
108
./mvnw $MAVEN_ARGS ${{ matrix.os.maven.args }} clean install \
109
109
-Pjqassistant -Pdist -Prelocation
110
+ env :
111
+ DEVELOCITY_ACCESS_KEY : " ${{ secrets.DEVELOCITY_ACCESS_KEY || '' }}"
112
+ # For jobs running on 'pull_request', upload build scan data.
113
+ # The actual publishing must be done in a separate job (see ci-report.yml).
114
+ # We don't write to the remote cache as that would be unsafe.
115
+ - name : Upload GitHub Actions artifact for the Develocity build scan
116
+ uses : actions/upload-artifact@v4
117
+ if : " ${{ github.event_name == 'pull_request' && !cancelled() }}"
118
+ with :
119
+ name : build-scan-data-standalone-${{ matrix.os.name }}
120
+ path : ~/.m2/.develocity/build-scan-data
110
121
111
- - name : Build code and run tests in container mode
122
+ - name : Run TCK tests in container mode
112
123
run : |
113
124
./mvnw $MAVEN_ARGS ${{ matrix.os.maven.args }} clean verify \
114
125
-Pjqassistant -Pskip-checks \
115
126
-am -pl :hibernate-validator-tck-runner \
116
127
-Dincontainer -Dincontainer-prepared
117
- # Workaround for https://github.com/actions/upload-artifact/issues/240
118
- - name : List build reports to upload (if build failed)
119
- if : ${{ failure() || cancelled() }}
120
- # The weird syntax is because we're setting a multiline environment variable
121
- # See https://docs.github.com/en/actions/using-workflows/workflow-commands-for-github-actions#example-of-a-multiline-string
122
- run : |
123
- {
124
- echo 'buildReportPaths<<EOF'
125
- find . -path '**/*-reports'
126
- echo EOF
127
- } >> "$GITHUB_ENV"
128
- - name : Upload build reports (if build failed)
128
+ env :
129
+ DEVELOCITY_ACCESS_KEY : " ${{ secrets.DEVELOCITY_ACCESS_KEY || '' }}"
130
+
131
+ - name : Upload GitHub Actions artifact for the Develocity build scan
129
132
uses : actions/upload-artifact@v4
130
- if : ${{ failure() || cancelled() }}
133
+ if : " ${{ github.event_name == 'pull_request' && ! cancelled() }}"
131
134
with :
132
- name : ${{ format('build-reports-{0}', matrix.os.name ) }}
133
- path : ${{ env.buildReportPaths }}
134
- retention-days : 7
135
+ name : build-scan-data-incontainer-${{ matrix.os.name }}
136
+ path : ~/.m2/.develocity/build-scan-data
135
137
136
138
- name : Omit produced artifacts from build cache
137
139
run : rm -r ~/.m2/repository/org/hibernate/validator
0 commit comments