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

Function test_reset_in

IPython/core/tests/test_magic.py:349–356  ·  view source on GitHub ↗

Test '%reset in' magic

()

Source from the content-addressed store, hash-verified

347 nt.assert_equal(len(_ip.user_ns['Out']), 0)
348
349def test_reset_in():
350 "Test '%reset in' magic"
351 # test '%reset -f in'
352 _ip.run_cell("parrot", store_history=True)
353 nt.assert_true('parrot' in [_ip.user_ns[x] for x in ('_i','_ii','_iii')])
354 _ip.magic('%reset -f in')
355 nt.assert_false('parrot' in [_ip.user_ns[x] for x in ('_i','_ii','_iii')])
356 nt.assert_equal(len(set(_ip.user_ns['In'])), 1)
357
358def test_reset_dhist():
359 "Test '%reset dhist' magic"

Callers

nothing calls this directly

Calls 2

run_cellMethod · 0.45
magicMethod · 0.45

Tested by

no test coverage detected