diff --git a/.travis.yml b/.travis.yml index 952eda78..1c887fed 100644 --- a/.travis.yml +++ b/.travis.yml @@ -24,27 +24,18 @@ matrix: # is used on Windows Subsystem for Linux. addons: apt: + update: true sources: - sourceline: 'ppa:fdroid/fdroidserver' packages: - - bash - - dash - - pylint - - pep8 - - python3-babel - - python3-dev - - python3-pip - - python3-ruamel.yaml - - python3-setuptools - - python3.4-venv - - libjpeg-dev - - zlib1g-dev - - fdroidserver + - python3-babel + - python3-setuptools + - fdroidserver android: components: - android-23 # required for `fdroid build` test - - build-tools-25.0.3 # required for `fdroid build` test + - build-tools-27.0.3 # required for `fdroid build` test licenses: - 'android-sdk-preview-.+' - 'android-sdk-license-.+' @@ -101,15 +92,12 @@ install: fi # The OSX tests seem to run slower, they often timeout. So only run -# the test suite with the installed version of fdroid, instead of the -# three rounds that ./complete-ci-tests does. +# the test suite with the installed version of fdroid. +# +# Supporting pip on Ubuntu/trusty was too painful here, since it seems +# that pip installs conflict with the Ubuntu packages. script: - - cd tests - - if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then - ./run-tests; - else - ./complete-ci-tests; - fi + - ./tests/run-tests after_failure: - cd $TRAVIS_BUILD_DIR diff --git a/tests/complete-ci-tests b/tests/complete-ci-tests index 6201eb2c..c1c812b2 100755 --- a/tests/complete-ci-tests +++ b/tests/complete-ci-tests @@ -27,6 +27,11 @@ if [ -z $ANDROID_HOME ]; then fi fi +if ! which pyvenv; then + echo "pyvenv required to run this test suite!" + exit 1 +fi + apksource=$1 #------------------------------------------------------------------------------# @@ -35,31 +40,12 @@ if [ -z $PIP_DOWNLOAD_CACHE ]; then export PIP_DOWNLOAD_CACHE=$HOME/.pip_download_cache fi - -#------------------------------------------------------------------------------# -# required Java 7 or later keytool/jarsigner for :file support - -export PATH=/usr/lib/jvm/java-8-openjdk-amd64/bin:$PATH - - #------------------------------------------------------------------------------# # run local tests, don't scan fdroidserver/ project for APKs cd $WORKSPACE/tests ./run-tests $apksource -#------------------------------------------------------------------------------# -# find pyvenv, to support Ubuntu/trusty's python3.4-venv - -if which pyvenv; then - pyvenv=pyvenv -elif which pyvenv-3.4; then - pyvenv=pyvenv-3.4 -else - echo "pyvenv required to run this test suite!" - exit 1 -fi - #------------------------------------------------------------------------------# # make sure that translations do not cause stacktraces @@ -78,10 +64,8 @@ done # test install using install direct from git repo cd $WORKSPACE rm -rf $WORKSPACE/env -$pyvenv $WORKSPACE/env +pyvenv $WORKSPACE/env . $WORKSPACE/env/bin/activate -# workaround https://github.com/pypa/setuptools/issues/937 -pip3 install --quiet setuptools==33.1.1 Babel pip3 install --quiet -e $WORKSPACE python3 setup.py compile_catalog install