gitlab-ci
This commit is contained in:
parent
e30b9e541b
commit
af5e051a74
|
@ -0,0 +1,50 @@
|
|||
image: hatsoftwares/mastalab-ci:latest
|
||||
|
||||
before_script:
|
||||
- export ANDROID_HOME=/opt/android-sdk-linux
|
||||
- export PATH=$PATH:/opt/android-sdk-linux/platform-tools/
|
||||
- export GRADLE_USER_HOME=$(pwd)/.gradle/
|
||||
- chmod +x gradlew
|
||||
|
||||
stages:
|
||||
- prepare
|
||||
- build
|
||||
- test
|
||||
|
||||
prepare:
|
||||
stage: prepare
|
||||
script:
|
||||
- ./gradlew tasks
|
||||
|
||||
assembleDebug:
|
||||
stage: build
|
||||
script:
|
||||
- ./gradlew assembleDebug
|
||||
cache:
|
||||
key: "$CI_COMMIT_SHA"
|
||||
paths:
|
||||
- app/build/outputs/
|
||||
- .gradle/
|
||||
policy: push
|
||||
|
||||
lintDebug:
|
||||
stage: test
|
||||
cache:
|
||||
key: "$CI_COMMIT_SHA"
|
||||
paths:
|
||||
- app/build/outputs/
|
||||
- .gradle/
|
||||
policy: pull
|
||||
script:
|
||||
- ./gradlew --stacktrace -Pci --console=plain :app:lintFdroidDebug -PbuildDir=lint
|
||||
|
||||
debugTests:
|
||||
stage: test
|
||||
cache:
|
||||
key: "$CI_COMMIT_SHA"
|
||||
paths:
|
||||
- app/build/outputs/
|
||||
- .gradle/
|
||||
policy: pull
|
||||
script:
|
||||
- ./gradlew --stacktrace -Pci --console=plain :app:testFdroidDebugUnitTest
|
Loading…
Reference in New Issue