MCPcopy Index your code
hub / github.com/RustPython/RustPython / wrapper

Function wrapper

Lib/test/support/__init__.py:389–403  ·  view source on GitHub ↗
(*args, **kw)

Source from the content-addressed store, hash-verified

387 def decorator(func):
388 @functools.wraps(func)
389 def wrapper(*args, **kw):
390 if sys.platform == 'darwin':
391 import platform
392 version_txt = platform.mac_ver()[0]
393 try:
394 version = tuple(map(int, version_txt.split('.')))
395 except ValueError:
396 pass
397 else:
398 if version < min_version:
399 min_version_txt = '.'.join(map(str, min_version))
400 raise unittest.SkipTest(
401 "Mac OS X %s or higher required, not %s"
402 % (min_version_txt, version_txt))
403 return func(*args, **kw)
404 wrapper.min_version = min_version
405 return wrapper
406 return decorator

Callers 1

Calls 15

getattrFunction · 0.85
_MemoryWatchdogClass · 0.85
iterFunction · 0.85
force_colorFunction · 0.85
subTestMethod · 0.80
doCleanupsMethod · 0.80
skipTestMethod · 0.80
AClass · 0.70
funcFunction · 0.50
printFunction · 0.50
fFunction · 0.50
splitMethod · 0.45

Tested by

no test coverage detected