Skip to content

Fix call to stop containers when using parallel in JUnit Jupiter Extension #10413

Fix call to stop containers when using parallel in JUnit Jupiter Extension

Fix call to stop containers when using parallel in JUnit Jupiter Extension #10413

Workflow file for this run

name: CI
on:
pull_request:
paths-ignore:
- 'docs/**/*.css'
- 'docs/**/*.html'
- 'docs/**/*.ico'
- 'docs/**/*.md'
- 'docs/**/*.png'
- 'docs/**/*.svg'
- 'mkdocs.yml'
- 'README.md'
- 'RELEASING.md'
- '.sdkmanrc'
push:
branches: [ main ]
paths-ignore:
- 'docs/**/*.css'
- 'docs/**/*.html'
- 'docs/**/*.ico'
- 'docs/**/*.md'
- 'docs/**/*.png'
- 'docs/**/*.svg'
- 'mkdocs.yml'
- 'README.md'
- 'RELEASING.md'
- '.sdkmanrc'
concurrency:
group: "${{ github.workflow }}-${{ github.head_ref || github.sha }}"
cancel-in-progress: true
permissions:
contents: read
env:
AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }}
AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
GRADLE_ENTERPRISE_ACCESS_KEY: ${{ secrets.GRADLE_ENTERPRISE_ACCESS_KEY }}
GRADLE_ENTERPRISE_CACHE_PASSWORD: ${{ secrets.GRADLE_ENTERPRISE_CACHE_PASSWORD }}
jobs:
find_gradle_jobs:
runs-on: ubuntu-22.04
outputs:
matrix: ${{ steps.set-matrix.outputs.matrix }}
steps:
- uses: actions/checkout@v3
- uses: actions/setup-java@v3
with:
java-version: '8'
distribution: temurin
- name: Setup Gradle Build Action
uses: gradle/gradle-build-action@v2
- id: set-matrix
env:
# Since we override the tests executor,
# we should not push empty results to the cache
READ_ONLY_REMOTE_GRADLE_CACHE: true
run: |
TASKS=$(./gradlew --no-daemon --parallel -q testMatrix | jq 'del(.[] | select(. == ":azure:check"))' --compact-output)
echo $TASKS
echo "matrix={\"gradle_args\":$TASKS}" >> $GITHUB_OUTPUT
check:
needs: [find_gradle_jobs]
strategy:
fail-fast: false
matrix: ${{ fromJson(needs.find_gradle_jobs.outputs.matrix) }}
runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@v3
- uses: actions/setup-java@v3
with:
java-version: '8'
distribution: temurin
- name: Clear existing docker image cache
run: docker image prune -af
- name: Setup Gradle Build Action
uses: gradle/gradle-build-action@v2
with:
gradle-home-cache-includes: |
caches
notifications
jdks
gradle-home-cache-cleanup: true
- name: Build and test with Gradle (${{matrix.gradle_args}})
run: |
./gradlew --no-daemon --continue --scan ${{matrix.gradle_args}}