Add compatibility with latest protobuf #32
Workflow file for this run
This file contains 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 Build" | |
on: | |
pull_request: | |
branches: | |
- main | |
jobs: | |
build: | |
name: Build | |
runs-on: ${{ matrix.os }} | |
strategy: | |
fail-fast: false | |
matrix: | |
os: | |
- macos-latest | |
- ubuntu-latest | |
- windows-latest | |
test-java-version: | |
- 8 | |
- 11 | |
- 17 | |
- 21 | |
include: | |
- os: ubuntu-latest | |
test-java-version: 21 | |
protobuf-version: 3.18.0 | |
- os: ubuntu-latest | |
test-java-version: 21 | |
coverage: true | |
steps: | |
- uses: actions/checkout@v2 | |
with: | |
fetch-depth: 0 | |
- id: setup-java-8 | |
name: Setup Java 8 for tests | |
uses: actions/setup-java@v2 | |
with: | |
distribution: temurin | |
java-version: 8 | |
java-package: jre | |
- id: setup-java-11 | |
name: Setup Java 11 for tests | |
uses: actions/setup-java@v2 | |
with: | |
distribution: temurin | |
java-version: 11 | |
- id: setup-java-21 | |
name: Setup Java 21 | |
uses: actions/setup-java@v2 | |
with: | |
distribution: temurin | |
java-version: 21 | |
- id: setup-java-17 | |
name: Setup Java 17 | |
uses: actions/setup-java@v2 | |
with: | |
distribution: temurin | |
java-version: 17 | |
- uses: gradle/actions/setup-gradle@v4 | |
- name: Run Tests | |
run: | | |
./gradlew build ${{ matrix.coverage && 'jacocoTestReport' || '' }} -PtestJavaVersion=${{ matrix.test-java-version }} -Porg.gradle.java.installations.paths=${{ steps.setup-java-8.outputs.path }},${{ steps.setup-java-11.outputs.path }},${{ steps.setup-java-17.outputs.path }},${{ steps.setup-java-21.outputs.path }} | |
env: | |
PROTOBUF_VERSION: ${{ matrix.protobuf-version || null }} | |
- uses: codecov/codecov-action@v2.1.0 | |
if: ${{ matrix.coverage }} |