MCPcopy Index your code
hub / github.com/tiann/hapi / getConfigHandler

Function getConfigHandler

cli/src/opencode/runOpencode.test.ts:117–124  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

115 });
116
117 function getConfigHandler(): (payload: unknown) => Promise<unknown> {
118 const registerCalls = harness.session.rpcHandlerManager.registerHandler.mock.calls;
119 const configHandler = registerCalls.find(
120 (call: unknown[]) => call[0] === 'set-session-config'
121 );
122 expect(configHandler).toBeDefined();
123 return configHandler![1] as (payload: unknown) => Promise<unknown>;
124 }
125
126 it('rejects plan mode for local OpenCode startup', async () => {
127 await expect(runOpencode({ permissionMode: 'plan' })).rejects.toThrow(

Callers 1

Calls

no outgoing calls

Tested by

no test coverage detected