Skip to content

test: observe CLI construction and forwarding across manifest refusals - #2

Draft
dinakarjs wants to merge 1 commit into
review/cmcp744-basefrom
test/cmcp744-cli-boundary
Draft

dinakarjs wants to merge 1 commit into
review/cmcp744-basefrom
test/cmcp744-cli-boundary

Conversation

@dinakarjs

Copy link
Copy Markdown
Owner

Review follow-up for upstream cMCP agentrust-io#744 at exact head 0581739fcf02649ad6b21cf298a74f76a1520fce.

Its synthetic forwarding test initializes forwarded=0 and never observes a forwarding seam on the refusal branch. This one-file proposal invokes the production Click start entry point, wraps the real build_server and CMCPProxy constructor, and observes an AsyncMock at _forward_to_upstream. The valid twin composes one actual server/proxy and forwards one synthetic call. Eleven refusal cases observe zero server builds, zero proxy constructions and zero forwarding awaits: signed seal mismatch/missing, policy mismatch, subject mismatch, expiry, empty trust, missing/duplicate/unknown requirements, signature tampering and changed catalog server identity.

The original fixture module is reused as a pytest plugin; no production source is changed. uvicorn.run is replaced only in tests to avoid opening a listener, and the upstream is mocked. These are software-only composition/forwarding controls, not live provider, hardware, deployment completeness or conformance evidence.

Local Python 3.12.14, installed hash-locked cMCP dependencies (Agent Manifest 0.15.0; cbor2 6.1.4): original PR unit/integration suite 2353 passed / 6 skipped; focused original module 10 passed; new CLI controls 12 passed; combined unit/integration including the addition 2365 passed / 6 skipped. Ruff passes. Initial full-suite failures came from inherited SOCKS proxy variables and HTTPX's absent optional socksio; the successful run unset those environment variables without changing dependency declarations. No live workflow was dispatched or runtime bypass committed.

This draft is an isolated contributor-fork diff for the original author to integrate or adapt. It does not update their branch, approve/merge agentrust-io#744 or extend the experimental profile's normative scope.

Signed-off-by: Srinivasa Dinakar Jainti dinakarjs@gmail.com

Signed-off-by: Srinivasa Dinakar Jainti <dinakarjs@gmail.com>
@github-actions

github-actions Bot commented Oct 13, 2026 •

Copy link
Copy Markdown

🟡 Contributor Check: MEDIUM

Check Result
Profile MEDIUM
Credential LOW
Overall MEDIUM

Automated check by AgenTrust Contributor Check.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

needs-review:MEDIUM Contributor check flagged MEDIUM risk

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant