Skip to content

Commit 1e941e9

Browse files
Upload tests result artifact on Windows (helidon-io#1099)
* Upload tests result artifacts on Windows * Rename MAVEN_ARGS to MVN_ARGS to fix windows issues with Maven 3.9.9 * Fix build-cache-maven-extension it/test3 * Fix copyright --------- Co-authored-by: Romain Grecourt <[email protected]> (cherry picked from commit 7127472)
1 parent bc3257f commit 1e941e9

File tree

7 files changed

+30
-31
lines changed

7 files changed

+30
-31
lines changed

.github/actions/common/action.yml

Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
#
2-
# Copyright (c) 2023, 2024 Oracle and/or its affiliates.
2+
# Copyright (c) 2023, 2025 Oracle and/or its affiliates.
33
#
44
# Licensed under the Apache License, Version 2.0 (the "License");
55
# you may not use this file except in compliance with the License.
@@ -57,7 +57,7 @@ inputs:
5757
required: false
5858
default: ''
5959
test-artifact-name:
60-
description: Name of the test artifact to create (excluded on windows), if non empty tests are archived
60+
description: Name of the test artifact to create, if non empty tests are archived
6161
required: false
6262
default: ''
6363
free-space:
@@ -150,15 +150,14 @@ runs:
150150
GPG_PASSPHRASE: ${{ inputs.GPG_PASSPHRASE }}
151151
GPG_PRIVATE_KEY: ${{ inputs.GPG_PRIVATE_KEY }}
152152
MAVEN_SETTINGS: ${{ inputs.MAVEN_SETTINGS }}
153-
MAVEN_ARGS: |
154-
${{ env.MAVEN_ARGS }}
153+
MVN_ARGS: |
154+
${{ env.MVN_ARGS }}
155155
-Dmaven.repo.local=${{ github.workspace }}/.m2/repository
156156
-Dcache.record=${{ inputs.build-cache == 'read-write' }}
157157
run: ${{ inputs.run }}
158158
shell: bash
159159
- name: Archive test results
160-
# https://github.com/actions/upload-artifact/issues/240
161-
if: ${{ inputs.test-artifact-name != '' && runner.os != 'Windows' && always() }}
160+
if: ${{ inputs.test-artifact-name != '' && always() }}
162161
uses: actions/upload-artifact@v4
163162
with:
164163
if-no-files-found: 'ignore'

.github/workflows/release.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
#
2-
# Copyright (c) 2023, 2024 Oracle and/or its affiliates.
2+
# Copyright (c) 2023, 2025 Oracle and/or its affiliates.
33
#
44
# Licensed under the Apache License, Version 2.0 (the "License");
55
# you may not use this file except in compliance with the License.
@@ -23,7 +23,7 @@ on:
2323
env:
2424
JAVA_VERSION: 17
2525
JAVA_DISTRO: oracle
26-
MAVEN_ARGS: |
26+
MVN_ARGS: |
2727
-B -e
2828
-Dmaven.wagon.httpconnectionManager.ttlSeconds=60
2929
-Dmaven.wagon.http.retryHandler.count=3

.github/workflows/validate.yml

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
#
2-
# Copyright (c) 2023, 2024 Oracle and/or its affiliates.
2+
# Copyright (c) 2023, 2025 Oracle and/or its affiliates.
33
#
44
# Licensed under the Apache License, Version 2.0 (the "License");
55
# you may not use this file except in compliance with the License.
@@ -30,7 +30,7 @@ env:
3030
JAVA_VERSION: 17
3131
JAVA_DISTRO: oracle
3232
GRAALVM_VERSION: 21.3.3.1
33-
MAVEN_ARGS: |
33+
MVN_ARGS: |
3434
-B -fae -e
3535
-Dmaven.wagon.httpconnectionManager.ttlSeconds=60
3636
-Dmaven.wagon.http.retryHandler.count=3
@@ -90,8 +90,8 @@ jobs:
9090
artifact-path: cli/impl/target/helidon-cli.zip
9191
run: |
9292
mvn --version
93-
mvn ${MAVEN_ARGS} build-cache:go-offline
94-
mvn ${MAVEN_ARGS} -T8 \
93+
mvn ${MVN_ARGS} build-cache:go-offline
94+
mvn ${MVN_ARGS} -T8 \
9595
-Dorg.slf4j.simpleLogger.showThreadName=true \
9696
-DskipTests \
9797
-P tests \
@@ -115,9 +115,9 @@ jobs:
115115
- uses: ./.github/actions/common
116116
with:
117117
build-cache: read-only
118-
test-artifact-name: tests-${{ matrix.moduleSet }}
118+
test-artifact-name: tests-${{ matrix.moduleSet }}-${{ matrix.os }}
119119
run: |
120-
mvn ${MAVEN_ARGS} \
120+
mvn ${MVN_ARGS} \
121121
-DreactorRule=tests \
122122
-DmoduleSet=${{ matrix.moduleSet }} \
123123
-Dsurefire.reportNameSuffix=${{ matrix.platform }} \
@@ -134,7 +134,7 @@ jobs:
134134
with:
135135
build-cache: read-only
136136
run: |
137-
mvn ${MAVEN_ARGS} -T 8 \
137+
mvn ${MVN_ARGS} -T 8 \
138138
-DskipTests \
139139
-Pspotbugs,build-cache \
140140
verify
@@ -150,7 +150,7 @@ jobs:
150150
with:
151151
build-cache: read-only
152152
run: |
153-
mvn ${MAVEN_ARGS} -T 8 \
153+
mvn ${MVN_ARGS} -T 8 \
154154
-DskipTests \
155155
-Pjavadoc,build-cache \
156156
package
@@ -166,7 +166,7 @@ jobs:
166166
with:
167167
build-cache: read-write
168168
run: |
169-
mvn ${MAVEN_ARGS} \
169+
mvn ${MVN_ARGS} \
170170
-pl ide-support/vscode-extension \
171171
-DskipTests \
172172
-P vscode \
@@ -196,15 +196,15 @@ jobs:
196196
artifact-path: cli/impl/target/helidon-cli-${{ matrix.platform }}${{ matrix.file-ext }}
197197
run: |
198198
# build the executable
199-
mvn ${MAVEN_ARGS} \
199+
mvn ${MVN_ARGS} \
200200
-pl cli/impl \
201201
-DskipTests \
202202
-Pnative-image,!toolchain \
203203
-Dnative.image.name=helidon-cli-${{ matrix.platform }} \
204204
package
205205
206206
# smoke test
207-
mvn ${MAVEN_ARGS} \
207+
mvn ${MVN_ARGS} \
208208
-pl cli/tests/functional \
209209
-Pnative-image \
210210
-Dnative.image.name=helidon-cli-${{ matrix.platform }} \

etc/scripts/checkstyle.sh

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
#!/bin/bash
22
#
3-
# Copyright (c) 2018, 2023 Oracle and/or its affiliates.
3+
# Copyright (c) 2018, 2025 Oracle and/or its affiliates.
44
#
55
# Licensed under the Apache License, Version 2.0 (the "License");
66
# you may not use this file except in compliance with the License.
@@ -53,7 +53,7 @@ die(){ echo "${1}" ; exit 1 ;}
5353
rm -f "${WS_DIR}"/target/checkstyle-*
5454

5555
# shellcheck disable=SC2086
56-
mvn ${MAVEN_ARGS} checkstyle:checkstyle-aggregate \
56+
mvn ${MVN_ARGS} checkstyle:checkstyle-aggregate \
5757
-f "${WS_DIR}"/pom.xml \
5858
-Dcheckstyle.output.format="plain" \
5959
-Dcheckstyle.output.file="${RESULT_FILE}" \

etc/scripts/copyright.sh

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
#!/bin/bash
22
#
3-
# Copyright (c) 2018, 2023 Oracle and/or its affiliates.
3+
# Copyright (c) 2018, 2025 Oracle and/or its affiliates.
44
#
55
# Licensed under the Apache License, Version 2.0 (the "License");
66
# you may not use this file except in compliance with the License.
@@ -49,7 +49,7 @@ readonly RESULT_FILE
4949
die() { echo "${1}" ; exit 1 ;}
5050

5151
# shellcheck disable=SC2086
52-
mvn ${MAVEN_ARGS} \
52+
mvn ${MVN_ARGS} \
5353
-f ${WS_DIR}/pom.xml \
5454
-Dhelidon.enforcer.output.file="${RESULT_FILE}" \
5555
-Dhelidon.enforcer.rules=copyright \

etc/scripts/release.sh

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
#!/bin/bash
22
#
3-
# Copyright (c) 2018, 2023 Oracle and/or its affiliates.
3+
# Copyright (c) 2018, 2025 Oracle and/or its affiliates.
44
#
55
# Licensed under the Apache License, Version 2.0 (the "License");
66
# you may not use this file except in compliance with the License.
@@ -109,7 +109,7 @@ exec 6>&1 1>&2
109109

110110
current_version() {
111111
# shellcheck disable=SC2086
112-
mvn ${MAVEN_ARGS} -q \
112+
mvn ${MVN_ARGS} -q \
113113
-f "${WS_DIR}"/pom.xml \
114114
-Dexec.executable="echo" \
115115
-Dexec.args="\${project.version}" \
@@ -133,7 +133,7 @@ update_version(){
133133
fi
134134

135135
# shellcheck disable=SC2086
136-
mvn ${MAVEN_ARGS} "${ARGS[@]}" \
136+
mvn ${MVN_ARGS} "${ARGS[@]}" \
137137
-f "${WS_DIR}"/pom.xml versions:set versions:set-property \
138138
-DgenerateBackupPoms="false" \
139139
-DnewVersion="${version}" \
@@ -176,7 +176,7 @@ release_build(){
176176
if [ -n "${MAVEN_SETTINGS}" ] ; then
177177
tmpfile=$(mktemp XXXXXXsettings.xml)
178178
echo "${MAVEN_SETTINGS}" > "${tmpfile}"
179-
MAVEN_ARGS="${MAVEN_ARGS} -s ${tmpfile}"
179+
MVN_ARGS="${MVN_ARGS} -s ${tmpfile}"
180180
fi
181181
if [ -n "${GPG_PRIVATE_KEY}" ] ; then
182182
tmpfile=$(mktemp XXXXXX.key)
@@ -193,7 +193,7 @@ release_build(){
193193

194194
# Perform local deployment
195195
# shellcheck disable=SC2086
196-
mvn ${MAVEN_ARGS} "${ARGS[@]}" \
196+
mvn ${MVN_ARGS} "${ARGS[@]}" \
197197
deploy \
198198
-Prelease \
199199
-DskipTests \
@@ -202,7 +202,7 @@ release_build(){
202202
# Upload all artifacts to nexus
203203
version=$(release_version)
204204
# shellcheck disable=SC2086
205-
mvn ${MAVEN_ARGS} -N nexus-staging:deploy-staged \
205+
mvn ${MVN_ARGS} -N nexus-staging:deploy-staged \
206206
-DstagingDescription="Helidon Build Tools v${version}"
207207
}
208208

maven-plugins/build-cache-maven-extension/src/it/projects/test3/invoker.properties

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
#
2-
# Copyright (c) 2024 Oracle and/or its affiliates.
2+
# Copyright (c) 2024, 2025 Oracle and/or its affiliates.
33
#
44
# Licensed under the Apache License, Version 2.0 (the "License");
55
# you may not use this file except in compliance with the License.
@@ -24,4 +24,4 @@ invoker.goals.2 = package -DskipTests -Pjavadoc
2424

2525
invoker.name.3 = Cached build #2
2626
invoker.description.3 = Tests resumed deploy
27-
invoker.goals.3 = deploy -DaltDeploymentRepository=":::file://${maven.multiModuleProjectDirectory}/staging"
27+
invoker.goals.3 = deploy -DaltDeploymentRepository="local::file://${maven.multiModuleProjectDirectory}/staging"

0 commit comments

Comments
 (0)