Update build-and-test.yml #442
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: Build and Test | |
on: | |
push: | |
branches: [master] | |
pull_request: | |
branches: [master] | |
jobs: | |
build-and-test-sdk: | |
name: Build and Test SDK Project | |
runs-on: ubuntu-latest | |
steps: | |
- name: Clone Repository | |
uses: actions/checkout@v3 | |
- name: Set up JDK 11 | |
uses: actions/setup-java@v2 | |
with: | |
java-version: 11 | |
distribution: 'zulu' | |
- name: Build | |
run: ./gradlew afterpay:build | |
- name: Lint | |
run: ./gradlew afterpay:lint afterpay:spotlessCheck | |
- name: Unit Tests | |
run: ./gradlew afterpay:testDebugUnitTest | |
build-example: | |
name: Build Sample Project | |
runs-on: ubuntu-latest | |
steps: | |
- name: Clone Repository | |
uses: actions/checkout@v3 | |
- name: Set up JDK 11 | |
uses: actions/setup-java@v2 | |
with: | |
java-version: 11 | |
distribution: 'zulu' | |
- name: Build | |
run: ./gradlew sample:buildDebug | |
- name: Lint | |
run: ./gradlew sample:lintDebug sample:spotlessCheck |