def test_paste():
def g():
print('hello world')
def fn():
set_trace()
if 4 != 5: g()
return 42
_, lineno = inspect.getsourcelines(fn)
start_lineno = lineno + 1
check(fn, r"""
[NUM] > .*fn()
-> if 4 != 5: g()
# g()
hello world
# paste g()
hello world
RUN epaste \+%d
hello world
# c
""" % start_lineno)
评论列表
文章目录