MCPcopy
hub / github.com/pytest-dev/pytest / rewrite

Function rewrite

testing/test_assertrewrite.py:43–46  ·  view source on GitHub ↗
(src: str)

Source from the content-addressed store, hash-verified

41
42
43def rewrite(src: str) -> ast.Module:
44 tree = ast.parse(src)
45 rewrite_asserts(tree, src.encode())
46 return tree
47
48
49def getmsg(

Callers 5

getmsgFunction · 0.85
test_location_is_setMethod · 0.85
preservedMethod · 0.85
test_dont_rewriteMethod · 0.85

Calls 2

rewrite_assertsFunction · 0.90
parseMethod · 0.45

Tested by

no test coverage detected