summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBrian Kearns <bdkearns@gmail.com>2014-10-23 19:46:28 -0400
committerBrian Kearns <bdkearns@gmail.com>2014-10-23 19:49:44 -0400
commit46aeda57095527ac1c567c17e0ef8a63a0d63d3f (patch)
tree645f07d2e3cd583768c61ed538e44ef6aa5ed979
parent4c5bf00cb613be617c7f48d3b2b82a1c7b895ac1 (diff)
downloadpep8-46aeda57095527ac1c567c17e0ef8a63a0d63d3f.tar.gz
add .tox to DEFAULT_EXCLUDE
-rwxr-xr-xpep8.py2
-rw-r--r--testsuite/test_api.py4
2 files changed, 4 insertions, 2 deletions
diff --git a/pep8.py b/pep8.py
index b31a978..f92d891 100755
--- a/pep8.py
+++ b/pep8.py
@@ -63,7 +63,7 @@ try:
except ImportError:
from ConfigParser import RawConfigParser
-DEFAULT_EXCLUDE = '.svn,CVS,.bzr,.hg,.git,__pycache__'
+DEFAULT_EXCLUDE = '.svn,CVS,.bzr,.hg,.git,__pycache__,.tox'
DEFAULT_IGNORE = 'E123,E226,E24,E704'
if sys.platform == 'win32':
DEFAULT_CONFIG = os.path.expanduser(r'~\.pep8')
diff --git a/testsuite/test_api.py b/testsuite/test_api.py
index 672f202..352c17b 100644
--- a/testsuite/test_api.py
+++ b/testsuite/test_api.py
@@ -160,7 +160,8 @@ class APITestCase(unittest.TestCase):
['directories', 'files',
'logical lines', 'physical lines'])
self.assertEqual(pep8style.options.exclude,
- ['.svn', 'CVS', '.bzr', '.hg', '.git', '__pycache__'])
+ ['.svn', 'CVS', '.bzr', '.hg',
+ '.git', '__pycache__', '.tox'])
self.assertEqual(pep8style.options.filename, ['*.py'])
self.assertEqual(pep8style.options.format, 'default')
self.assertEqual(pep8style.options.select, ())
@@ -233,6 +234,7 @@ class APITestCase(unittest.TestCase):
self.assertFalse(pep8style.excluded('./foo/bar/main.py'))
self.assertTrue(pep8style.excluded('./CVS'))
+ self.assertTrue(pep8style.excluded('./.tox'))
self.assertTrue(pep8style.excluded('./subdir/CVS'))
self.assertTrue(pep8style.excluded('__pycache__'))
self.assertTrue(pep8style.excluded('./__pycache__'))