refactor(llm-workflow): remove mockttp-based MockServerCapability#43071
refactor(llm-workflow): remove mockttp-based MockServerCapability#43071cryptotavares wants to merge 2 commits into
Conversation
Replace with Playwright route-based `mm mock-network` for session-scoped network mocking. The mockttp proxy capability, its tests, port allocation, and all wiring through the factory, daemon, and session manager are removed. Pre-launch mocking is not yet supported and will be added in a follow-up.
|
CLA Signature Action: All authors have signed the CLA. You may need to manually re-run the blocking PR check if it doesn't pass in a few minutes. |
|
Review the following changes in direct dependencies. Learn more about Socket for GitHub.
|
|
Warning MetaMask internal reviewing guidelines:
|
Description
Removes the
MetaMaskMockServerCapabilityfrom the LLM workflow system (test/e2e/playwright/llm-workflow/). Network mocking is now handled by Playwright route interception via themm mock-networkCLI command, which is session-scoped and supports both page and service-worker contexts.What changed:
mock-server.tsandmock-server.test.ts(277 lines removed)mockServeroptions fromCreateMetaMaskContextOptionsand the factoryMetaMaskSessionManagerproxyServerwiring to the browser launcherMockServerCapabilityimport from@metamask/client-mcp-coreChangelog
CHANGELOG entry: null
Related issues
Manual testing steps
yarn test:unit test/e2e/playwright/llm-workflow/— all tests passmm launch— session starts without mock server port allocationmm mock-network add '{"id":"test","method":"GET","url":"https://example.com/**","response":{"json":{"ok":true}}}'— Playwright route mock is activemm cleanup— clean shutdown without mock server teardown errorsPre-merge author checklist
Pre-merge reviewer checklist