-
Notifications
You must be signed in to change notification settings - Fork 38
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
issue132, issue135, and issue136 - Move to TestLab and CircleCI, add …
…tests for sample, and various refactors
- Loading branch information
1 parent
a0c589d
commit cf7f0f5
Showing
311 changed files
with
17,086 additions
and
2,192 deletions.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,84 @@ | ||
version: 2.1 | ||
|
||
orbs: | ||
codecov: codecov/codecov@1.0.5 | ||
|
||
jobs: | ||
ci_checks: | ||
working_directory: ~/code | ||
docker: | ||
- image: circleci/android:api-28-alpha | ||
environment: | ||
JVM_OPTS: -Xmx3200m | ||
steps: | ||
- checkout | ||
- restore_cache: | ||
key: jars-{{ checksum "build.gradle" }}-{{ checksum "wisefy/build.gradle" }}-{{ checksum "wisefysample/build.gradle" }} | ||
- run: | ||
name: Chmod permissions | ||
command: sudo chmod +x ./gradlew | ||
- run: | ||
name: Download dependencies | ||
command: ./gradlew androidDependencies | ||
- run: | ||
name: Clean build | ||
command: ./gradlew clean assembleDebug wisefy:assembleDebugAndroidTest wisefysample:assembleDebugAndroidTest --stacktrace | ||
- run: | ||
name: Static code analysis | ||
command: ./gradlew staticAnalysisSanityCheck | ||
- run: | ||
name: Unit tests | ||
command: ./gradlew :wisefy:jacocoDebugUnitTest :wisefysample:jacocoDebugUnitTest --stacktrace | ||
- run: | ||
name: Store Service Account | ||
command: echo $GCLOUD_SERVICE_KEY > ${HOME}/gcloud-service-key.json | ||
- run: | ||
name: Firebase Testing | ||
command: | | ||
sudo pip install -U crcmod | ||
sudo gcloud auth activate-service-account --key-file=${HOME}/gcloud-service-key.json | ||
sudo gcloud --quiet config set project ${GOOGLE_PROJECT_ID} | ||
sudo gcloud firebase test android run \ | ||
--type instrumentation \ | ||
--app wisefysample/build/outputs/apk/debug/wisefysample-debug.apk \ | ||
--test wisefy/build/outputs/apk/androidTest/debug/wisefy-debug-androidTest.apk \ | ||
--device model=Pixel2,version=28,locale=en,orientation=portrait \ | ||
--device model=Nexus6,version=23,locale=en,orientation=portrait \ | ||
--device model=Nexus5,version=19,locale=en,orientation=portrait \ | ||
--environment-variables coverage=true,coverageFile="/sdcard/coverage.ec" \ | ||
--directories-to-pull=/sdcard \ | ||
--results-dir=${CIRCLE_BRANCH}_${CIRCLE_BUILD_NUM} | ||
sudo gsutil -m cp -r -U gs://${GCLOUD_BUCKET_LOCATION}/${CIRCLE_BRANCH}_${CIRCLE_BUILD_NUM}/Nexus5-19-en-portrait/artifacts/coverage.ec wisefy/build/outputs/code-coverage/connected/wisefy-Nexus5-sdk19-coverage.ec | ||
sudo gsutil -m cp -r -U gs://${GCLOUD_BUCKET_LOCATION}/${CIRCLE_BRANCH}_${CIRCLE_BUILD_NUM}/Nexus6-23-en-portrait/artifacts/coverage.ec wisefy/build/outputs/code-coverage/connected/wisefy-Nexus6-sdk23-coverage.ec | ||
sudo gsutil -m cp -r -U gs://${GCLOUD_BUCKET_LOCATION}/${CIRCLE_BRANCH}_${CIRCLE_BUILD_NUM}/Pixel2-28-en-portrait/artifacts/coverage.ec wisefy/build/outputs/code-coverage/connected/wisefy-Pixel2-sdk28-coverage.ec | ||
sudo gcloud firebase test android run \ | ||
--type instrumentation \ | ||
--app wisefysample/build/outputs/apk/debug/wisefysample-debug.apk \ | ||
--test wisefysample/build/outputs/apk/androidTest/debug/wisefysample-debug-androidTest.apk \ | ||
--device model=Pixel2,version=28,locale=en,orientation=portrait \ | ||
--environment-variables coverage=true,coverageFile="/sdcard/coverage.ec" \ | ||
--directories-to-pull=/sdcard \ | ||
--results-dir=${CIRCLE_BRANCH}_${CIRCLE_BUILD_NUM} | ||
sudo gsutil -m cp -r -U gs://${GCLOUD_BUCKET_LOCATION}/${CIRCLE_BRANCH}_${CIRCLE_BUILD_NUM}/Pixel2-28-en-portrait/artifacts/coverage.ec wisefysample/build/outputs/code-coverage/connected/wisefysample-coverage.ec | ||
sudo gsutil rm -r gs://${GCLOUD_BUCKET_LOCATION}/${CIRCLE_BRANCH}_${CIRCLE_BUILD_NUM} | ||
- run: | ||
name: Generate coverage report | ||
command: ./gradlew :wisefy:jacocoDebugCombinedTestReport :wisefysample:jacocoDebugCombinedTestReport --stacktrace | ||
- codecov/upload: | ||
file: /reports/jacoco/*.xml | ||
- store_artifacts: | ||
path: wisefy/build/reports | ||
destination: reports/wisefy | ||
- store_artifacts: | ||
path: wisefysample/build/reports | ||
destination: reports/wisefysample | ||
- save_cache: | ||
key: jars-{{ checksum "build.gradle" }}-{{ checksum "wisefy/build.gradle" }}-{{ checksum "wisefysample/build.gradle" }} | ||
paths: | ||
- ~/.gradle | ||
|
||
workflows: | ||
version: 2 | ||
workflow: | ||
jobs: | ||
- ci_checks |
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
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
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
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
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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1,2 @@ | ||
## v4.0.0 - 05/x/2019 | ||
## v4.0.0 - 06/22/2019 | ||
|
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,2 +1,2 @@ | ||
codecov: | ||
branch: 3.x | ||
branch: 4.x |
This file was deleted.
Oops, something went wrong.
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
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
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
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
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
Oops, something went wrong.