language: python

python:
  - "3.4"
  - "3.5"
  - "3.5-dev" # 3.5 development branch
  - "3.6"
  - "3.6-dev" # 3.6 development branch

# Install dependencies
install:
  - pip install flake8 coverage coveralls
  - pip install -r requirements/base.txt
  - pip install -r requirements/test.txt

before_script:
  cd csunplugged/

# Runs test suite
script:
  - flake8 --config=../.flake8
  - coverage run --rcfile=../.coveragerc manage.py test --pattern "test_*.py" -v 3
  - 'if [ "$TRAVIS_PULL_REQUEST" != "false" ]; then manage.py test --pattern "test_*.py" --reverse -v 0; fi'

after_script:
  coverage report --rcfile=../.coveragerc
  #coveralls

# Stop email notifications but post to organisation Slack channel
notifications:
  email: false
  slack:
    rooms: deptfunstuff:abJKvzApk5SKtcEyAgtswXAv
    on_success: change
    on_failure: change

language: python

python:
  - "3.4"
  - "3.5"
  - "3.5-dev" # 3.5 development branch
  - "3.6"
  - "3.6-dev" # 3.6 development branch

# Install dependencies
install:
  - pip install flake8 coverage coveralls
  - pip install -r requirements/base.txt
  - pip install -r requirements/test.txt

before_script:
  cd csunplugged/

# Runs test suite
script:
  - flake8 --config=../.flake8
  - coverage run --rcfile=../.coveragerc manage.py test --pattern "test_*.py" -v 3
  - 'if [ "$TRAVIS_PULL_REQUEST" != "false" ]; then manage.py test --pattern "test_*.py" --reverse -v 0; fi'
  - coverage report --rcfile=../.coveragerc

after_script:
  True
  #coveralls

# Stop email notifications but post to organisation Slack channel
notifications:
  email: false
  slack:
    rooms: deptfunstuff:abJKvzApk5SKtcEyAgtswXAv
    on_success: change
    on_failure: change

Move coverage report into scripts to fail if coverage requirements are not met.
Move coverage report into scripts to fail if coverage requirements are not met.
