MCPcopy Create free account
hub / github.com/agentforce314/clawcodex / test_history

Method test_history

tests/test_ide_connection.py:125–135  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

123 self.assertEqual(tracker.current.file_path, "test.py")
124
125 def test_history(self) -> None:
126 tracker = SelectionTracker(max_history=3)
127 for i in range(5):
128 tracker.update(IDESelection(
129 file_path=f"file{i}.py",
130 text=f"text{i}",
131 range=IDERange(1, 0, 1, 5),
132 ))
133 # Max 3 in history
134 self.assertEqual(len(tracker.history), 3)
135 self.assertEqual(tracker.history[0].file_path, "file4.py")
136
137 def test_listener(self) -> None:
138 tracker = SelectionTracker()

Callers

nothing calls this directly

Calls 4

updateMethod · 0.95
SelectionTrackerClass · 0.90
IDESelectionClass · 0.90
IDERangeClass · 0.90

Tested by

no test coverage detected