File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1+ name : Gradle CI
2+
3+ on :
4+ push :
5+ branches : [ "main" ]
6+ pull_request :
7+ branches : [ "main" ]
8+
9+ jobs :
10+ build :
11+ runs-on : ubuntu-latest
12+
13+ steps :
14+ - name : Checkout repository
15+ uses : actions/checkout@v4
16+
17+ - name : Set up JDK 17
18+ uses : actions/setup-java@v4
19+ with :
20+ distribution : temurin
21+ java-version : 17
22+
23+ - name : Grant execute permission for gradlew
24+ run : chmod +x gradlew
25+
26+ - name : Run tests
27+ run : ./gradlew test --stacktrace
28+
29+ # Upload the test reports as artifacts
30+ - name : Upload test reports
31+ uses : actions/upload-artifact@v4
32+ with :
33+ name : junit-report
34+ path : build/test-results/test
35+
36+ # Publish test results so they appear in GitHub Actions UI
37+ - name : Publish Test Results
38+ uses : mikepenz/action-junit-report@v4
39+ if : always() # always run even if tests fail
40+ with :
41+ report_paths : ' **/build/test-results/test/TEST-*.xml'
You can’t perform that action at this time.
0 commit comments