diff options
author | Ned Batchelder <ned@nedbatchelder.com> | 2022-12-27 07:04:26 -0500 |
---|---|---|
committer | Ned Batchelder <ned@nedbatchelder.com> | 2022-12-27 07:24:44 -0500 |
commit | 9f7d19540e8a716279284f19a6a324311649b98e (patch) | |
tree | 6563c3360f24a0945b8bac7e6bc22ba16e99918e /coverage/misc.py | |
parent | 5af6270dd72f2a217823a32bf7141d3f7c1a2a92 (diff) | |
download | python-coveragepy-git-9f7d19540e8a716279284f19a6a324311649b98e.tar.gz |
refactor: remove more of the PyContracts stuff
Diffstat (limited to 'coverage/misc.py')
-rw-r--r-- | coverage/misc.py | 10 |
1 files changed, 4 insertions, 6 deletions
diff --git a/coverage/misc.py b/coverage/misc.py index 34b743dc..fe59ef6d 100644 --- a/coverage/misc.py +++ b/coverage/misc.py @@ -91,18 +91,16 @@ def import_third_party(modname): return None -def dummy_decorator_with_args(*args_unused, **kwargs_unused): +# We don't use PyContracts anymore, but the @contracts decorators will be +# useful info when it comes time to add type annotations, so keep them as +# dummies for now. +def contract(*args_unused, **kwargs_unused): """Dummy no-op implementation of a decorator with arguments.""" def _decorator(func): return func return _decorator -# We aren't using real PyContracts, so just define our decorators as -# stunt-double no-ops. -contract = dummy_decorator_with_args -one_of = dummy_decorator_with_args - def new_contract(*args_unused, **kwargs_unused): """Dummy no-op implementation of `new_contract`.""" pass |