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

Function test_config_print_class

IPython/core/tests/test_magic.py:125–134  ·  view source on GitHub ↗

test that config with a classname prints the class's options.

()

Source from the content-addressed store, hash-verified

123 nt.assert_list_equal(config_classes, sorted(set(config_classes)))
124
125def test_config_print_class():
126 """ test that config with a classname prints the class's options. """
127 with capture_output() as captured:
128 _ip.magic('config TerminalInteractiveShell')
129
130 stdout = captured.stdout
131 if not re.match("TerminalInteractiveShell.* options", stdout.splitlines()[0]):
132 print(stdout)
133 raise AssertionError("1st line of stdout not like "
134 "'TerminalInteractiveShell.* options'")
135
136def test_rehashx():
137 # clear up everything

Callers

nothing calls this directly

Calls 2

capture_outputClass · 0.85
magicMethod · 0.45

Tested by

no test coverage detected