-
Notifications
You must be signed in to change notification settings - Fork 1.9k
/
Copy path.travis.yml
39 lines (32 loc) · 1.92 KB
/
.travis.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
sudo: required
dist: xenial # needed for more recent python 3 and python3-venv
language: generic
services:
- docker
before_install:
- travis_retry sudo apt update -qq
- travis_retry sudo apt install -qq --no-install-recommends python2.7 python3 python3-venv python3-virtualenv
# (venv/virtualenv are both used by tests/test_pythonpackage.py)
- sudo pip install tox>=2.0
# https://github.com/travis-ci/travis-ci/issues/6069#issuecomment-266546552
- git remote set-branches --add origin master
- git fetch
env:
global:
- ANDROID_SDK_HOME=/opt/android/android-sdk
- ANDROID_NDK_HOME=/opt/android/android-ndk
matrix:
- COMMAND='. venv/bin/activate && cd testapps/ && python setup_testapp_python3_sqlite_openssl.py apk --sdk-dir $ANDROID_SDK_HOME --ndk-dir $ANDROID_NDK_HOME --requirements libffi,sdl2,pyjnius,kivy,python3,openssl,requests,sqlite3,setuptools'
# overrides requirements to skip `peewee` pure python module, see:
# https://github.com/kivy/python-for-android/issues/1263#issuecomment-390421054
- COMMAND='. venv/bin/activate && cd testapps/ && python setup_testapp_python2_sqlite_openssl.py apk --sdk-dir $ANDROID_SDK_HOME --ndk-dir $ANDROID_NDK_HOME --requirements sdl2,pyjnius,kivy,python2,openssl,requests,sqlite3,setuptools'
- COMMAND='. venv/bin/activate && cd testapps/ && python setup_testapp_python2.py apk --sdk-dir $ANDROID_SDK_HOME --ndk-dir $ANDROID_NDK_HOME --bootstrap sdl2 --requirements python2,numpy'
# builds only the recipes that moved
- COMMAND='. venv/bin/activate && ./ci/rebuild_updated_recipes.py'
before_script:
# we want to fail fast on tox errors without having to `docker build` first
- tox -- tests/ --ignore tests/test_pythonpackage.py
# (we ignore test_pythonpackage.py since these run way too long!! test_pythonpackage_basic.py will still be run.)
script:
- docker build --tag=p4a --file Dockerfile.py3 .
- docker run -e CI p4a /bin/sh -c "$COMMAND"