MCPcopy Index your code
hub / github.com/python/cpython / wrapper

Function wrapper

Lib/test/test_sqlite3/util.py:32–39  ·  view source on GitHub ↗
(self, *args, **kwargs)

Source from the content-addressed store, hash-verified

30 _msg_regex = re.compile(msg_regex) if msg_regex else None
31 @functools.wraps(func)
32 def wrapper(self, *args, **kwargs):
33 with test.support.catch_unraisable_exception() as cm:
34 # First, run the test with traceback enabled.
35 with check_tracebacks(self, cm, exc, exc_regex, _msg_regex, name):
36 func(self, *args, **kwargs)
37
38 # Then run the test with traceback disabled.
39 func(self, *args, **kwargs)
40 return wrapper
41 return decorator
42

Callers 4

test_writestrMethod · 0.50
test_writeMethod · 0.50
test_open_writeMethod · 0.50
test_overriding_callMethod · 0.50

Calls 2

check_tracebacksFunction · 0.85
funcFunction · 0.50

Tested by 4

test_writestrMethod · 0.40
test_writeMethod · 0.40
test_open_writeMethod · 0.40
test_overriding_callMethod · 0.40

Used in the wild real call sites across dependent graphs

searching dependent graphs…