-
Notifications
You must be signed in to change notification settings - Fork 1.1k
79 lines (79 loc) · 2.34 KB
/
Copy pathpull_request.yml
File metadata and controls
79 lines (79 loc) · 2.34 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
name: 26.x Pull Request Build
# For pull requests: builds and test
#
# This name intentionally differs from "Pull Request Build". The default-branch
# PR Test Report workflow listens for that name and compares results against the
# master baseline, which is not maintained for 26.x.
on:
push:
branches:
- '!master'
pull_request:
branches:
- master
- 26.x
- 23.x
- 22.x
- 21.x
- 20.x
- 19.x
permissions:
contents: read
jobs:
buildAndTest:
runs-on: ubuntu-latest
strategy:
matrix:
include:
- gradle-argument: 'assemble && ./gradlew check -x test -x testng'
label: 'check'
- gradle-argument: 'testWithJava11 testngWithJava11'
label: 'java11'
- gradle-argument: 'testWithJava17 testngWithJava17'
label: 'java17'
- gradle-argument: 'testWithJava21 testngWithJava21'
label: 'java21'
- gradle-argument: 'test testng'
label: 'java25'
- gradle-argument: 'jcstress'
label: 'jcstress'
steps:
- uses: actions/checkout@v6
- uses: gradle/actions/wrapper-validation@v6
- name: Set up JDK 25
uses: actions/setup-java@v5
with:
java-version: '25'
distribution: 'corretto'
- name: build and test
run: ./gradlew ${{matrix.gradle-argument}} --info --stacktrace
javadoc:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v6
- uses: gradle/actions/wrapper-validation@v6
- name: Set up JDK 25
uses: actions/setup-java@v5
with:
java-version: '25'
distribution: 'corretto'
- name: Verify Javadoc
run: ./gradlew javadoc --info --stacktrace
allBuildAndTestSuccessful:
if: always()
needs:
- buildAndTest
- javadoc
runs-on: ubuntu-latest
steps:
- name: Verify all jobs passed
run: |
if [ "${{ needs.buildAndTest.result }}" != "success" ]; then
echo "buildAndTest failed with result: ${{ needs.buildAndTest.result }}"
exit 1
fi
if [ "${{ needs.javadoc.result }}" != "success" ]; then
echo "javadoc failed with result: ${{ needs.javadoc.result }}"
exit 1
fi
echo "All build and test jobs passed successfully."