Skip to content

Commit

Permalink
cicd: update maven test workflow
Browse files Browse the repository at this point in the history
  • Loading branch information
nicoprow committed May 29, 2024
1 parent 12ef180 commit 0d20f5e
Showing 1 changed file with 8 additions and 29 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -17,48 +17,27 @@
# SPDX-License-Identifier: Apache-2.0
################################################################################

name: Maven Test Execution
name: Perform Maven Tests
on:
pull_request:
types: [opened, reopened, synchronize]
branches:
- main
- release/**
workflow_call:
workflow_dispatch:

jobs:
analyze:
runs-on: ubuntu-latest
env:
DOCKER_BUILDKIT: 1
permissions:
actions: read
contents: read
steps:
- name: Checkout
uses: actions/checkout@v4
with:
fetch-depth: 0

- name: Set up QEMU
uses: docker/setup-qemu-action@v3

- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3

- name: Set up JDK 21
uses: actions/setup-java@v4
with:
java-version: '21'
distribution: 'adopt'

#Use Maven package cache
- name: Cache Maven packages
uses: actions/cache@v4
with:
path: ~/.m2
key: ${{ runner.os }}-m2-${{ hashFiles('**/pom.xml') }}
restore-keys: ${{ runner.os }}-m2
distribution: 'temurin'

#Verify with tests
- name: Verify
run: ./mvnw -B verify
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- name: Maven Verify
run: mvn -B verify

0 comments on commit 0d20f5e

Please sign in to comment.