1
0
mirror of https://github.com/nvbn/thefuck.git synced 2025-01-19 12:24:29 +00:00

N/A: Add osx to travis-ci config

This commit is contained in:
Vladimir Iakovlev 2016-08-14 07:16:22 +03:00
parent 56851e8d31
commit a1f115eb19

View File

@ -1,10 +1,25 @@
language: python language: python
sudo: false sudo: false
python: matrix:
- "3.5" include:
- "3.4" - os: linux
- "3.3" dist: trusty
- "2.7" python: "3.5"
- os: linux
dist: trusty
python: "3.4"
- os: linux
dist: trusty
python: "3.3"
- os: linux
dist: trusty
python: "2.7"
- os: osx
env: FORMULA="python"
language: generic
- os: osx
env: FORMULA="python3"
language: generic
services: services:
- docker - docker
addons: addons:
@ -12,16 +27,21 @@ addons:
packages: packages:
- python-commandnotfound - python-commandnotfound
- python3-commandnotfound - python3-commandnotfound
install: before_install:
- if [[ $TRAVIS_OS_NAME == "osx" ]]; then brew update ; fi
- if [[ $TRAVIS_OS_NAME == "osx" ]]; then brew install $FORMULA; fi
- if [[ $TRAVIS_OS_NAME == "osx" ]]; then virtualenv venv -p $FORMULA; fi
- if [[ $TRAVIS_OS_NAME == "osx" ]]; then source venv/bin/activate; fi
- pip install -U pip - pip install -U pip
- pip install -U coveralls - pip install -U coveralls
install:
- pip install -Ur requirements.txt - pip install -Ur requirements.txt
- python setup.py develop - python setup.py develop
- rm -rf build - rm -rf build
script: script:
- export COVERAGE_PYTHON_VERSION=python-${TRAVIS_PYTHON_VERSION:0:1} - export COVERAGE_PYTHON_VERSION=python-${TRAVIS_PYTHON_VERSION:0:1}
- export RUN_TESTS="coverage run --source=thefuck,tests -m py.test -v --capture=sys" - export RUN_TESTS="coverage run --source=thefuck,tests -m py.test -v --capture=sys tests"
- if [[ $TRAVIS_PYTHON_VERSION == 3.5 ]]; then $RUN_TESTS --enable-functional; fi - if [[ $TRAVIS_PYTHON_VERSION == 3.5 && $TRAVIS_OS_NAME != "osx" ]]; then $RUN_TESTS --enable-functional; fi
- if [[ $TRAVIS_PYTHON_VERSION != 3.5 ]]; then $RUN_TESTS; fi - if [[ $TRAVIS_PYTHON_VERSION != 3.5 || $TRAVIS_OS_NAME == "osx" ]]; then $RUN_TESTS; fi
after_success: after_success:
- coveralls - coveralls