31 lines
785 B
YAML
31 lines
785 B
YAML
name: Pull request workflow
|
|
on: pull_request
|
|
|
|
permissions:
|
|
contents: write
|
|
pull-requests: write
|
|
|
|
jobs:
|
|
test:
|
|
name: Build and Test
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- uses: actions/checkout@v3
|
|
- uses: actions/setup-java@v3
|
|
with:
|
|
distribution: temurin
|
|
java-version: 17
|
|
- name: Validate Gradle Wrapper
|
|
uses: gradle/wrapper-validation-action@v1
|
|
- name: Build with Gradle
|
|
uses: gradle/gradle-build-action@v2
|
|
with:
|
|
arguments: --stacktrace build
|
|
- name: Publish JUnit Results
|
|
uses: dorny/test-reporter@v1
|
|
if: always()
|
|
with:
|
|
name: Unit Tests
|
|
path: "*/build/test-results/test/*.xml"
|
|
reporter: java-junit
|
|
fail-on-error: true
|