checkout:
  post:  
    - cp -r .circleci/licenses/. $ANDROID_HOME/licenses

machine:
  java:
    version:
      oraclejdk8

test:
  override:
    - ./gradlew test

checkout:
  post:
    - cp -r .circleci/licenses/. $ANDROID_HOME/licenses

machine:
  java:
    version:
      oraclejdk8

test:
  pre:
    - emulator -avd circleci-android24 -no-window:
        background: true
        parallel: true
  override:
    - ./gradlew test
    - circle-android wait-for-boot
    - ./gradlew connectedAndroidTest

Enable Android tests in CircleCI
Enable Android tests in CircleCI
