Merge pull request #120 from snyk/chore/resolve-ecosystem-based-on-pa… #355
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: Unit Tests | |
on: | |
push: | |
jobs: | |
unit_tests: | |
name: unit tests (Java ${{ matrix.java }}) | |
runs-on: ubuntu-latest | |
strategy: | |
matrix: | |
java: [17, 20] | |
steps: | |
- name: Fetch sources | |
uses: actions/checkout@v2 | |
- name: Setup JDK ${{ matrix.java }} | |
uses: actions/setup-java@v1 | |
with: | |
java-version: ${{ matrix.java }} | |
- name: Cache local Maven repository | |
uses: actions/cache@v2 | |
with: | |
path: | | |
~/.m2/repository | |
~/.m2/wrapper | |
key: ${{ runner.os }}-m2-${{ hashFiles('**/pom.xml') }} | |
restore-keys: ${{ runner.os }}-m2 | |
- name: Run unit tests | |
run: ./mvnw clean verify --show-version --batch-mode --errors --no-transfer-progress | |
env: | |
TEST_SNYK_TOKEN: ${{ secrets.TEST_SNYK_TOKEN }} | |
TEST_SNYK_ORG: ${{ secrets.TEST_SNYK_ORG }} |