Bump cekit/actions-setup-cekit from 1.1.6 to 1.1.7 #2
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: On PR Open or Push Do Build and Test | |
on: | |
pull_request: | |
push: | |
branches: | |
- main | |
- 15.[0-9]+.x | |
- 14.0.x | |
concurrency: | |
# Only cancel jobs for PR updates | |
group: ci-${{ github.ref }} | |
cancel-in-progress: true | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Build Infinispan | |
uses: ./.github/actions/build-infinispan | |
ci-build-test-pr: | |
needs: build | |
name: Maven Build and Test | |
runs-on: ubuntu-latest | |
env: | |
MAVEN_OPTS: "-Xmx1500m -XX:+HeapDumpOnOutOfMemoryError" | |
GH_TOKEN: ${{ github.token }} | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
- name: Setup Java | |
uses: ./.github/actions/setup-java | |
- uses: graalvm/setup-graalvm@v1 | |
with: | |
java-version: 21 | |
distribution: 'graalvm' | |
github-token: ${{ secrets.GITHUB_TOKEN }} | |
- name: Extract Maven Artifacts | |
uses: ./.github/actions/extract-maven-artifacts | |
- name: Maven Test | |
run: > | |
./mvnw verify -s maven-settings.xml -V -B -e -DrerunFailingTestsCount=2 | |
-Dmaven.test.failure.ignore=true -Dansi.strip=true -Pnative | |
- name: Archive commit sha PR | |
if: > | |
(success() || failure()) && | |
github.event_name == 'pull_request' | |
run: | | |
echo -n ${{ github.event.pull_request.head.sha }} > github-sha.txt | |
- name: Archive commit sha push | |
if: > | |
(success() || failure()) && | |
github.event_name == 'push' | |
run: | | |
echo -n $GITHUB_SHA > github-sha.txt | |
- name: Archive surefire test report | |
if: (success() || failure()) | |
uses: actions/upload-artifact@v4 | |
with: | |
name: surefire-test-report | |
path: | | |
**/surefire-reports/TEST-*.xml | |
**/*.dump* | |
**/hs_err_* | |
github-sha.txt | |
!**/target/*-reports*/**/TEST-*FLAKY.xml | |
# Create artifact with branch name and surefile flaky test report | |
- name: Check flaky report existence | |
if: success() || failure() | |
id: check_flaky_report | |
uses: andstor/file-existence-action@v3 | |
with: | |
files: "**/target/*-reports*/**/TEST-*FLAKY.xml" | |
- name: Archive base_ref | |
if: (success() || failure()) && steps.check_flaky_report.outputs.files_exists == 'true' | |
env: | |
TARGET_BRANCH: ${{ github.base_ref }} | |
EVENT_NAME: ${{ github.event_name }} | |
EVENT_NUMBER: ${{ github.event.number }} | |
run: | | |
echo -n $TARGET_BRANCH > target-branch.txt | |
echo -n $EVENT_NAME > event-name.txt | |
echo -n $EVENT_NUMBER > event-number.txt | |
- name: Archive flaky test report | |
if: (success() || failure()) && steps.check_flaky_report.outputs.files_exists == 'true' | |
uses: actions/upload-artifact@v4 | |
with: | |
name: flaky-test-report | |
path: | | |
**/target/*-reports*/**/TEST-*FLAKY.xml | |
target-branch.txt | |
event-name.txt | |
event-number.txt | |
db: | |
needs: build | |
runs-on: ubuntu-latest | |
strategy: | |
fail-fast: false | |
matrix: | |
dbs: | |
- mssql | |
- oracle | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Setup Java | |
uses: ./.github/actions/setup-java | |
- name: Extract Maven Artifacts | |
uses: ./.github/actions/extract-maven-artifacts | |
- name: Infinispan Version | |
run: echo "ISPN_VERSION=$(./mvnw help:evaluate -Dexpression=project.version -q -DforceStdout)" >> $GITHUB_ENV | |
- name: Download Infinispan Server | |
uses: actions/download-artifact@v4 | |
with: | |
name: infinispan-dist | |
- name: Extract Infinispan Server | |
run: | | |
cd /tmp | |
unzip ${GITHUB_WORKSPACE}/infinispan-server-${ISPN_VERSION}.zip | |
- name: Test | |
run: | | |
./mvnw verify -s maven-settings.xml -B -e -pl server/tests --fail-at-end \ | |
-Dansi.strip=true \ | |
-DdefaultTestGroup=database \ | |
-Dorg.infinispan.test.database.types=${{ matrix.dbs }} \ | |
-Dorg.infinispan.test.server.dir=/tmp/infinispan-server-${ISPN_VERSION} |