MCPcopy
hub / github.com/cool-RR/PySnooper / foo

Function foo

tests/test_pysnooper.py:59–74  ·  view source on GitHub ↗
(x)

Source from the content-addressed store, hash-verified

57 snoop = pysnooper.snoop(relative_time=True, color=False)
58
59 def foo(x):
60 if x == 0:
61 bar1(x)
62 qux()
63 return
64
65 with snoop:
66 # There should be line entries for these three lines,
67 # no line entries for anything else in this function,
68 # but calls to all bar functions should be traced
69 foo(x - 1)
70 bar2(x)
71 qux()
72 int(4)
73 bar3(9)
74 return x
75
76 @snoop
77 def bar1(_x):

Callers 2

test_relative_timeFunction · 0.70
test_with_blockFunction · 0.70

Calls 4

bar1Function · 0.85
quxFunction · 0.85
bar2Function · 0.85
bar3Function · 0.85

Tested by

no test coverage detected