From 6ecc5fa26c4aac0f62cba6d4f23a43e702dbb9db Mon Sep 17 00:00:00 2001 From: Sebastian Hartte Date: Tue, 19 Dec 2023 18:57:59 +0100 Subject: [PATCH] Workflows --- .github/workflows/main.yml | 43 ++++++++++++++++++++++++++++++++++++++ 1 file changed, 43 insertions(+) create mode 100644 .github/workflows/main.yml diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml new file mode 100644 index 0000000..b5cd3cc --- /dev/null +++ b/.github/workflows/main.yml @@ -0,0 +1,43 @@ +name: 'Build Main' + +on: + push: + branches: + - main + +jobs: + build: + name: Build and Test + runs-on: ubuntu-latest + steps: + - name: Checkout repository + uses: actions/checkout@v4 + with: + fetch-depth: 1000 + fetch-tags: true + + - name: Setup JDK + uses: actions/setup-java@v3 + with: + java-version: '17' + distribution: 'microsoft' + + - name: Setup Gradle + uses: gradle/gradle-build-action@v2 + + - name: Build + run: ./gradlew --info -s -x check build + + - name: Test + run: ./gradlew --info -s check + + # Always upload test results + - name: Merge Test Reports + if: success() || failure() + run: npx junit-report-merger junit.xml "**/TEST-*.xml" + + - uses: actions/upload-artifact@v3 + if: success() || failure() + with: + name: test-results + path: junit.xml