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

Function test_multiple_magics

IPython/core/tests/test_magic.py:1044–1052  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

1042 nt.assert_equal(oinfo['docstring'], FooFoo.line_foo.__doc__)
1043
1044def test_multiple_magics():
1045 ip = get_ipython()
1046 foo1 = FooFoo(ip)
1047 foo2 = FooFoo(ip)
1048 mm = ip.magics_manager
1049 mm.register(foo1)
1050 nt.assert_true(mm.magics['line']['foo'].__self__ is foo1)
1051 mm.register(foo2)
1052 nt.assert_true(mm.magics['line']['foo'].__self__ is foo2)
1053
1054def test_alias_magic():
1055 """Test %alias_magic."""

Callers

nothing calls this directly

Calls 3

get_ipythonFunction · 0.90
FooFooClass · 0.85
registerMethod · 0.45

Tested by

no test coverage detected