MCPcopy Create free account
hub / github.com/IBM/mcp-cli / test_linear_execution

Method test_linear_execution

tests/planning/test_executor.py:290–304  ·  view source on GitHub ↗

Sequential plan executes all steps in order.

(self, tmp_path)

Source from the content-addressed store, hash-verified

288
289 @pytest.mark.asyncio
290 async def test_linear_execution(self, tmp_path):
291 """Sequential plan executes all steps in order."""
292 tm = FakeToolManager({"read_file": "file data", "search_code": "found main"})
293 context = PlanningContext(tm, plans_dir=tmp_path / "plans")
294 runner = PlanRunner(context, enable_guards=False)
295
296 result = await runner.execute_plan(SAMPLE_PLAN, checkpoint=False)
297
298 assert result.success
299 assert len(result.steps) == 2
300 assert result.steps[0].success
301 assert result.steps[0].tool_name == "read_file"
302 assert result.steps[1].success
303 assert result.steps[1].tool_name == "search_code"
304 assert result.total_duration > 0
305
306 @pytest.mark.asyncio
307 async def test_variable_binding(self, tmp_path):

Callers

nothing calls this directly

Calls 4

execute_planMethod · 0.95
PlanningContextClass · 0.90
PlanRunnerClass · 0.90
FakeToolManagerClass · 0.70

Tested by

no test coverage detected