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: install:
# source because it sets up env vars on some platforms # source because it sets up env vars on some platforms
- source ci/travis/travis_install.sh - source ci/travis/travis_install.sh
script: script: ./run_tests.py
- ci/travis/travis_script.sh
after_success: after_success:
- codecov - codecov
env: env:
@ -18,14 +17,13 @@ env:
- YCM_CORES=3 - YCM_CORES=3
- COVERAGE=true - COVERAGE=true
matrix: matrix:
- YCM_PYTHON_VERSION=2.7 YCM_FLAKE8=true - YCM_PYTHON_VERSION=2.6
# Since 3.0.4, Flake8 is not working anymore on Python 2.6. - YCM_PYTHON_VERSION=2.7
- YCM_PYTHON_VERSION=2.6 YCM_FLAKE8=false - YCM_PYTHON_VERSION=3.3
- YCM_PYTHON_VERSION=3.3 YCM_FLAKE8=true
matrix: matrix:
exclude: exclude:
- os: osx - os: osx
env: YCM_PYTHON_VERSION=2.6 YCM_FLAKE8=false env: YCM_PYTHON_VERSION=2.6
addons: addons:
apt: apt:
sources: 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,8 +1,10 @@
flake8>=2.0 # Flake8 3.x dropped support of Python 2.6 and 3.3
mock>=1.0.1 flake8 < 3.0.0; python_version == '2.6' or python_version == '3.3'
nose>=1.3.7 flake8 >= 3.0.0; python_version == '2.7' or python_version > '3.3'
PyHamcrest>=1.8.0 mock >= 1.0.1
nose >= 1.3.7
PyHamcrest >= 1.8.0
# This needs to be kept in sync with submodule checkout in # This needs to be kept in sync with submodule checkout in
# third_party/ycmd/third_party # third_party/ycmd/third_party
future==0.15.2 future == 0.15.2
codecov>=2.0.5 codecov >= 2.0.5