diff --git a/.travis.yml b/.travis.yml index 1a3bdaf1..41181c18 100644 --- a/.travis.yml +++ b/.travis.yml @@ -15,4 +15,15 @@ before_script: - emulator -avd test -no-audio -no-window & - android-wait-for-emulator - adb shell input keyevent 82 - + # This should be in the `before_script` entry + # Set up Code Climate test reporter + - curl -L https://codeclimate.com/downloads/test-reporter/test-reporter-latest-linux-amd64 > ./cc-test-reporter + - chmod +x ./cc-test-reporter + - ./cc-test-reporter before-build +script: + - ./gradlew build connectedCheck jacocoTestReport +after_script: + # Report test coverage to Code Climate + - export JACOCO_SOURCE_PATH=app/src/main/java/ + - ./cc-test-reporter format-coverage ./app/build/reports/coverage/debug/report.xml --input-type jacoco + - ./cc-test-reporter upload-coverage