Skip to content

Commit

Permalink
Add pylint checker
Browse files Browse the repository at this point in the history
  • Loading branch information
MartinBasti committed Jun 26, 2016
1 parent 257f2ae commit d7e0aef
Show file tree
Hide file tree
Showing 4 changed files with 84 additions and 2 deletions.
3 changes: 2 additions & 1 deletion .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ python:
- "3.5-dev" # 3.5 development branch
- "nightly" # currently points to 3.6-dev
install:
- pip install unittest2
- pip install unittest2 pylint
script:
- if [[ $TRAVIS_PYTHON_VERSION != '2.6' ]]; then make lint; fi
- make test
3 changes: 3 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -59,3 +59,6 @@ check: test

test:
cd tests; make PYTHON=${PYTHON} test

lint:
pylint dns
73 changes: 73 additions & 0 deletions pylintrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,73 @@
[MASTER]
# Pickle collected data for later comparisons.
persistent=no

# Use multiple processes to speed up Pylint.
jobs=1

[MESSAGES CONTROL]

enable=
all,
python3

disable=
R,
I,
anomalous-backslash-in-string,
arguments-differ,
assigning-non-slot,
attribute-defined-outside-init,
bad-builtin,
bad-continuation,
bad-whitespace,
bare-except,
basestring-builtin,
delslice-method,
deprecated-lambda,
deprecated-method,
dict-iter-method,
fixme,
getslice-method,
global-statement,
import-error,
invalid-name,
long-builtin,
missing-docstring,
no-absolute-import,
no-member,
notimplemented-raised,
old-division,
protected-access,
range-builtin-not-iterating,
redefined-builtin,
round-builtin,
superfluous-parens,
too-many-lines,
undefined-loop-variable,
undefined-variable,
unichr-builtin,
unicode-builtin,
unnecessary-lambda,
unneeded-not,
unused-argument,
unused-import,
unused-variable,
wrong-import-order,
wrong-import-position,
xrange-builtin


[REPORTS]

# Set the output format. Available formats are text, parseable, colorized, msvs
# (visual studio) and html. You can also give a reporter class, eg
# mypackage.mymodule.MyReporterClass.
output-format=colorized

# Tells whether to display a full report or only the messages
reports=no

# Template used to display messages. This is a python new-style format string
# used to format the message information. See doc for all details
msg-template='{path}:{line}: [{msg_id}({symbol}), {obj}] {msg})'
7 changes: 6 additions & 1 deletion tox.ini
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ envlist =
py34,
# py35,
flake8,
# pylint,
pylint,
coverage

[testenv]
Expand All @@ -29,6 +29,11 @@ commands =
pip install flake8
flake8 dns

[testenv:pylint]
commands =
pip install pylint
pylint dns

[testenv:coverage]
basepython = python2

Expand Down

0 comments on commit d7e0aef

Please sign in to comment.