summaryrefslogtreecommitdiff
path: root/coverage/misc.py
diff options
context:
space:
mode:
authorNed Batchelder <ned@nedbatchelder.com>2015-05-23 07:37:35 -0400
committerNed Batchelder <ned@nedbatchelder.com>2015-05-23 07:37:35 -0400
commit056b3385c45b8e65fb29c06813c0dc6cc44796d2 (patch)
tree4ce855ee0f66820c82816fcb648e93ef826d8529 /coverage/misc.py
parent3d8f486b2974772a7524b64fcba68bea4a2929fb (diff)
downloadpython-coveragepy-git-056b3385c45b8e65fb29c06813c0dc6cc44796d2.tar.gz
Pylint weeding
Diffstat (limited to 'coverage/misc.py')
-rw-r--r--coverage/misc.py6
1 files changed, 2 insertions, 4 deletions
diff --git a/coverage/misc.py b/coverage/misc.py
index 6131ec2a..0dad0559 100644
--- a/coverage/misc.py
+++ b/coverage/misc.py
@@ -11,10 +11,8 @@ from coverage.backward import string_class, to_bytes, unicode_class
# Use PyContracts for assertion testing on parameters and returns, but only if
# we are running our own test suite.
-contract = None
-
if env.TESTING:
- from contracts import contract
+ from contracts import contract # pylint: disable=unused-import
from contracts import new_contract
# Define contract words that PyContract doesn't have.
@@ -25,7 +23,7 @@ if env.TESTING:
else:
# We aren't using real PyContracts, so just define a no-op decorator as a
# stunt double.
- def contract(**unused): # pylint: disable=function-redefined
+ def contract(**unused):
"""Dummy no-op implementation of `contract`."""
return lambda func: func