circle.yml 1.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051
  1. #
  2. # Build configuration for Circle CI
  3. #
  4. machine:
  5. environment:
  6. ANDROID_HOME: /usr/local/android-sdk-linux
  7. ANDROID_NDK_HOME: $ANDROID_NDK
  8. NODE_ENV: test
  9. NODE_PATH: $NODE_PATH:$HOME/$CIRCLE_PROJECT_REPONAME/node_modules:$HOME/$CIRCLE_PROJECT_REPONAME/node_modules/cordova/node_modules
  10. PATH: $PATH:$HOME/$CIRCLE_PROJECT_REPONAME/node_modules/.bin
  11. dependencies:
  12. override:
  13. - npm install
  14. - cordova create app-preferences-app
  15. #dependencies:
  16. # override:
  17. # - echo y | android update sdk --no-ui --all --filter tools,platform-tools,build-tools-21.1.2,android-21,extra-google-m2repository,extra-google-google_play_services,extra-android-support
  18. # - ANDROID_HOME=/usr/local/android-sdk-linux ./gradlew dependencies
  19. test:
  20. pre:
  21. - emulator -avd circleci-android22 -no-audio -no-window:
  22. background: true
  23. parallel: true
  24. - circle-android wait-for-boot
  25. override:
  26. - echo running jasmine test
  27. - jasmine:
  28. pwd: bin
  29. - echo test plugin within cordova app
  30. - cordova platform add android:
  31. pwd: app-preferences-app
  32. - cordova plugin add https://github.com/apla/me.apla.cordova.app-preferences:
  33. pwd: app-preferences-app
  34. - cordova plugin add cordova-plugin-device:
  35. pwd: app-preferences-app
  36. - (if [ ! -f app-settings.json ]; then exit 0; fi):
  37. pwd: app-preferences-app
  38. - cp plugins/cordova-plugin-app-preferences/src/test.js www/js/apppreferences-test.js:
  39. pwd: app-preferences-app
  40. - patch -p0 -i plugins/cordova-plugin-app-preferences/src/test.patch:
  41. pwd: app-preferences-app
  42. - cordova prepare:
  43. pwd: app-preferences-app
  44. - cordova -d build --debug --emulator android:
  45. pwd: app-preferences-app
  46. - node ../bin/test-server.js android circleci-android22:
  47. pwd: app-preferences-app