Permalink
Fetching contributors…
Cannot retrieve contributors at this time
76 lines (75 sloc) 2.27 KB
sudo: false
language: python
python:
- '3.5'
env:
global:
- PIP_RETRIES=10
- PIP_TIMEOUT=30
- BROWSER=phantomjs
matrix:
- TOXENV=checkqa
- TOXENV=base-py35-django20-sqlite
matrix:
allow_failures:
- env: TOXENV=base-py35-django20-sqlite
install:
- travis_retry pip install -U pip
- travis_retry pip install tox
- travis_retry pip freeze
before_script:
- "export DISPLAY=:99.0"
- "sh -e /etc/init.d/xvfb start"
- sleep 3 # give xvfb some time to start
- if echo "$TOXENV" | grep mysql; then mysql -e 'create database autocomplete_light_test;';
fi
- if echo "$TOXENV" | grep postgresql; then psql -c 'create database autocomplete_light_test;'
-U postgres; fi
- set -eux;
export PHANTOMJS_VERSION=2.1.1;
phantomjs --version;
export PATH=$HOME/travis_phantomjs/phantomjs-$PHANTOMJS_VERSION-linux-x86_64/bin:$PATH;
phantomjs --version;
if [ "$(phantomjs --version)" != "$PHANTOMJS_VERSION" ]; then
rm -rf $HOME/travis_phantomjs;
mkdir -p $HOME/travis_phantomjs;
if [ ! -f $HOME/travis_phantomjs/phantomjs-$PHANTOMJS_VERSION-linux-x86_64.tar.bz2 ]; then
travis_retry wget
https://github.com/Medium/phantomjs/releases/download/v$PHANTOMJS_VERSION/phantomjs-$PHANTOMJS_VERSION-linux-x86_64.tar.bz2
-O $HOME/travis_phantomjs/phantomjs-$PHANTOMJS_VERSION-linux-x86_64.tar.bz2;
fi;
tar -xvf
$HOME/travis_phantomjs/phantomjs-$PHANTOMJS_VERSION-linux-x86_64.tar.bz2
-C $HOME/travis_phantomjs;
fi;
phantomjs --version;
set +eu
script:
- tox -r
- test -d .tox/$TOXENV/log && cat .tox/$TOXENV/log/*.log || true
after_success:
- travis_retry pip install codecov
- cd test_project && codecov
notifications:
irc:
channels:
- irc.freenode.org#yourlabs
template:
- "%{repository} (%{commit} %{author}) : %{message} %{build_url} %{compare_url}"
cache:
directories:
- .tox/$TOXENV
- $HOME/.cache/pip
- $HOME/travis_phantomjs
deploy:
provider: openshift
user: jpic@yourlabs.org
password:
secure: FuIzy9CJ1+SSsLFVXj942Y4DYzv2NLAktHML+VB3IBR+JdJ4cTW7lftwUmmghXE4HmBoHbKsDlpwN/dErPy0yDl2bv3ejJWRWyekIOyu0Omwia0PDTEt6n/mryrQ92dAyjpD6SeypotHqhOCnj1HxJdgwL4EmzG+5o9n8eNte0M=
app: dal
domain: yourlabs
deployment_branch: master
skip_cleanup: true
on:
repo: yourlabs/django-autocomplete-light
branch: master