There are three hand-maintained lists of tools: the per-file mcp.AddTool registrations reached by RegisterAll (full mode), ToolCategories (discovery and router), and buildToolDispatcher (lazy execution). TestDispatcher_AllCategoryToolsCovered pins dispatcher versus ToolCategories parity, but nothing cross-checks the actual set RegisterAll registers. A tool added in full mode but forgotten in ToolCategories and the dispatcher would compile, pass every test, work in full mode, and be silently uncallable via autotask_execute_tool in lazy mode.
Add a test that enumerates the tools the built server actually registers and asserts set-equality with the dispatcher and ToolCategories, so a future tool cannot silently become lazy-mode-only-broken.
Found during post-merge review (see PR #38).
There are three hand-maintained lists of tools: the per-file mcp.AddTool registrations reached by RegisterAll (full mode), ToolCategories (discovery and router), and buildToolDispatcher (lazy execution). TestDispatcher_AllCategoryToolsCovered pins dispatcher versus ToolCategories parity, but nothing cross-checks the actual set RegisterAll registers. A tool added in full mode but forgotten in ToolCategories and the dispatcher would compile, pass every test, work in full mode, and be silently uncallable via autotask_execute_tool in lazy mode.
Add a test that enumerates the tools the built server actually registers and asserts set-equality with the dispatcher and ToolCategories, so a future tool cannot silently become lazy-mode-only-broken.
Found during post-merge review (see PR #38).