MCPcopy Create free account
hub / github.com/ipython/ipython / test_time3

Function test_time3

IPython/core/tests/test_magic.py:447–455  ·  view source on GitHub ↗

Erroneous magic function calls, issue gh-3334

()

Source from the content-addressed store, hash-verified

445 ip.run_cell("%time None")
446
447def test_time3():
448 """Erroneous magic function calls, issue gh-3334"""
449 ip = get_ipython()
450 ip.user_ns.pop('run', None)
451
452 with tt.AssertNotPrints("not found", channel='stderr'):
453 ip.run_cell("%%time\n"
454 "run = 0\n"
455 "run += 1")
456
457def test_multiline_time():
458 """Make sure last statement from time return a value."""

Callers

nothing calls this directly

Calls 3

get_ipythonFunction · 0.90
popMethod · 0.80
run_cellMethod · 0.45

Tested by

no test coverage detected