From 056b3385c45b8e65fb29c06813c0dc6cc44796d2 Mon Sep 17 00:00:00 2001 From: Ned Batchelder Date: Sat, 23 May 2015 07:37:35 -0400 Subject: Pylint weeding --- coverage/misc.py | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) (limited to 'coverage/misc.py') 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 -- cgit v1.2.1