Merge pull request #182 from apple/dependabot/github_actions/actions/… #298
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: PR Builder | |
| permissions: | |
| contents: read | |
| on: | |
| pull_request: | |
| branches: [ main ] | |
| push: | |
| branches: [ main ] | |
| jobs: | |
| build: | |
| name: JDK ${{ matrix.java }} ${{ matrix.os }} | |
| runs-on: ${{ matrix.os }} | |
| strategy: | |
| matrix: | |
| java: [ 17, 21, 25 ] | |
| os: [ ubuntu-latest ] | |
| steps: | |
| - name: Checkout Code | |
| uses: actions/checkout@v4 | |
| - name: Set up JDK ${{ matrix.java }} | |
| uses: actions/setup-java@v5 | |
| with: | |
| java-version: ${{ matrix.java }} | |
| distribution: 'corretto' | |
| cache: 'gradle' | |
| - name: Print JDK Version | |
| run: java -version | |
| - name: Make gradlew Executable | |
| run: chmod +x gradlew | |
| - name: Build and Test | |
| env: | |
| JAVA_TOOL_OPTIONS: -Dfile.encoding=UTF-8 | |
| run: sudo -E env "PATH=$PATH" bash -c "ulimit -l 65536 && ulimit -a && ./gradlew --no-daemon --parallel clean test" | |
| - name: Upload Test Results | |
| if: always() | |
| uses: actions/upload-artifact@v5 | |
| with: | |
| name: test-results-${{ matrix.os }}-${{ matrix.java }} | |
| path: '**/build/test-results/test/TEST-*.xml' |