MCPcopy Index your code
hub / github.com/python-cmd2/cmd2 / parser

Function parser

tests/test_history.py:386–402  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

384
385@pytest.fixture
386def parser():
387 from cmd2.parsing import (
388 StatementParser,
389 )
390
391 return StatementParser(
392 terminators=[";", "&"],
393 multiline_commands=["multiline"],
394 aliases={
395 "helpalias": "help",
396 "42": "theanswer",
397 "l": "!ls -al",
398 "anothermultiline": "multiline",
399 "fake": "run_pyscript",
400 },
401 shortcuts={"?": "help", "!": "shell"},
402 )
403
404
405def test_multiline_histitem(parser) -> None:

Callers

nothing calls this directly

Calls 1

StatementParserClass · 0.90

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…