Auto merge of #2476 - micbou:flake8, r=Valloric

[READY] Do not disable Flake8 on Python 2.6 Travis but restrict its version

See PR https://github.com/Valloric/ycmd/pull/665.

<!-- Reviewable:start -->
---
This change is [<img src="https://reviewable.io/review_button.svg" height="34" align="absmiddle" alt="Reviewable"/>](https://reviewable.io/reviews/valloric/youcompleteme/2476)
<!-- Reviewable:end -->
This commit is contained in:
Homu 2016-12-19 03:20:28 +09:00
commit 194ff33466
3 changed files with 13 additions and 20 deletions

View File

@ -8,8 +8,7 @@ before_install:
install:
# source because it sets up env vars on some platforms
- source ci/travis/travis_install.sh
script:
- ci/travis/travis_script.sh
script: ./run_tests.py
after_success:
- codecov
env:
@ -18,14 +17,13 @@ env:
- YCM_CORES=3
- COVERAGE=true
matrix:
- YCM_PYTHON_VERSION=2.7 YCM_FLAKE8=true
# Since 3.0.4, Flake8 is not working anymore on Python 2.6.
- YCM_PYTHON_VERSION=2.6 YCM_FLAKE8=false
- YCM_PYTHON_VERSION=3.3 YCM_FLAKE8=true
- YCM_PYTHON_VERSION=2.6
- YCM_PYTHON_VERSION=2.7
- YCM_PYTHON_VERSION=3.3
matrix:
exclude:
- os: osx
env: YCM_PYTHON_VERSION=2.6 YCM_FLAKE8=false
env: YCM_PYTHON_VERSION=2.6
addons:
apt:
sources:

View File

@ -1,7 +0,0 @@
#!/bin/bash
if [ "${YCM_FLAKE8}" = true ]; then
./run_tests.py
else
./run_tests.py --no-flake8
fi

View File

@ -1,4 +1,6 @@
flake8>=2.0
# Flake8 3.x dropped support of Python 2.6 and 3.3
flake8 < 3.0.0; python_version == '2.6' or python_version == '3.3'
flake8 >= 3.0.0; python_version == '2.7' or python_version > '3.3'
mock >= 1.0.1
nose >= 1.3.7
PyHamcrest >= 1.8.0