Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Run Python flake8 tests on several Nodejs repos #21942

Closed
wants to merge 1 commit into from
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
58 changes: 36 additions & 22 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -1,23 +1,37 @@
language: cpp
compiler:
- clang
sudo: false
cache: ccache
group: travis_latest
dist: xenial # required for Python 3.7
sudo: true # required for Python 3.7
language: python
cache: pip
python:
- 2.7
- 3.7
matrix:
include:
- os: linux
node_js: "latest"
install:
- NODE=$(which node) make lint-md-build
script:
- NODE=$(which node) make lint-ci
- os: linux
install:
- ./configure
- make -j2 V=
script:
- make -j2 test-ci
before_install:
- export CXX="ccache clang++ -Qunused-arguments"
- export CC="ccache clang -Qunused-arguments -Wno-unknown-warning-option"
- export JOBS=2
allow_failures:
- python: 2.7
env:
- REPO=nodejs/node
- REPO=nodejs/node-gyp
- REPO=nodejs/node-auto-test
- REPO=nodejs/node-chakracore
- REPO=nodejs/node-v8
- REPO=nodejs/build
- REPO=nodejs/ffi
- REPO=nodejs/nan
- REPO=nodejs/testing
install:
- pip install flake8
before_script:
- URL=https://github.com/${REPO}
- echo ; echo -n "flake8 testing of ${URL} on " ; python -V
- git clone --depth=50 ${URL} ~/${REPO} # --branch=master
- cd ~/${REPO}
script:
- echo stop the build if there are Python syntax errors or undefined names
- echo ; echo -n "flake8 testing of ${URL} on " ; python -V
- time flake8 . --count --select=E901,E999,F821,F822,F823 --show-source --statistics
- echo exit-zero treats all errors as warnings. The GitHub editor is 127 chars wide
- time flake8 . --count --exit-zero --max-complexity=10 --max-line-length=127 --statistics
notifications:
on_success: change
on_failure: change # `always` will be the setting once code changes slow down