MCPcopy Index your code
hub / github.com/ipython/ipython / test_paste_leading_commas

Method test_paste_leading_commas

tests/test_magic_terminal.py:199–208  ·  view source on GitHub ↗

Test multiline strings with leading commas

(self)

Source from the content-addressed store, hash-verified

197 assert out == code + "\n## -- End pasted text --\n"
198
199 def test_paste_leading_commas(self):
200 "Test multiline strings with leading commas"
201 tm = ip.magics_manager.registry["TerminalMagics"]
202 s = '''\
203a = """
204,1,2,3
205"""'''
206 ip.user_ns.pop("foo", None)
207 tm.store_or_execute(s, "foo")
208 self.assertIn("foo", ip.user_ns)
209
210 def test_paste_trailing_question(self):
211 "Test pasting sources with trailing question marks"

Callers

nothing calls this directly

Calls 2

popMethod · 0.80
store_or_executeMethod · 0.80

Tested by

no test coverage detected