[MOB-7646] update processing logic for diff merge messages #1392
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: Build and Test | |
on: | |
push: | |
branches: | |
- master | |
pull_request: | |
jobs: | |
check: | |
name: Check | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v2 | |
- name: Validate Gradle Wrapper | |
uses: gradle/wrapper-validation-action@v1 | |
- name: Configure JDK | |
uses: actions/setup-java@v1 | |
with: | |
java-version: 11 | |
- run: touch local.properties | |
- name: Checkstyle | |
run: ./gradlew :iterableapi:checkstyle :iterableapi-ui:assembleDebug | |
- name: Javadoc Check | |
run: ./gradlew :iterableapi:javadoc :iterableapi-ui:javadoc | |
unit-tests: | |
name: Unit tests | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v2 | |
- name: Validate Gradle Wrapper | |
uses: gradle/wrapper-validation-action@v1 | |
- name: Configure JDK | |
uses: actions/setup-java@v1 | |
with: | |
java-version: 11 | |
- run: touch local.properties | |
- name: Test | |
run: ./gradlew :iterableapi:jacocoTestDebugUnitTestReport :app:jacocoDebugTestReport | |
- name: Upload coverage data | |
uses: actions/upload-artifact@v2 | |
with: | |
name: unit-tests | |
path: | | |
./**/build/**/jacoco*.xml | |
./**/build/**/report.xml | |
instrumentation-tests: | |
name: Instrumentation tests | |
runs-on: macos-latest | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v2 | |
- name: Validate Gradle Wrapper | |
uses: gradle/wrapper-validation-action@v1 | |
- name: Configure JDK | |
uses: actions/setup-java@v1 | |
with: | |
java-version: 11 | |
- run: touch local.properties | |
- name: Test | |
uses: reactivecircus/android-emulator-runner@v2 | |
with: | |
api-level: 28 | |
script: ./gradlew :iterableapi:connectedCheck :app:jacocoDebugAndroidTestReport | |
- name: Upload coverage data | |
uses: actions/upload-artifact@v2 | |
with: | |
name: instrumentation-tests | |
path: | | |
./**/build/**/jacoco*.xml | |
./**/build/**/report.xml | |
report-coverage: | |
name: Report coverage | |
runs-on: ubuntu-latest | |
needs: [unit-tests, instrumentation-tests] | |
env: | |
JACOCO_SOURCE_PATH: "iterableapi/src/main/java iterableapi-ui/src/main/java" | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v2 | |
- name: Configure JDK | |
uses: actions/setup-java@v1 | |
with: | |
java-version: 11 | |
- run: curl -L https://codeclimate.com/downloads/test-reporter/test-reporter-latest-linux-amd64 > ./cc-test-reporter | |
- run: chmod +x ./cc-test-reporter | |
- run: ./cc-test-reporter before-build | |
- name: Download unit tests coverage | |
uses: actions/download-artifact@v2 | |
with: | |
name: unit-tests | |
- name: Download instrumentation tests coverage | |
uses: actions/download-artifact@v2 | |
with: | |
name: instrumentation-tests | |
- run: bash <(curl -s https://codecov.io/bash) | |
- run: ./cc-test-reporter format-coverage app/build/reports/jacoco/jacocoDebugTestReport/jacocoDebugTestReport.xml --input-type jacoco -d | |
- run: ./cc-test-reporter format-coverage iterableapi/build/reports/coverage/androidTest/debug/connected/report.xml --input-type jacoco -d | |
- run: ./cc-test-reporter format-coverage iterableapi/build/jacoco/jacoco.xml --input-type jacoco -d | |
- run: ./cc-test-reporter format-coverage app/build/reports/jacoco/jacocoDebugAndroidTestReport/jacocoDebugAndroidTestReport.xml --input-type jacoco -d | |
- run: ./cc-test-reporter upload-coverage | |
env: | |
CC_TEST_REPORTER_ID: ${{ secrets.CC_TEST_REPORTER_ID }} |