diff --git a/.travis.yml b/.travis.yml index 46f1cb6f6..8da902868 100644 --- a/.travis.yml +++ b/.travis.yml @@ -3,14 +3,17 @@ python: 2.7 sudo: false env: matrix: - - TOX_ENV=py26 - - TOX_ENV=py27 - - TOX_ENV=py33 - - TOX_ENV=py34 - - TOX_ENV=pypy - - TOX_ENV=docs - - TOX_ENV=system-tests - - TOX_ENV=system-tests3 + # - TOX_ENV=py26 + # - TOX_ENV=py27 + # - TOX_ENV=py33 + # - TOX_ENV=py34 + # - TOX_ENV=pypy + # - TOX_ENV=docs + # - TOX_ENV=system-tests + # - TOX_ENV=system-tests3 + - TOX_ENV=gae + global: + - GAE_PYTHONPATH=$HOME/google_appengine install: - ./scripts/install.sh script: diff --git a/scripts/install.sh b/scripts/install.sh index 5e8a17d98..c8473c5cb 100755 --- a/scripts/install.sh +++ b/scripts/install.sh @@ -25,3 +25,11 @@ if [[ "${TOX_ENV}" == "pypy" ]]; then pyenv install pypy-2.6.0 pyenv global pypy-2.6.0 fi + +if [[ "${TOX_ENV}" == "gae" && ! -d $HOME/google_appengine ]]; then + cd $HOME + wget https://storage.googleapis.com/appengine-sdks/featured/google_appengine_1.9.25.zip + unzip -q google_appengine_1.9.25.zip + # Directory is required for the App Assertion tests to pass. + mkdir -p $HOME/.config/gcloud +fi diff --git a/tests/data/app.yaml b/tests/data/app.yaml new file mode 100644 index 000000000..9268dfa7d --- /dev/null +++ b/tests/data/app.yaml @@ -0,0 +1,10 @@ +# Dummy app.yaml to placate nosegae. +application: oauth2client +version: 1 +runtime: python27 +api_version: 1 +threadsafe: yes + +handlers: +- url: /.* + script: null.app diff --git a/tox.ini b/tox.ini index 342f512db..39fe50606 100644 --- a/tox.ini +++ b/tox.ini @@ -1,5 +1,5 @@ [tox] -envlist = py26,py27,py33,py34,pypy,cover +envlist = py26,py27,py33,py34,pypy,gae,cover [testenv] basedeps = keyring @@ -51,6 +51,15 @@ basepython = python2.6 deps = {[testenv]basedeps} django>=1.5,<1.6 +[testenv:gae] +basepython = python2.7 +deps = {[testenv]basedeps} + nosegae +commands = + nosetests --with-gae --gae-application=tests/data --logging-level=INFO {posargs} tests/test_appengine.py +setenv: + PYTHONPATH={env:GAE_PYTHONPATH:} + [testenv:system-tests] basepython = python2.7