Skip to content

Commit

Permalink
Add more automated checks
Browse files Browse the repository at this point in the history
  • Loading branch information
myint committed Jan 4, 2018
1 parent cf4d7fa commit f74645b
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 5 deletions.
7 changes: 6 additions & 1 deletion .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,12 @@ install:

script:
- ./setup.py test
- ./test_fuzz.py *.py
- ./test_fuzz.py ./*.py

- pyflakes ./*.py
- pip install pycodestyle pydocstyle
- pycodestyle ./*.py
- pydocstyle autoflake.py setup.py

after_success:
- pip install --quiet coverage
Expand Down
3 changes: 2 additions & 1 deletion Makefile
Original file line number Diff line number Diff line change
@@ -1,10 +1,11 @@
check:
pycodestyle autoflake.py setup.py
pyflakes ./*.py
pylint \
--reports=no \
--rcfile=/dev/null \
--errors-only \
autoflake.py setup.py
pycodestyle ./*.py
pydocstyle autoflake.py setup.py
check-manifest
python setup.py --long-description | rstcheck -
Expand Down
7 changes: 4 additions & 3 deletions test_autoflake.py
Original file line number Diff line number Diff line change
Expand Up @@ -1101,9 +1101,10 @@ def test_exclude(self):
'w') as output:
output.write('import os\n')

p = subprocess.Popen(list(AUTOFLAKE_COMMAND) +
[temp_directory, '--recursive', '--exclude=a*'],
stdout=subprocess.PIPE)
p = subprocess.Popen(
list(AUTOFLAKE_COMMAND) +
[temp_directory, '--recursive', '--exclude=a*'],
stdout=subprocess.PIPE)
result = p.communicate()[0].decode('utf-8')

self.assertNotIn('import re', result)
Expand Down

0 comments on commit f74645b

Please sign in to comment.