MCPcopy Create free account
hub / github.com/cloudflare/mcp / mockMultiAccountUser

Function mockMultiAccountUser

tests/executor.test.ts:148–156  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

146 // A user token spanning >1 account: account_id can't be auto-resolved, so an
147 // execute call without account_id binds no usable `accountId`.
148 function mockMultiAccountUser() {
149 mockIdentityProbe({
150 user: { id: 'u1', email: 'u@example.com' },
151 accounts: [
152 { id: ACCOUNT_ID, name: 'Acc One' },
153 { id: '00000000000000000000000000000002', name: 'Acc Two' }
154 ]
155 })
156 }
157
158 it('runs account-independent calls that never read accountId', async () => {
159 mockMultiAccountUser()

Callers 1

executor.test.tsFile · 0.85

Calls 1

mockIdentityProbeFunction · 0.90

Tested by

no test coverage detected