This is an automated email from the ASF dual-hosted git repository.
adoroszlai pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/ratis.git
The following commit(s) were added to refs/heads/master by this push:
new 7dae4db9b RATIS-2373. Use workflow inputs in run command via
environment variable (#1329)
7dae4db9b is described below
commit 7dae4db9b5e4b3ba5af71acb5d82134c68abdf94
Author: Doroszlai, Attila <[email protected]>
AuthorDate: Tue Dec 16 20:17:51 2025 +0100
RATIS-2373. Use workflow inputs in run command via environment variable
(#1329)
---
.github/workflows/check.yaml | 8 +++++---
.github/workflows/repeat-test.yaml | 3 ++-
2 files changed, 7 insertions(+), 4 deletions(-)
diff --git a/.github/workflows/check.yaml b/.github/workflows/check.yaml
index 81651c1fa..996277d75 100644
--- a/.github/workflows/check.yaml
+++ b/.github/workflows/check.yaml
@@ -79,6 +79,7 @@ on:
env:
MAVEN_ARGS: --batch-mode --show-version
MAVEN_OPTS: -Dhttp.keepAlive=false -Dmaven.wagon.http.pool=false
-Dmaven.wagon.http.retryHandler.class=standard
-Dmaven.wagon.http.retryHandler.count=3
+ SCRIPT: ${{ inputs.script }}
WITH_COVERAGE: ${{ github.event_name == 'push' }}
jobs:
@@ -154,15 +155,16 @@ jobs:
- name: Execute tests
run: |
- dev-support/checks/${{ inputs.script }}.sh ${{ inputs.script-args }}
+ $COMMAND
env:
+ COMMAND: dev-support/checks/${{ inputs.script }}.sh ${{
inputs.script-args }}
DEVELOCITY_ACCESS_KEY: ${{ secrets.DEVELOCITY_ACCESS_KEY }}
- name: Summary of failures
if: ${{ failure() }}
run: |
- if [[ -s "target/${{ inputs.script }}/summary.txt" ]]; then
- cat target/${{ inputs.script }}/summary.txt
+ if [[ -s "target/$SCRIPT/summary.txt" ]]; then
+ cat target/$SCRIPT/summary.txt
fi
- name: Archive build results
diff --git a/.github/workflows/repeat-test.yaml
b/.github/workflows/repeat-test.yaml
index 66fec90f1..de787d929 100644
--- a/.github/workflows/repeat-test.yaml
+++ b/.github/workflows/repeat-test.yaml
@@ -47,6 +47,7 @@ env:
TEST_METHOD: ${{ github.event.inputs.test-method }}
ITERATIONS: ${{ github.event.inputs.iterations }}
FAIL_FAST: ${{ github.event.inputs.fail-fast }}
+ SPLITS: ${{ github.event.inputs.splits }}
run-name: ${{ github.event_name == 'workflow_dispatch' &&
format('{0}#{1}[{2}]-{3}x{4}', inputs.test-class, inputs.test-method,
inputs.ref, inputs.splits, inputs.iterations) || '' }}
jobs:
prepare:
@@ -59,7 +60,7 @@ jobs:
name: Generate test matrix
run: |
splits=()
- for ((i = 1; i <= ${{ github.event.inputs.splits }}; i++)); do
+ for ((i = 1; i <= $SPLITS; i++)); do
splits+=("$i")
done
printf -v x "%s," "${splits[@]}"