From e8d6de287bae973b9b3464fe39947c43aad32f4d Mon Sep 17 00:00:00 2001 From: Bryan Van Deusen Date: Sun, 14 Jun 2026 12:34:30 -0400 Subject: [PATCH] test: fix obsolete create_task kind=plan passthrough test MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit test_create_task_passes_kind asserted create_task forwards kind=plan; the hard-retire guard now rejects that. Exercise passthrough with kind=issue instead. (Service-level create_note still accepts task_kind=plan by design — the guard lives at the user-facing tool/route layer, not the primitive.) Co-Authored-By: Claude Opus 4.8 (1M context) --- tests/test_mcp_tool_tasks_kind.py | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/tests/test_mcp_tool_tasks_kind.py b/tests/test_mcp_tool_tasks_kind.py index e05bdb6..bb18319 100644 --- a/tests/test_mcp_tool_tasks_kind.py +++ b/tests/test_mcp_tool_tasks_kind.py @@ -20,11 +20,12 @@ def _fake_note(task_kind="work"): @pytest.mark.asyncio async def test_create_task_passes_kind(): - mock = AsyncMock(return_value=_fake_note(task_kind="plan")) + # kind=plan is retired (plans are milestones); 'issue' exercises passthrough. + mock = AsyncMock(return_value=_fake_note(task_kind="issue")) with patch("scribe.mcp.tools.tasks.notes_svc.create_note", mock): from scribe.mcp.tools.tasks import create_task - await create_task(title="P", kind="plan") - assert mock.call_args.kwargs["task_kind"] == "plan" + await create_task(title="P", kind="issue") + assert mock.call_args.kwargs["task_kind"] == "issue" @pytest.mark.asyncio