test(mcp-integrations): add MCP plugin and backend integration tests#3232
test(mcp-integrations): add MCP plugin and backend integration tests#3232HusneShabbir wants to merge 1 commit into
Conversation
Missing ChangesetsThe following package(s) are changed by this PR but do not have a changeset:
See CONTRIBUTING.md for more information about how to add changesets. Changed Packages
|
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #3232 +/- ##
==========================================
+ Coverage 60.97% 61.00% +0.03%
==========================================
Files 2098 2098
Lines 65140 65150 +10
Branches 17029 17029
==========================================
+ Hits 39721 39747 +26
+ Misses 25180 25164 -16
Partials 239 239
*This pull request uses carry forward flags. Click here to find out more. Continue to review full report in Codecov by Sentry.
🚀 New features to boost your workflow:
|
4921c97 to
f1a9e17
Compare
Add integration tests for action registration and MCP tools/list/call coverage, including auth and pluginSources filtering. Mark read-only actions with MCP attributes and configure backend test runner to exit cleanly after integration runs. Co-authored-by: Cursor <cursoragent@cursor.com>
f1a9e17 to
827b7fe
Compare
|



Summary
Integration tests for MCP overlay plugins: plugin wiring (action registration) and backend MCP HTTP (
tools/list,tools/call, auth).Test file structure
Total: 4 files · 12 integration tests (runs in CI via
yarn test:all)Plugin tests — “does the plugin register the right actions?”
Each file starts
startTestBackend, capturesactionsRegistry.register(), and asserts action names + count.software-catalog-mcp-extras/.../plugin.integration.test.tsquery-catalog-entities(1)techdocs-mcp-extras/.../plugin.integration.test.tsfetch-techdocs,analyze-techdocs-coverage,retrieve-techdocs-content(3)scaffolder-mcp-extras/.../plugin.integration.test.tsfetch-template-metadata,list-scaffolder-tasks,get-scaffolder-task-logs,list-scaffolder-actions,validate-scaffolder,execute-template(6)Backend test — “does the MCP server work over HTTP?”
packages/backend/src/mcp-tools.integration.test.ts— real MCP client against/api/mcp-actions/v1.inputSchemaon every toolpluginSourcesfilter → catalog-only returns 1 toolquery-catalog-entities→{ entities: [] }analyze-techdocs-coverage→ zero coverage statsfetch-template-metadata→{ templates: [] }tools/listsucceedsSupporting changes
attributeson 5 actions (for MCP metadata tests)CI=true … --forceExittest scriptCI
workspaces/mcp-integrations→ Test changed packages → 15 suites, 132 tests pass (includes these 12 + existing unit tests).