MCPcopy Create free account
hub / github.com/celery/celery / pypy_version

Function pypy_version

t/unit/conftest.py:490–497  ·  view source on GitHub ↗

Mock :data:`sys.pypy_version_info` Example:: >>> with pypy_version((3, 6, 1)): ... ...

(value=None)

Source from the content-addressed store, hash-verified

488
489@contextmanager
490def pypy_version(value=None):
491 """Mock :data:`sys.pypy_version_info`
492
493 Example::
494 >>> with pypy_version((3, 6, 1)):
495 ... ...
496 """
497 yield from replace_module_value(sys, 'pypy_version_info', value)
498
499
500def _restore_logging():

Callers

nothing calls this directly

Calls 1

replace_module_valueFunction · 0.85

Tested by

no test coverage detected