Ci: Add job to run test on push and mr

This commit is contained in:
Lars Simon Winzer
2026-03-14 10:06:12 +01:00
parent 66f840b269
commit 6e35c599da
+21
View File
@@ -2,6 +2,7 @@ stages:
- lint
- report
- build
- test
# Reusable definitions
.gradle-cache: &gradle-cache
@@ -87,3 +88,23 @@ compile-check:
allow_failure: false
- if: '$CI_COMMIT_BRANCH'
allow_failure: false
test:
<<: *gradle-cache
stage: test
image: gradle:9.3.1-jdk25
script:
- gradle test
artifacts:
when: always
reports:
junit: build/test-results/test/*.xml
paths:
- build/reports/tests/test/
expose_as: 'Test Report'
expire_in: 1 week
rules:
- if: '$CI_PIPELINE_SOURCE == "merge_request_event"'
allow_failure: false
- if: '$CI_COMMIT_BRANCH'
allow_failure: true