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

Method complete_bar

tests/test_dynamic_complete_style.py:23–26  ·  view source on GitHub ↗
(self, text, line, begidx, endidx)

Source from the content-addressed store, hash-verified

21 pass
22
23 def complete_bar(self, text, line, begidx, endidx) -> Completions:
24 # Return 5 items
25 items = [f"item{i}" for i in range(5) if f"item{i}".startswith(text)]
26 return Completions.from_values(items)
27
28
29@pytest.fixture

Callers

nothing calls this directly

Calls 1

from_valuesMethod · 0.80

Tested by

no test coverage detected