Skip to content

Commit

Permalink
Improved CI
Browse files Browse the repository at this point in the history
  • Loading branch information
ZuluPro committed Dec 14, 2016
1 parent 702a1af commit 2f0ad14
Show file tree
Hide file tree
Showing 3 changed files with 53 additions and 8 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -59,3 +59,4 @@ recaptcha
htmlcov
node_modules
bower_components/
.tox
29 changes: 23 additions & 6 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -1,11 +1,28 @@
language: python

python:
- "2.7"
- "pypy"

install:
- python setup.py -q develop
- askbot-setup -n . -e2 -d data.db
- pip install -q -U git+git://github.com/coffin/coffin.git@master git+git://github.com/saltduck/django-followit.git@support_django1.6
before_script:
- python manage.py syncdb --migrate --noinput -v0
- TOX_ENV=py${TRAVIS_PYTHON_VERSION}
- tox -e $TOX_ENV --notest

script:
- python manage.py test askbot
- tox -e $TOX_ENV

after_success:
- tox -e $TOX_ENV -- pip install coveralls
- tox -e $TOX_ENV -- coveralls $COVERALLS_OPTION

matrix:
fast_finish: true
include:
- python: "2.7"
env: TOX_ENV=lint
install: pip install tox
script: tox -e $TOX_ENV
- python: "2.7"
env: TOX_ENV=setup
install: pip install tox
script: tox -e $TOX_ENV
31 changes: 29 additions & 2 deletions tox.ini
Original file line number Diff line number Diff line change
@@ -1,4 +1,31 @@
[tox]
envlist=py26,py25,py27
envlist =
py{2.7,3.4,3.5,pypy}
lint
setup

[testenv]
commands=python manage.py test askbot
whitelist_externals =
echo
basepython =
py2.7: python2.7
py3.4: python3.4
py3.5: python3.5
pypypy: pypy
commands =
askbot-setup -n {toxworkdir} -e2 -d data.db
echo 'ASKBOT_SELF_TEST = False' >> {toxworkdir}/settings.py
python {toxworkdir}/manage.py test askbot

[testenv:lint]
basepython = python
deps =
prospector
commands = prospector askbot -0

[testenv:setup]
basepython = python
commands =
askbot-setup --dir-name=. --db-engine=2 --db-name=db.sql --domain=example.com
python manage.py migrate --noinput
python manage.py collectstatic --noinput

0 comments on commit 2f0ad14

Please sign in to comment.