@kya-os/mcp-i-core 1.2.2-canary.26 → 1.2.2-canary.27

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,3756 +1,28 @@
1
-
2
- 
3
- > @kya-os/mcp-i-core@1.2.2-canary.24 test:coverage /Users/dylanhobbs/Documents/@kya-os/xmcp-i/packages/mcp-i-core
4
- > vitest run --coverage
5
-
6
- [?25l▲ [WARNING] The condition "types" here will never be used as it comes after both "import" and "require" [package.json]
7
-
8
- package.json:32:6:
9
-  32 │ "types": "./dist/utils/did-helpers.d.ts"
10
- ╵ ~~~~~~~
11
-
12
- The "import" condition comes earlier and will be used for all "import"
13
- statements:
14
-
15
- package.json:31:6:
16
-  31 │ "import": "./dist/utils/did-helpers.js",
17
- ╵ ~~~~~~~~
18
-
19
- The "require" condition comes earlier and will be used for all "require" calls:
20
-
21
- package.json:30:6:
22
-  30 │ "require": "./dist/utils/did-helpers.js",
23
- ╵ ~~~~~~~~~
24
-
25
-
26
-  RUN  v4.0.5 /Users/dylanhobbs/Documents/@kya-os/xmcp-i/packages/mcp-i-core
27
- Coverage enabled with v8
28
-
29
- [?2026h
30
-  ❯ src/__tests__/services/provider-resolver-edge-cases.test.ts [queued]
31
-
32
-  Test Files 0 passed (43)
33
-  Tests 0 passed (0)
34
-  Start at 22:55:10
35
-  Duration 101ms
36
- [?2026l[?2026h
37
-  ❯ src/__tests__/cache/tool-protection-cache.test.ts 0/49
38
-  ❯ src/__tests__/runtime/route-interception.test.ts [queued]
39
-  ❯ src/__tests__/runtime/tool-protection-enforcement.test.ts [queued]
40
-  ❯ src/__tests__/services/agentshield-integration.test.ts [queued]
41
-  ❯ src/__tests__/services/provider-resolver-edge-cases.test.ts [queued]
42
-  ❯ src/__tests__/services/tool-protection.service.test.ts [queued]
43
-  ❯ src/delegation/__tests__/vc-issuer.test.ts [queued]
44
-  ❯ src/delegation/__tests__/vc-verifier.test.ts [queued]
45
-  ❯ src/services/__tests__/access-control.integration.test.ts [queued]
46
-  ❯ src/services/__tests__/access-control.service.test.ts [queued]
47
-  ❯ src/services/__tests__/crypto.service.test.ts [queued]
48
-  ❯ src/services/__tests__/proof-verifier.integration.test.ts [queued]
49
-  ❯ src/services/__tests__/storage.service.test.ts [queued]
50
-
51
-  Test Files 0 passed (43)
52
-  Tests 0 passed (49)
53
-  Start at 22:55:10
54
-  Duration 302ms
55
- [?2026l[?2026hstdout | src/__tests__/services/agentshield-integration.test.ts > AgentShield Integration > API Authentication > should use X-API-Key header for new endpoint
56
- [ToolProtectionService] Config loaded from API {
57
- source: 'api',
58
- toolCount: 0,
59
- protectedTools: [],
60
- agentDid: 'did:key:z6MkhaXgBZDv...',
61
- projectId: 'test-project-123',
62
- cacheTtlMs: 300000,
63
- cacheExpiresAt: '2025-11-22T05:00:10.829Z'
64
- }
65
-
66
- stdout | src/__tests__/services/agentshield-integration.test.ts > AgentShield Integration > API Authentication > should use Authorization Bearer header for old endpoint
67
- [ToolProtectionService] Config loaded from API {
68
- source: 'api',
69
- toolCount: 0,
70
- protectedTools: [],
71
- agentDid: 'did:key:z6MkhaXgBZDv...',
72
- projectId: 'none',
73
- cacheTtlMs: 300000,
74
- cacheExpiresAt: '2025-11-22T05:00:10.833Z'
75
- }
76
-
77
- stdout | src/__tests__/services/agentshield-integration.test.ts > AgentShield Integration > Endpoint Selection > should use project-scoped endpoint when projectId is available
78
- [ToolProtectionService] Config loaded from API {
79
- source: 'api',
80
- toolCount: 0,
81
- protectedTools: [],
82
- agentDid: 'did:key:z6MkhaXgBZDv...',
83
- projectId: 'test-project-123',
84
- cacheTtlMs: 300000,
85
- cacheExpiresAt: '2025-11-22T05:00:10.835Z'
86
- }
87
-
88
- stdout | src/__tests__/services/agentshield-integration.test.ts > AgentShield Integration > Endpoint Selection > should use agent-scoped endpoint when projectId is not available
89
- [ToolProtectionService] Config loaded from API {
90
- source: 'api',
91
- toolCount: 0,
92
- protectedTools: [],
93
- agentDid: 'did:key:z6MkhaXgBZDv...',
94
- projectId: 'none',
95
- cacheTtlMs: 300000,
96
- cacheExpiresAt: '2025-11-22T05:00:10.835Z'
97
- }
98
-
99
- stdout | src/__tests__/services/agentshield-integration.test.ts > AgentShield Integration > Endpoint Selection > should encode projectId in URL
100
- [ToolProtectionService] Config loaded from API {
101
- source: 'api',
102
- toolCount: 0,
103
- protectedTools: [],
104
- agentDid: 'did:key:z6MkhaXgBZDv...',
105
- projectId: 'project/with/special-chars',
106
- cacheTtlMs: 300000,
107
- cacheExpiresAt: '2025-11-22T05:00:10.835Z'
108
- }
109
-
110
- stdout | src/__tests__/services/agentshield-integration.test.ts > AgentShield Integration > Endpoint Selection > should encode agent DID in URL
111
- [ToolProtectionService] Config loaded from API {
112
- source: 'api',
113
- toolCount: 0,
114
- protectedTools: [],
115
- agentDid: 'did:key:z6MkhaXgBZDv...',
116
- projectId: 'none',
117
- cacheTtlMs: 300000,
118
- cacheExpiresAt: '2025-11-22T05:00:10.835Z'
119
- }
120
-
121
- stdout | src/__tests__/services/agentshield-integration.test.ts > AgentShield Integration > Response Format Compatibility > should handle new endpoint format (toolProtections object)
122
- [ToolProtectionService] Config loaded from API {
123
- source: 'api',
124
- toolCount: 2,
125
- protectedTools: [ 'checkout' ],
126
- agentDid: 'did:key:z6MkhaXgBZDv...',
127
- projectId: 'test-project-123',
128
- cacheTtlMs: 300000,
129
- cacheExpiresAt: '2025-11-22T05:00:10.835Z'
130
- }
131
-
132
- stdout | src/__tests__/services/agentshield-integration.test.ts > AgentShield Integration > Response Format Compatibility > should handle old endpoint format (tools array)
133
- [ToolProtectionService] Config loaded from API {
134
- source: 'api',
135
- toolCount: 2,
136
- protectedTools: [ 'checkout' ],
137
- agentDid: 'did:key:z6MkhaXgBZDv...',
138
- projectId: 'none',
139
- cacheTtlMs: 300000,
140
- cacheExpiresAt: '2025-11-22T05:00:10.836Z'
141
- }
142
-
143
- stdout | src/__tests__/services/agentshield-integration.test.ts > AgentShield Integration > Response Format Compatibility > should handle old endpoint format (tools object)
144
- [ToolProtectionService] Config loaded from API {
145
- source: 'api',
146
- toolCount: 2,
147
- protectedTools: [ 'checkout' ],
148
- agentDid: 'did:key:z6MkhaXgBZDv...',
149
- projectId: 'none',
150
- cacheTtlMs: 300000,
151
- cacheExpiresAt: '2025-11-22T05:00:10.836Z'
152
- }
153
-
154
- stdout | src/__tests__/services/agentshield-integration.test.ts > AgentShield Integration > Response Format Compatibility > should handle snake_case field names
155
- [ToolProtectionService] Config loaded from API {
156
- source: 'api',
157
- toolCount: 1,
158
- protectedTools: [ 'tool1' ],
159
- agentDid: 'did:key:z6MkhaXgBZDv...',
160
- projectId: 'test-project-123',
161
- cacheTtlMs: 300000,
162
- cacheExpiresAt: '2025-11-22T05:00:10.836Z'
163
- }
164
-
165
- stdout | src/__tests__/services/agentshield-integration.test.ts > AgentShield Integration > Response Format Compatibility > should handle camelCase field names
166
- [ToolProtectionService] Config loaded from API {
167
- source: 'api',
168
- toolCount: 1,
169
- protectedTools: [ 'tool1' ],
170
- agentDid: 'did:key:z6MkhaXgBZDv...',
171
- projectId: 'test-project-123',
172
- cacheTtlMs: 300000,
173
- cacheExpiresAt: '2025-11-22T05:00:10.836Z'
174
- }
175
-
176
- stdout | src/__tests__/services/agentshield-integration.test.ts > AgentShield Integration > Response Format Compatibility > should prefer camelCase over snake_case when both present
177
- [ToolProtectionService] Config loaded from API {
178
- source: 'api',
179
- toolCount: 1,
180
- protectedTools: [ 'tool1' ],
181
- agentDid: 'did:key:z6MkhaXgBZDv...',
182
- projectId: 'test-project-123',
183
- cacheTtlMs: 300000,
184
- cacheExpiresAt: '2025-11-22T05:00:10.836Z'
185
- }
186
-
187
-
188
-  ❯ src/__tests__/cache/tool-protection-cache.test.ts 1/49
189
-  ❯ src/__tests__/runtime/route-interception.test.ts [queued]
190
-  ❯ src/__tests__/runtime/tool-protection-enforcement.test.ts [queued]
191
-  ❯ src/__tests__/services/agentshield-integration.test.ts 0/30
192
-  ❯ src/__tests__/services/provider-resolver-edge-cases.test.ts [queued]
193
-  ❯ src/__tests__/services/tool-protection.service.test.ts 49/49
194
-  ❯ src/delegation/__tests__/vc-issuer.test.ts 0/21
195
-  ❯ src/delegation/__tests__/vc-verifier.test.ts 0/35
196
-  ❯ src/services/__tests__/access-control.integration.test.ts [queued]
197
-  ❯ src/services/__tests__/access-control.service.test.ts 23/23
198
-  ❯ src/services/__tests__/crypto.service.test.ts 34/34
199
-  ❯ src/services/__tests__/proof-verifier.integration.test.ts [queued]
200
-  ❯ src/services/__tests__/storage.service.test.ts 17/17
201
-
202
-  Test Files 4 passed (43)
203
-  Tests 124 passed (258)
204
-  Start at 22:55:10
205
-  Duration 402ms
206
- [?2026l[?2026hstderr | src/__tests__/services/agentshield-integration.test.ts > AgentShield Integration > Error Handling > should handle network timeout
207
- [ToolProtectionService] API fetch failed, using fallback config { agentDid: 'did:key:z6MkhaXgBZDv...', error: 'Network timeout' }
208
-
209
- stderr | src/__tests__/services/agentshield-integration.test.ts > AgentShield Integration > Fallback Behavior > should cache fallback config
210
- [ToolProtectionService] API fetch failed, using fallback config { agentDid: 'did:key:z6MkhaXgBZDv...', error: 'Network error' }
211
-
212
-
213
-  ❯ src/__tests__/cache/tool-protection-cache.test.ts 1/49
214
-  ❯ src/__tests__/runtime/route-interception.test.ts [queued]
215
-  ❯ src/__tests__/runtime/tool-protection-enforcement.test.ts [queued]
216
-  ❯ src/__tests__/services/agentshield-integration.test.ts 0/30
217
-  ❯ src/__tests__/services/provider-resolver-edge-cases.test.ts [queued]
218
-  ❯ src/__tests__/services/tool-protection.service.test.ts 49/49
219
-  ❯ src/delegation/__tests__/vc-issuer.test.ts 0/21
220
-  ❯ src/delegation/__tests__/vc-verifier.test.ts 0/35
221
-  ❯ src/services/__tests__/access-control.integration.test.ts [queued]
222
-  ❯ src/services/__tests__/access-control.service.test.ts 23/23
223
-  ❯ src/services/__tests__/crypto.service.test.ts 34/34
224
-  ❯ src/services/__tests__/proof-verifier.integration.test.ts [queued]
225
-  ❯ src/services/__tests__/storage.service.test.ts 17/17
226
-
227
-  Test Files 4 passed (43)
228
-  Tests 124 passed (258)
229
-  Start at 22:55:10
230
-  Duration 402ms
231
- [?2026l[?2026hstdout | src/__tests__/services/agentshield-integration.test.ts > AgentShield Integration > Caching Integration > should cache successful API responses
232
- [ToolProtectionService] Config loaded from API {
233
- source: 'api',
234
- toolCount: 1,
235
- protectedTools: [ 'tool1' ],
236
- agentDid: 'did:key:z6MkhaXgBZDv...',
237
- projectId: 'test-project-123',
238
- cacheTtlMs: 300000,
239
- cacheExpiresAt: '2025-11-22T05:00:10.838Z'
240
- }
241
-
242
- stdout | src/__tests__/services/agentshield-integration.test.ts > AgentShield Integration > Caching Integration > should respect cache TTL
243
- [ToolProtectionService] Config loaded from API {
244
- source: 'api',
245
- toolCount: 0,
246
- protectedTools: [],
247
- agentDid: 'did:key:z6MkhaXgBZDv...',
248
- projectId: 'test-project-123',
249
- cacheTtlMs: 1000,
250
- cacheExpiresAt: '2025-11-22T04:55:11.839Z'
251
- }
252
-
253
- stdout | src/__tests__/services/tool-protection.service.test.ts > ToolProtectionService > getToolProtectionConfig > API fetch - new endpoint format > should fetch from project-scoped endpoint when projectId is available
254
- [ToolProtectionService] Config loaded from API {
255
- source: 'api',
256
- toolCount: 2,
257
- protectedTools: [ 'checkout' ],
258
- agentDid: 'did:key:z6MkhaXgBZDv...',
259
- projectId: 'test-project-123',
260
- cacheTtlMs: 300000,
261
- cacheExpiresAt: '2025-11-22T05:00:10.855Z'
262
- }
263
-
264
- stdout | src/__tests__/services/tool-protection.service.test.ts > ToolProtectionService > getToolProtectionConfig > API fetch - new endpoint format > should handle new endpoint format with toolProtections object
265
- [ToolProtectionService] Config loaded from API {
266
- source: 'api',
267
- toolCount: 2,
268
- protectedTools: [ 'protected_tool' ],
269
- agentDid: 'did:key:z6MkhaXgBZDv...',
270
- projectId: 'test-project-123',
271
- cacheTtlMs: 300000,
272
- cacheExpiresAt: '2025-11-22T05:00:10.857Z'
273
- }
274
-
275
- stdout | src/__tests__/services/tool-protection.service.test.ts > ToolProtectionService > getToolProtectionConfig > API fetch - new endpoint format > should parse oauthProvider from new endpoint format (Phase 2)
276
- [ToolProtectionService] Config loaded from API {
277
- source: 'api',
278
- toolCount: 2,
279
- protectedTools: [ 'read_repos', 'send_email' ],
280
- agentDid: 'did:key:z6MkhaXgBZDv...',
281
- projectId: 'test-project-123',
282
- cacheTtlMs: 300000,
283
- cacheExpiresAt: '2025-11-22T05:00:10.857Z'
284
- }
285
-
286
- stdout | src/__tests__/services/tool-protection.service.test.ts > ToolProtectionService > getToolProtectionConfig > API fetch - new endpoint format > should preserve oauthProvider through cache operations
287
- [ToolProtectionService] Config loaded from API {
288
- source: 'api',
289
- toolCount: 1,
290
- protectedTools: [ 'read_repos' ],
291
- agentDid: 'did:key:z6MkhaXgBZDv...',
292
- projectId: 'test-project-123',
293
- cacheTtlMs: 300000,
294
- cacheExpiresAt: '2025-11-22T05:00:10.857Z'
295
- }
296
-
297
- stdout | src/__tests__/services/tool-protection.service.test.ts > ToolProtectionService > getToolProtectionConfig > API fetch - old endpoint format > should fetch from agent-scoped endpoint when projectId is not available
298
- [ToolProtectionService] Config loaded from API {
299
- source: 'api',
300
- toolCount: 2,
301
- protectedTools: [ 'checkout' ],
302
- agentDid: 'did:key:z6MkhaXgBZDv...',
303
- projectId: 'none',
304
- cacheTtlMs: 300000,
305
- cacheExpiresAt: '2025-11-22T05:00:10.857Z'
306
- }
307
-
308
- stdout | src/__tests__/services/tool-protection.service.test.ts > ToolProtectionService > getToolProtectionConfig > API fetch - old endpoint format > should handle old endpoint format with tools array
309
- [ToolProtectionService] Config loaded from API {
310
- source: 'api',
311
- toolCount: 2,
312
- protectedTools: [ 'tool1' ],
313
- agentDid: 'did:key:z6MkhaXgBZDv...',
314
- projectId: 'none',
315
- cacheTtlMs: 300000,
316
- cacheExpiresAt: '2025-11-22T05:00:10.858Z'
317
- }
318
-
319
- stdout | src/__tests__/services/tool-protection.service.test.ts > ToolProtectionService > getToolProtectionConfig > API fetch - old endpoint format > should parse oauthProvider from old endpoint format (tools array)
320
- [ToolProtectionService] Config loaded from API {
321
- source: 'api',
322
- toolCount: 2,
323
- protectedTools: [ 'read_repos', 'send_email' ],
324
- agentDid: 'did:key:z6MkhaXgBZDv...',
325
- projectId: 'none',
326
- cacheTtlMs: 300000,
327
- cacheExpiresAt: '2025-11-22T05:00:10.858Z'
328
- }
329
-
330
- stdout | src/__tests__/services/tool-protection.service.test.ts > ToolProtectionService > getToolProtectionConfig > API fetch - old endpoint format > should handle old endpoint format with tools object
331
- [ToolProtectionService] Config loaded from API {
332
- source: 'api',
333
- toolCount: 2,
334
- protectedTools: [ 'tool1' ],
335
- agentDid: 'did:key:z6MkhaXgBZDv...',
336
- projectId: 'none',
337
- cacheTtlMs: 300000,
338
- cacheExpiresAt: '2025-11-22T05:00:10.858Z'
339
- }
340
-
341
- stdout | src/__tests__/services/tool-protection.service.test.ts > ToolProtectionService > getToolProtectionConfig > API fetch - old endpoint format > should parse oauthProvider from old endpoint format (tools object)
342
- [ToolProtectionService] Config loaded from API {
343
- source: 'api',
344
- toolCount: 2,
345
- protectedTools: [ 'read_repos', 'send_email' ],
346
- agentDid: 'did:key:z6MkhaXgBZDv...',
347
- projectId: 'none',
348
- cacheTtlMs: 300000,
349
- cacheExpiresAt: '2025-11-22T05:00:10.858Z'
350
- }
351
-
352
- stdout | src/__tests__/services/tool-protection.service.test.ts > ToolProtectionService > getToolProtectionConfig > API fetch - old endpoint format > should skip tools without name in array format
353
- [ToolProtectionService] Cache miss, fetching from API {
354
- source: 'api-fetch-start',
355
- cacheKey: 'agent:did:key:z6MkhaXgBZDvotDkL5257faiztiGiC2QtKLGpbnnEGta2doK',
356
- agentDid: 'did:key:z6MkhaXgBZDv...',
357
- projectId: 'none',
358
- apiUrl: 'https://kya.vouched.id',
359
- endpoint: '/api/v1/bouncer/config?agent_did=did:key:z6MkhaXgBZDvotDkL5257faiztiGiC2QtKLGpbnnEGta2doK'
360
- }
361
- [ToolProtectionService] Fetching from API: https://kya.vouched.id/api/v1/bouncer/config?agent_did=did%3Akey%3Az6MkhaXgBZDvotDkL5257faiztiGiC2QtKLGpbnnEGta2doK {
362
- method: 'config?agent_did (old)',
363
- projectId: 'none',
364
- apiKeyPresent: true,
365
- apiKeyLength: 18,
366
- apiKeyMasked: 'test-api...'
367
- }
368
-
369
- stdout | src/__tests__/services/tool-protection.service.test.ts > ToolProtectionService > getToolProtectionConfig > API fetch - old endpoint format > should skip tools without name in array format
370
- [ToolProtectionService] API response received {
371
- source: 'api-fetch-complete',
372
- agentDid: 'did:key:z6MkhaXgBZDv...',
373
- projectId: 'none',
374
- responseKeys: [ 'success', 'data', 'metadata' ],
375
- dataKeys: [ 'tools' ],
376
- rawToolProtections: null,
377
- rawTools: [
378
- { name: 'valid_tool', requiresDelegation: true },
379
- { requiresDelegation: false }
380
- ],
381
- responseMetadata: {}
382
- }
383
-
384
- stdout | src/__tests__/services/tool-protection.service.test.ts > ToolProtectionService > getToolProtectionConfig > API fetch - old endpoint format > should skip tools without name in array format
385
- [ToolProtectionService] Config loaded from API {
386
- source: 'api',
387
- toolCount: 1,
388
- protectedTools: [ 'valid_tool' ],
389
- agentDid: 'did:key:z6MkhaXgBZDv...',
390
- projectId: 'none',
391
- cacheTtlMs: 300000,
392
- cacheExpiresAt: '2025-11-22T05:00:10.859Z'
393
- }
394
- [ToolProtectionService] API fetch successful, config cached {
395
- source: 'cache-write',
396
- agentDid: 'did:key:z6MkhaXgBZDv...',
397
- cacheKey: 'agent:did:key:z6MkhaXgBZDvotDkL5257faiztiGiC2QtKLGpbnnEGta2doK',
398
- toolCount: 1,
399
- tools: [ { name: 'valid_tool', requiresDelegation: true, scopeCount: 0 } ],
400
- ttlMs: 300000,
401
- ttlMinutes: 5,
402
- expiresAt: '2025-11-22T05:00:10.859Z',
403
- expiresIn: '300s'
404
- }
405
-
406
-
407
-  ❯ src/__tests__/cache/tool-protection-cache.test.ts 1/49
408
-  ❯ src/__tests__/runtime/route-interception.test.ts [queued]
409
-  ❯ src/__tests__/runtime/tool-protection-enforcement.test.ts [queued]
410
-  ❯ src/__tests__/services/agentshield-integration.test.ts 0/30
411
-  ❯ src/__tests__/services/provider-resolver-edge-cases.test.ts [queued]
412
-  ❯ src/__tests__/services/tool-protection.service.test.ts 49/49
413
-  ❯ src/delegation/__tests__/vc-issuer.test.ts 0/21
414
-  ❯ src/delegation/__tests__/vc-verifier.test.ts 0/35
415
-  ❯ src/services/__tests__/access-control.integration.test.ts [queued]
416
-  ❯ src/services/__tests__/access-control.service.test.ts 23/23
417
-  ❯ src/services/__tests__/crypto.service.test.ts 34/34
418
-  ❯ src/services/__tests__/proof-verifier.integration.test.ts [queued]
419
-  ❯ src/services/__tests__/storage.service.test.ts 17/17
420
-
421
-  Test Files 4 passed (43)
422
-  Tests 124 passed (258)
423
-  Start at 22:55:10
424
-  Duration 402ms
425
- [?2026l[?2026hstderr | src/__tests__/services/tool-protection.service.test.ts > ToolProtectionService > getToolProtectionConfig > API fetch error handling > should handle network errors gracefully
426
- [ToolProtectionService] API fetch failed, no fallback, failing closed (deny-all) {
427
- agentDid: 'did:key:z6MkhaXgBZDv...',
428
- error: 'ECONNREFUSED',
429
- cacheKey: 'agent:did:key:z6MkhaXgBZDvotDkL5257faiztiGiC2QtKLGpbnnEGta2doK'
430
- }
431
-
432
-
433
-  ❯ src/__tests__/cache/tool-protection-cache.test.ts 1/49
434
-  ❯ src/__tests__/runtime/route-interception.test.ts [queued]
435
-  ❯ src/__tests__/runtime/tool-protection-enforcement.test.ts [queued]
436
-  ❯ src/__tests__/services/agentshield-integration.test.ts 0/30
437
-  ❯ src/__tests__/services/provider-resolver-edge-cases.test.ts [queued]
438
-  ❯ src/__tests__/services/tool-protection.service.test.ts 49/49
439
-  ❯ src/delegation/__tests__/vc-issuer.test.ts 0/21
440
-  ❯ src/delegation/__tests__/vc-verifier.test.ts 0/35
441
-  ❯ src/services/__tests__/access-control.integration.test.ts [queued]
442
-  ❯ src/services/__tests__/access-control.service.test.ts 23/23
443
-  ❯ src/services/__tests__/crypto.service.test.ts 34/34
444
-  ❯ src/services/__tests__/proof-verifier.integration.test.ts [queued]
445
-  ❯ src/services/__tests__/storage.service.test.ts 17/17
446
-
447
-  Test Files 4 passed (43)
448
-  Tests 124 passed (258)
449
-  Start at 22:55:10
450
-  Duration 402ms
451
- [?2026l[?2026hstdout | src/__tests__/services/tool-protection.service.test.ts > ToolProtectionService > getToolProtectionConfig > caching behavior > should cache successful API responses
452
- [ToolProtectionService] Config loaded from API {
453
- source: 'api',
454
- toolCount: 1,
455
- protectedTools: [ 'tool1' ],
456
- agentDid: 'did:key:z6MkhaXgBZDv...',
457
- projectId: 'none',
458
- cacheTtlMs: 300000,
459
- cacheExpiresAt: '2025-11-22T05:00:10.863Z'
460
- }
461
-
462
- stdout | src/__tests__/services/tool-protection.service.test.ts > ToolProtectionService > getToolProtectionConfig > caching behavior > should use default cache TTL when not specified
463
- [ToolProtectionService] Config loaded from API {
464
- source: 'api',
465
- toolCount: 0,
466
- protectedTools: [],
467
- agentDid: 'did:key:z6MkhaXgBZDv...',
468
- projectId: 'none',
469
- cacheTtlMs: 300000,
470
- cacheExpiresAt: '2025-11-22T05:00:10.863Z'
471
- }
472
-
473
- stdout | src/__tests__/services/tool-protection.service.test.ts > ToolProtectionService > getToolProtectionConfig > caching behavior > should use custom cache TTL when specified
474
- [ToolProtectionService] Config loaded from API {
475
- source: 'api',
476
- toolCount: 0,
477
- protectedTools: [],
478
- agentDid: 'did:key:z6MkhaXgBZDv...',
479
- projectId: 'none',
480
- cacheTtlMs: 600000,
481
- cacheExpiresAt: '2025-11-22T05:05:10.863Z'
482
- }
483
-
484
- stdout | src/__tests__/services/tool-protection.service.test.ts > ToolProtectionService > getToolProtectionConfig > edge cases > should handle empty toolProtections object
485
- [ToolProtectionService] Config loaded from API {
486
- source: 'api',
487
- toolCount: 0,
488
- protectedTools: [],
489
- agentDid: 'did:key:z6MkhaXgBZDv...',
490
- projectId: 'none',
491
- cacheTtlMs: 300000,
492
- cacheExpiresAt: '2025-11-22T05:00:10.863Z'
493
- }
494
-
495
- stdout | src/__tests__/services/tool-protection.service.test.ts > ToolProtectionService > getToolProtectionConfig > edge cases > should handle null requiredScopes
496
- [ToolProtectionService] Config loaded from API {
497
- source: 'api',
498
- toolCount: 1,
499
- protectedTools: [ 'tool1' ],
500
- agentDid: 'did:key:z6MkhaXgBZDv...',
501
- projectId: 'none',
502
- cacheTtlMs: 300000,
503
- cacheExpiresAt: '2025-11-22T05:00:10.863Z'
504
- }
505
-
506
- stdout | src/__tests__/services/tool-protection.service.test.ts > ToolProtectionService > getToolProtectionConfig > edge cases > should handle mixed camelCase and snake_case in response
507
- [ToolProtectionService] Config loaded from API {
508
- source: 'api',
509
- toolCount: 2,
510
- protectedTools: [ 'tool1' ],
511
- agentDid: 'did:key:z6MkhaXgBZDv...',
512
- projectId: 'none',
513
- cacheTtlMs: 300000,
514
- cacheExpiresAt: '2025-11-22T05:00:10.863Z'
515
- }
516
-
517
- stdout | src/__tests__/services/tool-protection.service.test.ts > ToolProtectionService > checkToolProtection > should return null when tool has no protection
518
- [ToolProtectionService] Config loaded from API {
519
- source: 'api',
520
- toolCount: 1,
521
- protectedTools: [],
522
- agentDid: 'did:key:z6MkhaXgBZDv...',
523
- projectId: 'none',
524
- cacheTtlMs: 300000,
525
- cacheExpiresAt: '2025-11-22T05:00:10.864Z'
526
- }
527
-
528
- stdout | src/__tests__/services/tool-protection.service.test.ts > ToolProtectionService > checkToolProtection > should return null when tool is not in config
529
- [ToolProtectionService] Config loaded from API {
530
- source: 'api',
531
- toolCount: 1,
532
- protectedTools: [ 'other_tool' ],
533
- agentDid: 'did:key:z6MkhaXgBZDv...',
534
- projectId: 'none',
535
- cacheTtlMs: 300000,
536
- cacheExpiresAt: '2025-11-22T05:00:10.864Z'
537
- }
538
-
539
- stdout | src/__tests__/services/tool-protection.service.test.ts > ToolProtectionService > checkToolProtection > should return null when tool is not in config
540
- [ToolProtectionService] Protection check {
541
- tool: 'unknown_tool',
542
- agentDid: 'did:key:z6MkhaXgBZDv...',
543
- found: false,
544
- isWildcard: true,
545
- requiresDelegation: false,
546
- availableTools: [ 'other_tool' ]
547
- }
548
-
549
- stdout | src/__tests__/services/tool-protection.service.test.ts > ToolProtectionService > checkToolProtection > should return wildcard protection when tool not found and wildcard exists
550
- [ToolProtectionService] Config loaded from API {
551
- source: 'api',
552
- toolCount: 2,
553
- protectedTools: [ '*' ],
554
- agentDid: 'did:key:z6MkhaXgBZDv...',
555
- projectId: 'none',
556
- cacheTtlMs: 300000,
557
- cacheExpiresAt: '2025-11-22T05:00:10.865Z'
558
- }
559
-
560
- stdout | src/__tests__/services/tool-protection.service.test.ts > ToolProtectionService > checkToolProtection > should return wildcard protection when tool not found and wildcard exists
561
- [ToolProtectionService] Protection check {
562
- tool: 'unknown_tool',
563
- agentDid: 'did:key:z6MkhaXgBZDv...',
564
- found: true,
565
- isWildcard: true,
566
- requiresDelegation: true,
567
- availableTools: [ '*', 'specific_tool' ]
568
- }
569
-
570
- stdout | src/__tests__/services/tool-protection.service.test.ts > ToolProtectionService > checkToolProtection > should prioritize specific tool protection over wildcard
571
- [ToolProtectionService] Config loaded from API {
572
- source: 'api',
573
- toolCount: 2,
574
- protectedTools: [ '*' ],
575
- agentDid: 'did:key:z6MkhaXgBZDv...',
576
- projectId: 'none',
577
- cacheTtlMs: 300000,
578
- cacheExpiresAt: '2025-11-22T05:00:10.865Z'
579
- }
580
-
581
-
582
-  ❯ src/__tests__/cache/tool-protection-cache.test.ts 1/49
583
-  ❯ src/__tests__/runtime/route-interception.test.ts [queued]
584
-  ❯ src/__tests__/runtime/tool-protection-enforcement.test.ts [queued]
585
-  ❯ src/__tests__/services/agentshield-integration.test.ts 0/30
586
-  ❯ src/__tests__/services/provider-resolver-edge-cases.test.ts [queued]
587
-  ❯ src/__tests__/services/tool-protection.service.test.ts 49/49
588
-  ❯ src/delegation/__tests__/vc-issuer.test.ts 0/21
589
-  ❯ src/delegation/__tests__/vc-verifier.test.ts 0/35
590
-  ❯ src/services/__tests__/access-control.integration.test.ts [queued]
591
-  ❯ src/services/__tests__/access-control.service.test.ts 23/23
592
-  ❯ src/services/__tests__/crypto.service.test.ts 34/34
593
-  ❯ src/services/__tests__/proof-verifier.integration.test.ts [queued]
594
-  ❯ src/services/__tests__/storage.service.test.ts 17/17
595
-
596
-  Test Files 4 passed (43)
597
-  Tests 124 passed (258)
598
-  Start at 22:55:10
599
-  Duration 402ms
600
- [?2026l[?2026hstderr | src/__tests__/services/tool-protection.service.test.ts > ToolProtectionService > checkToolProtection > should use wildcard protection in fail-safe deny-all mode
601
- [ToolProtectionService] API fetch failed, no fallback, failing closed (deny-all) {
602
- agentDid: 'did:key:z6MkhaXgBZDv...',
603
- error: 'Network error',
604
- cacheKey: 'agent:did:key:z6MkhaXgBZDvotDkL5257faiztiGiC2QtKLGpbnnEGta2doK'
605
- }
606
-
607
-
608
-  ❯ src/__tests__/cache/tool-protection-cache.test.ts 1/49
609
-  ❯ src/__tests__/runtime/route-interception.test.ts [queued]
610
-  ❯ src/__tests__/runtime/tool-protection-enforcement.test.ts [queued]
611
-  ❯ src/__tests__/services/agentshield-integration.test.ts 0/30
612
-  ❯ src/__tests__/services/provider-resolver-edge-cases.test.ts [queued]
613
-  ❯ src/__tests__/services/tool-protection.service.test.ts 49/49
614
-  ❯ src/delegation/__tests__/vc-issuer.test.ts 0/21
615
-  ❯ src/delegation/__tests__/vc-verifier.test.ts 0/35
616
-  ❯ src/services/__tests__/access-control.integration.test.ts [queued]
617
-  ❯ src/services/__tests__/access-control.service.test.ts 23/23
618
-  ❯ src/services/__tests__/crypto.service.test.ts 34/34
619
-  ❯ src/services/__tests__/proof-verifier.integration.test.ts [queued]
620
-  ❯ src/services/__tests__/storage.service.test.ts 17/17
621
-
622
-  Test Files 4 passed (43)
623
-  Tests 124 passed (258)
624
-  Start at 22:55:10
625
-  Duration 402ms
626
- [?2026l[?2026hstdout | src/__tests__/services/tool-protection.service.test.ts > ToolProtectionService > checkToolProtection > should use wildcard protection in fail-safe deny-all mode
627
- [ToolProtectionService] Protection check {
628
- tool: 'any_tool',
629
- agentDid: 'did:key:z6MkhaXgBZDv...',
630
- found: true,
631
- isWildcard: true,
632
- requiresDelegation: true,
633
- availableTools: [ '*' ]
634
- }
635
-
636
- stdout | src/__tests__/services/tool-protection.service.test.ts > ToolProtectionService > checkToolProtection > should return protection config when tool requires delegation
637
- [ToolProtectionService] Config loaded from API {
638
- source: 'api',
639
- toolCount: 1,
640
- protectedTools: [ 'protected_tool' ],
641
- agentDid: 'did:key:z6MkhaXgBZDv...',
642
- projectId: 'none',
643
- cacheTtlMs: 300000,
644
- cacheExpiresAt: '2025-11-22T05:00:10.865Z'
645
- }
646
-
647
- stdout | src/__tests__/services/tool-protection.service.test.ts > ToolProtectionService > checkToolProtection > should return protection config when tool requires delegation
648
- [ToolProtectionService] Protection check {
649
- tool: 'protected_tool',
650
- agentDid: 'did:key:z6MkhaXgBZDv...',
651
- found: true,
652
- isWildcard: false,
653
- requiresDelegation: true,
654
- availableTools: [ 'protected_tool' ]
655
- }
656
-
657
-
658
-  ❯ src/__tests__/cache/tool-protection-cache.test.ts 1/49
659
-  ❯ src/__tests__/runtime/route-interception.test.ts [queued]
660
-  ❯ src/__tests__/runtime/tool-protection-enforcement.test.ts [queued]
661
-  ❯ src/__tests__/services/agentshield-integration.test.ts 0/30
662
-  ❯ src/__tests__/services/provider-resolver-edge-cases.test.ts [queued]
663
-  ❯ src/__tests__/services/tool-protection.service.test.ts 49/49
664
-  ❯ src/delegation/__tests__/vc-issuer.test.ts 0/21
665
-  ❯ src/delegation/__tests__/vc-verifier.test.ts 0/35
666
-  ❯ src/services/__tests__/access-control.integration.test.ts [queued]
667
-  ❯ src/services/__tests__/access-control.service.test.ts 23/23
668
-  ❯ src/services/__tests__/crypto.service.test.ts 34/34
669
-  ❯ src/services/__tests__/proof-verifier.integration.test.ts [queued]
670
-  ❯ src/services/__tests__/storage.service.test.ts 17/17
671
-
672
-  Test Files 4 passed (43)
673
-  Tests 124 passed (258)
674
-  Start at 22:55:10
675
-  Duration 402ms
676
- [?2026l[?2026hstderr | src/services/__tests__/storage.service.test.ts > StorageService > createStorageProviders > should prefer Redis over KV when both are configured
677
- [StorageService] Failed to connect to Redis, falling back to memory: Redis package not available
678
-
679
-
680
-  ❯ src/__tests__/cache/tool-protection-cache.test.ts 1/49
681
-  ❯ src/__tests__/runtime/route-interception.test.ts [queued]
682
-  ❯ src/__tests__/runtime/tool-protection-enforcement.test.ts [queued]
683
-  ❯ src/__tests__/services/agentshield-integration.test.ts 0/30
684
-  ❯ src/__tests__/services/provider-resolver-edge-cases.test.ts [queued]
685
-  ❯ src/__tests__/services/tool-protection.service.test.ts 49/49
686
-  ❯ src/delegation/__tests__/vc-issuer.test.ts 0/21
687
-  ❯ src/delegation/__tests__/vc-verifier.test.ts 0/35
688
-  ❯ src/services/__tests__/access-control.integration.test.ts [queued]
689
-  ❯ src/services/__tests__/access-control.service.test.ts 23/23
690
-  ❯ src/services/__tests__/crypto.service.test.ts 34/34
691
-  ❯ src/services/__tests__/proof-verifier.integration.test.ts [queued]
692
-  ❯ src/services/__tests__/storage.service.test.ts 17/17
693
-
694
-  Test Files 4 passed (43)
695
-  Tests 124 passed (258)
696
-  Start at 22:55:10
697
-  Duration 402ms
698
- [?2026l[?2026hstdout | src/__tests__/services/tool-protection.service.test.ts > ToolProtectionService > integration with NoOpToolProtectionCache > should work with NoOpToolProtectionCache
699
- [ToolProtectionService] Config loaded from API {
700
- source: 'api',
701
- toolCount: 1,
702
- protectedTools: [ 'tool1' ],
703
- agentDid: 'did:key:z6MkhaXgBZDv...',
704
- projectId: 'none',
705
- cacheTtlMs: 300000,
706
- cacheExpiresAt: '2025-11-22T05:00:10.866Z'
707
- }
708
-
709
- stdout | src/__tests__/services/tool-protection.service.test.ts > ToolProtectionService > integration with NoOpToolProtectionCache > should work with NoOpToolProtectionCache
710
- [ToolProtectionService] Config loaded from API {
711
- source: 'api',
712
- toolCount: 1,
713
- protectedTools: [ 'tool1' ],
714
- agentDid: 'did:key:z6MkhaXgBZDv...',
715
- projectId: 'none',
716
- cacheTtlMs: 300000,
717
- cacheExpiresAt: '2025-11-22T05:00:10.866Z'
718
- }
719
-
720
-
721
-  ❯ src/__tests__/cache/tool-protection-cache.test.ts 1/49
722
-  ❯ src/__tests__/runtime/route-interception.test.ts [queued]
723
-  ❯ src/__tests__/runtime/tool-protection-enforcement.test.ts [queued]
724
-  ❯ src/__tests__/services/agentshield-integration.test.ts 0/30
725
-  ❯ src/__tests__/services/provider-resolver-edge-cases.test.ts [queued]
726
-  ❯ src/__tests__/services/tool-protection.service.test.ts 49/49
727
-  ❯ src/delegation/__tests__/vc-issuer.test.ts 0/21
728
-  ❯ src/delegation/__tests__/vc-verifier.test.ts 0/35
729
-  ❯ src/services/__tests__/access-control.integration.test.ts [queued]
730
-  ❯ src/services/__tests__/access-control.service.test.ts 23/23
731
-  ❯ src/services/__tests__/crypto.service.test.ts 34/34
732
-  ❯ src/services/__tests__/proof-verifier.integration.test.ts [queued]
733
-  ❯ src/services/__tests__/storage.service.test.ts 17/17
734
-
735
-  Test Files 4 passed (43)
736
-  Tests 124 passed (258)
737
-  Start at 22:55:10
738
-  Duration 402ms
739
- [?2026l[?2026hstderr | src/services/__tests__/access-control.service.test.ts > AccessControlApiService > submitProofs > should submit proofs successfully
740
- [AccessControl] 🔍 RAW API RESPONSE (before parsing): {
741
- correlationId: '1ca9d6c3-6d96-4d12-96cc-ffe44342ccc3',
742
- status: 200,
743
- statusText: '',
744
- headers: { 'content-type': 'application/json' },
745
- responseTextLength: 100,
746
- responseTextPreview: '{"success":true,"accepted":1,"rejected":0,"outcomes":{"success":1,"failed":0,"blocked":0,"error":0}}',
747
- fullResponseText: '{"success":true,"accepted":1,"rejected":0,"outcomes":{"success":1,"failed":0,"blocked":0,"error":0}}'
748
- }
749
- [AccessControl] 🔍 PARSED RESPONSE DATA: {
750
- correlationId: '1ca9d6c3-6d96-4d12-96cc-ffe44342ccc3',
751
- status: 200,
752
- responseDataType: 'object',
753
- responseDataKeys: [ 'success', 'accepted', 'rejected', 'outcomes' ],
754
- responseData: '{\n' +
755
- ' "success": true,\n' +
756
- ' "accepted": 1,\n' +
757
- ' "rejected": 0,\n' +
758
- ' "outcomes": {\n' +
759
- ' "success": 1,\n' +
760
- ' "failed": 0,\n' +
761
- ' "blocked": 0,\n' +
762
- ' "error": 0\n' +
763
- ' }\n' +
764
- '}'
765
- }
766
- [AccessControl] Raw response received: {
767
- "success": true,
768
- "accepted": 1,
769
- "rejected": 0,
770
- "outcomes": {
771
- "success": 1,
772
- "failed": 0,
773
- "blocked": 0,
774
- "error": 0
775
- }
776
- }
777
-
778
- stderr | src/services/__tests__/access-control.service.test.ts > AccessControlApiService > submitProofs > should handle all_proofs_rejected error gracefully
779
- [AccessControl] 🔍 RAW API RESPONSE (before parsing): {
780
- correlationId: 'd3b5a466-44b5-4a00-8873-742a20888891',
781
- status: 400,
782
- statusText: '',
783
- headers: { 'content-type': 'application/json' },
784
- responseTextLength: 209,
785
- responseTextPreview: '{"success":false,"error":{"code":"all_proofs_rejected","message":"All proofs rejected","details":{"rejected":1,"errors":[{"proof_index":0,"error":{"code":"invalid_signature","message":"Invalid signature"}}]}}}',
786
- fullResponseText: '{"success":false,"error":{"code":"all_proofs_rejected","message":"All proofs rejected","details":{"rejected":1,"errors":[{"proof_index":0,"error":{"code":"invalid_signature","message":"Invalid signature"}}]}}}'
787
- }
788
- [AccessControl] 🔍 PARSED RESPONSE DATA: {
789
- correlationId: 'd3b5a466-44b5-4a00-8873-742a20888891',
790
- status: 400,
791
- responseDataType: 'object',
792
- responseDataKeys: [ 'success', 'error' ],
793
- responseData: '{\n' +
794
- ' "success": false,\n' +
795
- ' "error": {\n' +
796
- ' "code": "all_proofs_rejected",\n' +
797
- ' "message": "All proofs rejected",\n' +
798
- ' "details": {\n' +
799
- ' "rejected": 1,\n' +
800
- ' "errors": [\n' +
801
- ' {\n' +
802
- ' "proof_index": 0,\n' +
803
- ' "error": {\n' +
804
- ' "code": "invalid_signature",\n' +
805
- ' "message": "Invalid signature"\n' +
806
- ' }\n' +
807
- ' }\n' +
808
- ' ]\n' +
809
- ' }\n' +
810
- ' }\n' +
811
- '}'
812
- }
813
-
814
- stderr | src/services/__tests__/storage.service.test.ts > StorageService > createStorageProviders > should prefer Redis over KV when both are configured
815
- [StorageService] Failed to initialize KV, falling back to memory: Failed to import Cloudflare storage providers: Cannot find package '@kya-os/mcp-i-cloudflare/providers/storage' imported from '/Users/dylanhobbs/Documents/@kya-os/xmcp-i/packages/mcp-i-core/src/services/storage.service.ts'
816
-
817
- stderr | src/services/__tests__/access-control.service.test.ts > AccessControlApiService > submitProofs > should handle wrapped response format
818
- [AccessControl] 🔍 RAW API RESPONSE (before parsing): {
819
- correlationId: 'cc1ac72c-9755-4b10-89d4-636d8cf48144',
820
- status: 200,
821
- statusText: '',
822
- headers: { 'content-type': 'application/json' },
823
- responseTextLength: 206,
824
- responseTextPreview: '{"success":true,"data":{"success":true,"accepted":1,"rejected":0,"outcomes":{"success":1,"failed":0,"blocked":0,"error":0}},"metadata":{"requestId":"test-request-id","timestamp":"2025-11-22T04:55:10.868Z"}}',
825
- fullResponseText: '{"success":true,"data":{"success":true,"accepted":1,"rejected":0,"outcomes":{"success":1,"failed":0,"blocked":0,"error":0}},"metadata":{"requestId":"test-request-id","timestamp":"2025-11-22T04:55:10.868Z"}}'
826
- }
827
- [AccessControl] 🔍 PARSED RESPONSE DATA: {
828
- correlationId: 'cc1ac72c-9755-4b10-89d4-636d8cf48144',
829
- status: 200,
830
- responseDataType: 'object',
831
- responseDataKeys: [ 'success', 'data', 'metadata' ],
832
- responseData: '{\n' +
833
- ' "success": true,\n' +
834
- ' "data": {\n' +
835
- ' "success": true,\n' +
836
- ' "accepted": 1,\n' +
837
- ' "rejected": 0,\n' +
838
- ' "outcomes": {\n' +
839
- ' "success": 1,\n' +
840
- ' "failed": 0,\n' +
841
- ' "blocked": 0,\n' +
842
- ' "error": 0\n' +
843
- ' }\n' +
844
- ' },\n' +
845
- ' "metadata": {\n' +
846
- ' "requestId": "test-request-id",\n' +
847
- ' "timestamp": "2025-11-22T04:55:10.868Z"\n' +
848
- ' }\n' +
849
- '}'
850
- }
851
- [AccessControl] Raw response received: {
852
- "success": true,
853
- "data": {
854
- "success": true,
855
- "accepted": 1,
856
- "rejected": 0,
857
- "outcomes": {
858
- "success": 1,
859
- "failed": 0,
860
- "blocked": 0,
861
- "error": 0
862
- }
863
- },
864
- "metadata": {
865
- "requestId": "test-request-id",
866
- "timestamp": "2025-11-22T04:55:10.868Z"
867
- }
868
- }
869
- [AccessControl] 🔍 DATA OBJECT STRUCTURE: {
870
- correlationId: 'cc1ac72c-9755-4b10-89d4-636d8cf48144',
871
- dataKeys: [ 'success', 'accepted', 'rejected', 'outcomes' ],
872
- hasAccepted: true,
873
- hasRejected: true,
874
- hasOutcomes: true,
875
- hasErrors: false,
876
- acceptedType: 'number',
877
- rejectedType: 'number',
878
- outcomesType: 'object',
879
- errorsType: 'undefined',
880
- errorsIsArray: false,
881
- fullData: '{\n' +
882
- ' "success": true,\n' +
883
- ' "accepted": 1,\n' +
884
- ' "rejected": 0,\n' +
885
- ' "outcomes": {\n' +
886
- ' "success": 1,\n' +
887
- ' "failed": 0,\n' +
888
- ' "blocked": 0,\n' +
889
- ' "error": 0\n' +
890
- ' }\n' +
891
- '}'
892
- }
893
-
894
- stderr | src/services/__tests__/access-control.service.test.ts > AccessControlApiService > submitProofs > should handle response with missing outcomes field (outcomes is optional)
895
- [AccessControl] 🔍 RAW API RESPONSE (before parsing): {
896
- correlationId: '84dad0f8-bea5-42d9-9d9c-428355d364da',
897
- status: 200,
898
- statusText: '',
899
- headers: { 'content-type': 'application/json' },
900
- responseTextLength: 42,
901
- responseTextPreview: '{"success":true,"accepted":1,"rejected":0}',
902
- fullResponseText: '{"success":true,"accepted":1,"rejected":0}'
903
- }
904
- [AccessControl] 🔍 PARSED RESPONSE DATA: {
905
- correlationId: '84dad0f8-bea5-42d9-9d9c-428355d364da',
906
- status: 200,
907
- responseDataType: 'object',
908
- responseDataKeys: [ 'success', 'accepted', 'rejected' ],
909
- responseData: '{\n "success": true,\n "accepted": 1,\n "rejected": 0\n}'
910
- }
911
- [AccessControl] Raw response received: {
912
- "success": true,
913
- "accepted": 1,
914
- "rejected": 0
915
- }
916
-
917
- stderr | src/services/__tests__/access-control.service.test.ts > AccessControlApiService > submitProofs > should handle response with missing outcomes field (outcomes is optional)
918
- [AccessControl] 🔍 RAW API RESPONSE (before parsing): {
919
- correlationId: '8f2d3cae-5ad0-4943-8ddf-1eb9e2aef62a',
920
- status: 200,
921
- statusText: '',
922
- headers: { 'content-type': 'application/json' },
923
- responseTextLength: 100,
924
- responseTextPreview: '{"success":true,"accepted":1,"rejected":0,"outcomes":{"success":1,"failed":0,"blocked":0,"error":0}}',
925
- fullResponseText: '{"success":true,"accepted":1,"rejected":0,"outcomes":{"success":1,"failed":0,"blocked":0,"error":0}}'
926
- }
927
- [AccessControl] 🔍 PARSED RESPONSE DATA: {
928
- correlationId: '8f2d3cae-5ad0-4943-8ddf-1eb9e2aef62a',
929
- status: 200,
930
- responseDataType: 'object',
931
- responseDataKeys: [ 'success', 'accepted', 'rejected', 'outcomes' ],
932
- responseData: '{\n' +
933
- ' "success": true,\n' +
934
- ' "accepted": 1,\n' +
935
- ' "rejected": 0,\n' +
936
- ' "outcomes": {\n' +
937
- ' "success": 1,\n' +
938
- ' "failed": 0,\n' +
939
- ' "blocked": 0,\n' +
940
- ' "error": 0\n' +
941
- ' }\n' +
942
- '}'
943
- }
944
- [AccessControl] Raw response received: {
945
- "success": true,
946
- "accepted": 1,
947
- "rejected": 0,
948
- "outcomes": {
949
- "success": 1,
950
- "failed": 0,
951
- "blocked": 0,
952
- "error": 0
953
- }
954
- }
955
-
956
- stderr | src/services/__tests__/access-control.service.test.ts > AccessControlApiService > submitProofs > should handle response with missing outcomes field (outcomes is optional)
957
- [AccessControl] 🔍 RAW API RESPONSE (before parsing): {
958
- correlationId: '9aaa68be-ba0e-4a1c-b1d2-a88aea65ece2',
959
- status: 200,
960
- statusText: '',
961
- headers: { 'content-type': 'application/json' },
962
- responseTextLength: 56,
963
- responseTextPreview: '{"success":true,"accepted":1,"rejected":0,"outcomes":{}}',
964
- fullResponseText: '{"success":true,"accepted":1,"rejected":0,"outcomes":{}}'
965
- }
966
- [AccessControl] 🔍 PARSED RESPONSE DATA: {
967
- correlationId: '9aaa68be-ba0e-4a1c-b1d2-a88aea65ece2',
968
- status: 200,
969
- responseDataType: 'object',
970
- responseDataKeys: [ 'success', 'accepted', 'rejected', 'outcomes' ],
971
- responseData: '{\n "success": true,\n "accepted": 1,\n "rejected": 0,\n "outcomes": {}\n}'
972
- }
973
- [AccessControl] Raw response received: {
974
- "success": true,
975
- "accepted": 1,
976
- "rejected": 0,
977
- "outcomes": {}
978
- }
979
-
980
- stderr | src/services/__tests__/access-control.service.test.ts > AccessControlApiService > submitProofs > should handle wrapped response with invalid data structure
981
- [AccessControl] 🔍 RAW API RESPONSE (before parsing): {
982
- correlationId: '9eecca9a-ffd6-4558-8e7d-5258efb887b6',
983
- status: 200,
984
- statusText: '',
985
- headers: { 'content-type': 'application/json' },
986
- responseTextLength: 52,
987
- responseTextPreview: '{"success":true,"data":{"message":"Invalid format"}}',
988
- fullResponseText: '{"success":true,"data":{"message":"Invalid format"}}'
989
- }
990
- [AccessControl] 🔍 PARSED RESPONSE DATA: {
991
- correlationId: '9eecca9a-ffd6-4558-8e7d-5258efb887b6',
992
- status: 200,
993
- responseDataType: 'object',
994
- responseDataKeys: [ 'success', 'data' ],
995
- responseData: '{\n "success": true,\n "data": {\n "message": "Invalid format"\n }\n}'
996
- }
997
- [AccessControl] Raw response received: {
998
- "success": true,
999
- "data": {
1000
- "message": "Invalid format"
1001
- }
1002
- }
1003
- [AccessControl] 🔍 DATA OBJECT STRUCTURE: {
1004
- correlationId: '9eecca9a-ffd6-4558-8e7d-5258efb887b6',
1005
- dataKeys: [ 'message' ],
1006
- hasAccepted: false,
1007
- hasRejected: false,
1008
- hasOutcomes: false,
1009
- hasErrors: false,
1010
- acceptedType: 'undefined',
1011
- rejectedType: 'undefined',
1012
- outcomesType: 'undefined',
1013
- errorsType: 'undefined',
1014
- errorsIsArray: false,
1015
- fullData: '{\n "message": "Invalid format"\n}'
1016
- }
1017
- [AccessControl] Wrapped response validation failed {
1018
- correlationId: '9eecca9a-ffd6-4558-8e7d-5258efb887b6',
1019
- zodErrors: [
1020
- {
1021
- code: 'invalid_type',
1022
- expected: 'number',
1023
- received: 'undefined',
1024
- path: [Array],
1025
- message: 'Required'
1026
- },
1027
- {
1028
- code: 'invalid_type',
1029
- expected: 'number',
1030
- received: 'undefined',
1031
- path: [Array],
1032
- message: 'Required'
1033
- }
1034
- ],
1035
- zodErrorDetails: '[\n' +
1036
- ' {\n' +
1037
- ' "code": "invalid_type",\n' +
1038
- ' "expected": "number",\n' +
1039
- ' "received": "undefined",\n' +
1040
- ' "path": [\n' +
1041
- ' "accepted"\n' +
1042
- ' ],\n' +
1043
- ' "message": "Required"\n' +
1044
- ' },\n' +
1045
- ' {\n' +
1046
- ' "code": "invalid_type",\n' +
1047
- ' "expected": "number",\n' +
1048
- ' "received": "undefined",\n' +
1049
- ' "path": [\n' +
1050
- ' "rejected"\n' +
1051
- ' ],\n' +
1052
- ' "message": "Required"\n' +
1053
- ' }\n' +
1054
- ']',
1055
- dataToValidate: '{\n "message": "Invalid format"\n}',
1056
- dataWithSuccess: '{\n "message": "Invalid format",\n "success": true\n}',
1057
- dataKeys: [ 'message' ],
1058
- originalResponse: '{\n "success": true,\n "data": {\n "message": "Invalid format"\n }\n}'
1059
- }
1060
- [AccessControl] Original wrapped response: {
1061
- "success": true,
1062
- "data": {
1063
- "message": "Invalid format"
1064
- }
1065
- }
1066
- [AccessControl] ❌ ZOD VALIDATION FAILED - 2 error(s):
1067
- [AccessControl] Error 1: {
1068
- path: 'accepted',
1069
- message: 'Required',
1070
- code: 'invalid_type',
1071
- received: 'undefined',
1072
- expected: 'number'
1073
- }
1074
- [AccessControl] Error 2: {
1075
- path: 'rejected',
1076
- message: 'Required',
1077
- code: 'invalid_type',
1078
- received: 'undefined',
1079
- expected: 'number'
1080
- }
1081
- [AccessControl] ❌ Full ZOD errors JSON: [
1082
- {
1083
- "code": "invalid_type",
1084
- "expected": "number",
1085
- "received": "undefined",
1086
- "path": [
1087
- "accepted"
1088
- ],
1089
- "message": "Required"
1090
- },
1091
- {
1092
- "code": "invalid_type",
1093
- "expected": "number",
1094
- "received": "undefined",
1095
- "path": [
1096
- "rejected"
1097
- ],
1098
- "message": "Required"
1099
- }
1100
- ]
1101
- [AccessControl] Response validation failed {
1102
- zodErrors: [
1103
- {
1104
- code: 'invalid_type',
1105
- expected: 'number',
1106
- received: 'undefined',
1107
- path: [Array],
1108
- message: 'Required'
1109
- },
1110
- {
1111
- code: 'invalid_type',
1112
- expected: 'number',
1113
- received: 'undefined',
1114
- path: [Array],
1115
- message: 'Required'
1116
- }
1117
- ],
1118
- responseData: { success: true, data: { message: 'Invalid format' } }
1119
- }
1120
- [AccessControl] Response validation failed {
1121
- correlationId: '9eecca9a-ffd6-4558-8e7d-5258efb887b6',
1122
- zodErrors: [
1123
- {
1124
- code: 'invalid_type',
1125
- expected: 'number',
1126
- received: 'undefined',
1127
- path: [Array],
1128
- message: 'Required'
1129
- },
1130
- {
1131
- code: 'invalid_type',
1132
- expected: 'number',
1133
- received: 'undefined',
1134
- path: [Array],
1135
- message: 'Required'
1136
- }
1137
- ],
1138
- zodErrorDetails: '[\n' +
1139
- ' {\n' +
1140
- ' "code": "invalid_type",\n' +
1141
- ' "expected": "number",\n' +
1142
- ' "received": "undefined",\n' +
1143
- ' "path": [\n' +
1144
- ' "accepted"\n' +
1145
- ' ],\n' +
1146
- ' "message": "Required"\n' +
1147
- ' },\n' +
1148
- ' {\n' +
1149
- ' "code": "invalid_type",\n' +
1150
- ' "expected": "number",\n' +
1151
- ' "received": "undefined",\n' +
1152
- ' "path": [\n' +
1153
- ' "rejected"\n' +
1154
- ' ],\n' +
1155
- ' "message": "Required"\n' +
1156
- ' }\n' +
1157
- ']',
1158
- responseData: '{\n "success": true,\n "data": {\n "message": "Invalid format"\n }\n}',
1159
- responseDataType: 'object',
1160
- responseKeys: [ 'success', 'data' ],
1161
- httpStatus: 200,
1162
- httpStatusText: ''
1163
- }
1164
- [AccessControl] ❌ ZOD VALIDATION FAILED (direct) - 2 error(s):
1165
- [AccessControl] Error 1: {
1166
- path: 'accepted',
1167
- message: 'Required',
1168
- code: 'invalid_type',
1169
- received: 'undefined',
1170
- expected: 'number'
1171
- }
1172
- [AccessControl] Error 2: {
1173
- path: 'rejected',
1174
- message: 'Required',
1175
- code: 'invalid_type',
1176
- received: 'undefined',
1177
- expected: 'number'
1178
- }
1179
- [AccessControl] ❌ Full ZOD errors JSON: [
1180
- {
1181
- "code": "invalid_type",
1182
- "expected": "number",
1183
- "received": "undefined",
1184
- "path": [
1185
- "accepted"
1186
- ],
1187
- "message": "Required"
1188
- },
1189
- {
1190
- "code": "invalid_type",
1191
- "expected": "number",
1192
- "received": "undefined",
1193
- "path": [
1194
- "rejected"
1195
- ],
1196
- "message": "Required"
1197
- }
1198
- ]
1199
- [AccessControl] ❌ ACTUAL RESPONSE DATA: {
1200
- "success": true,
1201
- "data": {
1202
- "message": "Invalid format"
1203
- }
1204
- }
1205
-
1206
- stderr | src/services/__tests__/storage.service.test.ts > StorageService > createStorageProviders > should fall back to memory when Redis connection fails
1207
- [StorageService] Failed to connect to Redis, falling back to memory: Redis package not available
1208
-
1209
- stderr | src/services/__tests__/crypto.service.test.ts > CryptoService > verifyEd25519 > should return false on verification error
1210
- [CryptoService] Ed25519 verification error: Error: Verification failed
1211
- at /Users/dylanhobbs/Documents/@kya-os/xmcp-i/packages/mcp-i-core/src/services/__tests__/crypto.service.test.ts:62:9
1212
- at file:///Users/dylanhobbs/Documents/@kya-os/xmcp-i/node_modules/.pnpm/@vitest+runner@4.0.5/node_modules/@vitest/runner/dist/index.js:157:11
1213
- at file:///Users/dylanhobbs/Documents/@kya-os/xmcp-i/node_modules/.pnpm/@vitest+runner@4.0.5/node_modules/@vitest/runner/dist/index.js:753:26
1214
- at file:///Users/dylanhobbs/Documents/@kya-os/xmcp-i/node_modules/.pnpm/@vitest+runner@4.0.5/node_modules/@vitest/runner/dist/index.js:1636:20
1215
- at new Promise (<anonymous>)
1216
- at runWithTimeout (file:///Users/dylanhobbs/Documents/@kya-os/xmcp-i/node_modules/.pnpm/@vitest+runner@4.0.5/node_modules/@vitest/runner/dist/index.js:1602:10)
1217
- at runTest (file:///Users/dylanhobbs/Documents/@kya-os/xmcp-i/node_modules/.pnpm/@vitest+runner@4.0.5/node_modules/@vitest/runner/dist/index.js:1309:12)
1218
-  at processTicksAndRejections (node:internal/process/task_queues:103:5)
1219
- at runSuite (file:///Users/dylanhobbs/Documents/@kya-os/xmcp-i/node_modules/.pnpm/@vitest+runner@4.0.5/node_modules/@vitest/runner/dist/index.js:1468:8)
1220
- at runSuite (file:///Users/dylanhobbs/Documents/@kya-os/xmcp-i/node_modules/.pnpm/@vitest+runner@4.0.5/node_modules/@vitest/runner/dist/index.js:1468:8)
1221
-
1222
- stderr | src/services/__tests__/crypto.service.test.ts > CryptoService > verifyJWS > should reject invalid JWK format
1223
- [CryptoService] Invalid Ed25519 JWK format
1224
-
1225
- stderr | src/services/__tests__/crypto.service.test.ts > CryptoService > verifyJWS > should reject JWK with wrong kty
1226
- [CryptoService] Invalid Ed25519 JWK format
1227
-
1228
- stderr | src/services/__tests__/crypto.service.test.ts > CryptoService > verifyJWS > should reject JWK with wrong crv
1229
- [CryptoService] Invalid Ed25519 JWK format
1230
-
1231
- stderr | src/services/__tests__/crypto.service.test.ts > CryptoService > verifyJWS > should reject JWK with missing x field
1232
- [CryptoService] Invalid Ed25519 JWK format
1233
-
1234
- stderr | src/services/__tests__/crypto.service.test.ts > CryptoService > verifyJWS > should reject JWK with empty x field
1235
- [CryptoService] Invalid Ed25519 JWK format
1236
-
1237
- stderr | src/services/__tests__/storage.service.test.ts > StorageService > createStorageProviders > should use KV namespace when provided
1238
- [StorageService] Failed to initialize KV, falling back to memory: Failed to import Cloudflare storage providers: Cannot find package '@kya-os/mcp-i-cloudflare/providers/storage' imported from '/Users/dylanhobbs/Documents/@kya-os/xmcp-i/packages/mcp-i-core/src/services/storage.service.ts'
1239
-
1240
- stderr | src/services/__tests__/crypto.service.test.ts > CryptoService > verifyJWS > should reject malformed JWS
1241
- [CryptoService] Invalid JWS format: Error: Invalid header base64: Unexpected token 'ž', "ž‹" is not valid JSON
1242
- at CryptoService.parseJWS (/Users/dylanhobbs/Documents/@kya-os/xmcp-i/packages/mcp-i-core/src/services/crypto.service.ts:91:13)
1243
- at CryptoService.verifyJWS (/Users/dylanhobbs/Documents/@kya-os/xmcp-i/packages/mcp-i-core/src/services/crypto.service.ts:169:23)
1244
- at /Users/dylanhobbs/Documents/@kya-os/xmcp-i/packages/mcp-i-core/src/services/__tests__/crypto.service.test.ts:230:42
1245
- at file:///Users/dylanhobbs/Documents/@kya-os/xmcp-i/node_modules/.pnpm/@vitest+runner@4.0.5/node_modules/@vitest/runner/dist/index.js:157:11
1246
- at file:///Users/dylanhobbs/Documents/@kya-os/xmcp-i/node_modules/.pnpm/@vitest+runner@4.0.5/node_modules/@vitest/runner/dist/index.js:753:26
1247
- at file:///Users/dylanhobbs/Documents/@kya-os/xmcp-i/node_modules/.pnpm/@vitest+runner@4.0.5/node_modules/@vitest/runner/dist/index.js:1636:20
1248
- at new Promise (<anonymous>)
1249
- at runWithTimeout (file:///Users/dylanhobbs/Documents/@kya-os/xmcp-i/node_modules/.pnpm/@vitest+runner@4.0.5/node_modules/@vitest/runner/dist/index.js:1602:10)
1250
- at runTest (file:///Users/dylanhobbs/Documents/@kya-os/xmcp-i/node_modules/.pnpm/@vitest+runner@4.0.5/node_modules/@vitest/runner/dist/index.js:1309:12)
1251
-  at processTicksAndRejections (node:internal/process/task_queues:103:5)
1252
-
1253
- stderr | src/services/__tests__/crypto.service.test.ts > CryptoService > verifyJWS > should reject non-EdDSA algorithms
1254
- [CryptoService] Unsupported algorithm: RS256, expected EdDSA
1255
-
1256
- stderr | src/services/__tests__/crypto.service.test.ts > CryptoService > verifyJWS > should reject HS256 algorithm
1257
- [CryptoService] Unsupported algorithm: HS256, expected EdDSA
1258
-
1259
- stderr | src/services/__tests__/crypto.service.test.ts > CryptoService > verifyJWS > should handle empty JWS components
1260
- [CryptoService] Invalid JWS format: Error: Invalid header base64: Unexpected end of JSON input
1261
- at CryptoService.parseJWS (/Users/dylanhobbs/Documents/@kya-os/xmcp-i/packages/mcp-i-core/src/services/crypto.service.ts:91:13)
1262
- at CryptoService.verifyJWS (/Users/dylanhobbs/Documents/@kya-os/xmcp-i/packages/mcp-i-core/src/services/crypto.service.ts:169:23)
1263
- at /Users/dylanhobbs/Documents/@kya-os/xmcp-i/packages/mcp-i-core/src/services/__tests__/crypto.service.test.ts:271:42
1264
- at file:///Users/dylanhobbs/Documents/@kya-os/xmcp-i/node_modules/.pnpm/@vitest+runner@4.0.5/node_modules/@vitest/runner/dist/index.js:157:11
1265
- at file:///Users/dylanhobbs/Documents/@kya-os/xmcp-i/node_modules/.pnpm/@vitest+runner@4.0.5/node_modules/@vitest/runner/dist/index.js:753:26
1266
- at file:///Users/dylanhobbs/Documents/@kya-os/xmcp-i/node_modules/.pnpm/@vitest+runner@4.0.5/node_modules/@vitest/runner/dist/index.js:1636:20
1267
- at new Promise (<anonymous>)
1268
- at runWithTimeout (file:///Users/dylanhobbs/Documents/@kya-os/xmcp-i/node_modules/.pnpm/@vitest+runner@4.0.5/node_modules/@vitest/runner/dist/index.js:1602:10)
1269
- at runTest (file:///Users/dylanhobbs/Documents/@kya-os/xmcp-i/node_modules/.pnpm/@vitest+runner@4.0.5/node_modules/@vitest/runner/dist/index.js:1309:12)
1270
-  at processTicksAndRejections (node:internal/process/task_queues:103:5)
1271
-
1272
- stderr | src/services/__tests__/crypto.service.test.ts > CryptoService > verifyJWS > should handle malformed JWS - single part
1273
- [CryptoService] Invalid JWS format: Error: Invalid JWS format: expected header.payload.signature
1274
- at CryptoService.parseJWS (/Users/dylanhobbs/Documents/@kya-os/xmcp-i/packages/mcp-i-core/src/services/crypto.service.ts:78:13)
1275
- at CryptoService.verifyJWS (/Users/dylanhobbs/Documents/@kya-os/xmcp-i/packages/mcp-i-core/src/services/crypto.service.ts:169:23)
1276
- at /Users/dylanhobbs/Documents/@kya-os/xmcp-i/packages/mcp-i-core/src/services/__tests__/crypto.service.test.ts:279:42
1277
- at file:///Users/dylanhobbs/Documents/@kya-os/xmcp-i/node_modules/.pnpm/@vitest+runner@4.0.5/node_modules/@vitest/runner/dist/index.js:157:11
1278
- at file:///Users/dylanhobbs/Documents/@kya-os/xmcp-i/node_modules/.pnpm/@vitest+runner@4.0.5/node_modules/@vitest/runner/dist/index.js:753:26
1279
- at file:///Users/dylanhobbs/Documents/@kya-os/xmcp-i/node_modules/.pnpm/@vitest+runner@4.0.5/node_modules/@vitest/runner/dist/index.js:1636:20
1280
- at new Promise (<anonymous>)
1281
- at runWithTimeout (file:///Users/dylanhobbs/Documents/@kya-os/xmcp-i/node_modules/.pnpm/@vitest+runner@4.0.5/node_modules/@vitest/runner/dist/index.js:1602:10)
1282
- at runTest (file:///Users/dylanhobbs/Documents/@kya-os/xmcp-i/node_modules/.pnpm/@vitest+runner@4.0.5/node_modules/@vitest/runner/dist/index.js:1309:12)
1283
-  at processTicksAndRejections (node:internal/process/task_queues:103:5)
1284
-
1285
- stderr | src/services/__tests__/crypto.service.test.ts > CryptoService > verifyJWS > should handle malformed JWS - two parts
1286
- [CryptoService] Invalid JWS format: Error: Invalid JWS format: expected header.payload.signature
1287
- at CryptoService.parseJWS (/Users/dylanhobbs/Documents/@kya-os/xmcp-i/packages/mcp-i-core/src/services/crypto.service.ts:78:13)
1288
- at CryptoService.verifyJWS (/Users/dylanhobbs/Documents/@kya-os/xmcp-i/packages/mcp-i-core/src/services/crypto.service.ts:169:23)
1289
- at /Users/dylanhobbs/Documents/@kya-os/xmcp-i/packages/mcp-i-core/src/services/__tests__/crypto.service.test.ts:287:42
1290
- at file:///Users/dylanhobbs/Documents/@kya-os/xmcp-i/node_modules/.pnpm/@vitest+runner@4.0.5/node_modules/@vitest/runner/dist/index.js:157:11
1291
- at file:///Users/dylanhobbs/Documents/@kya-os/xmcp-i/node_modules/.pnpm/@vitest+runner@4.0.5/node_modules/@vitest/runner/dist/index.js:753:26
1292
- at file:///Users/dylanhobbs/Documents/@kya-os/xmcp-i/node_modules/.pnpm/@vitest+runner@4.0.5/node_modules/@vitest/runner/dist/index.js:1636:20
1293
- at new Promise (<anonymous>)
1294
- at runWithTimeout (file:///Users/dylanhobbs/Documents/@kya-os/xmcp-i/node_modules/.pnpm/@vitest+runner@4.0.5/node_modules/@vitest/runner/dist/index.js:1602:10)
1295
- at runTest (file:///Users/dylanhobbs/Documents/@kya-os/xmcp-i/node_modules/.pnpm/@vitest+runner@4.0.5/node_modules/@vitest/runner/dist/index.js:1309:12)
1296
-  at processTicksAndRejections (node:internal/process/task_queues:103:5)
1297
-
1298
-
1299
-  ❯ src/__tests__/cache/tool-protection-cache.test.ts 1/49
1300
-  ❯ src/__tests__/runtime/route-interception.test.ts [queued]
1301
-  ❯ src/__tests__/runtime/tool-protection-enforcement.test.ts [queued]
1302
-  ❯ src/__tests__/services/agentshield-integration.test.ts 0/30
1303
-  ❯ src/__tests__/services/provider-resolver-edge-cases.test.ts [queued]
1304
-  ❯ src/__tests__/services/tool-protection.service.test.ts 49/49
1305
-  ❯ src/delegation/__tests__/vc-issuer.test.ts 0/21
1306
-  ❯ src/delegation/__tests__/vc-verifier.test.ts 0/35
1307
-  ❯ src/services/__tests__/access-control.integration.test.ts [queued]
1308
-  ❯ src/services/__tests__/access-control.service.test.ts 23/23
1309
-  ❯ src/services/__tests__/crypto.service.test.ts 34/34
1310
-  ❯ src/services/__tests__/proof-verifier.integration.test.ts [queued]
1311
-  ❯ src/services/__tests__/storage.service.test.ts 17/17
1312
-
1313
-  Test Files 4 passed (43)
1314
-  Tests 124 passed (258)
1315
-  Start at 22:55:10
1316
-  Duration 402ms
1317
- [?2026l[?2026h ✓ src/__tests__/services/tool-protection.service.test.ts (49 tests) 16ms
1318
-
1319
-  ❯ src/__tests__/cache/tool-protection-cache.test.ts 1/49
1320
-  ❯ src/__tests__/runtime/route-interception.test.ts [queued]
1321
-  ❯ src/__tests__/runtime/tool-protection-enforcement.test.ts [queued]
1322
-  ❯ src/__tests__/services/agentshield-integration.test.ts 0/30
1323
-  ❯ src/__tests__/services/provider-resolver-edge-cases.test.ts [queued]
1324
-  ❯ src/__tests__/services/tool-protection.service.test.ts 49/49
1325
-  ❯ src/delegation/__tests__/vc-issuer.test.ts 0/21
1326
-  ❯ src/delegation/__tests__/vc-verifier.test.ts 0/35
1327
-  ❯ src/services/__tests__/access-control.integration.test.ts [queued]
1328
-  ❯ src/services/__tests__/access-control.service.test.ts 23/23
1329
-  ❯ src/services/__tests__/crypto.service.test.ts 34/34
1330
-  ❯ src/services/__tests__/proof-verifier.integration.test.ts [queued]
1331
-  ❯ src/services/__tests__/storage.service.test.ts 17/17
1332
-
1333
-  Test Files 4 passed (43)
1334
-  Tests 124 passed (258)
1335
-  Start at 22:55:10
1336
-  Duration 402ms
1337
- [?2026l[?2026hstderr | src/services/__tests__/crypto.service.test.ts > CryptoService > verifyJWS > should handle malformed JWS - four parts
1338
- [CryptoService] Invalid JWS format: Error: Invalid JWS format: expected header.payload.signature
1339
- at CryptoService.parseJWS (/Users/dylanhobbs/Documents/@kya-os/xmcp-i/packages/mcp-i-core/src/services/crypto.service.ts:78:13)
1340
- at CryptoService.verifyJWS (/Users/dylanhobbs/Documents/@kya-os/xmcp-i/packages/mcp-i-core/src/services/crypto.service.ts:169:23)
1341
- at /Users/dylanhobbs/Documents/@kya-os/xmcp-i/packages/mcp-i-core/src/services/__tests__/crypto.service.test.ts:302:42
1342
- at file:///Users/dylanhobbs/Documents/@kya-os/xmcp-i/node_modules/.pnpm/@vitest+runner@4.0.5/node_modules/@vitest/runner/dist/index.js:157:11
1343
- at file:///Users/dylanhobbs/Documents/@kya-os/xmcp-i/node_modules/.pnpm/@vitest+runner@4.0.5/node_modules/@vitest/runner/dist/index.js:753:26
1344
- at file:///Users/dylanhobbs/Documents/@kya-os/xmcp-i/node_modules/.pnpm/@vitest+runner@4.0.5/node_modules/@vitest/runner/dist/index.js:1636:20
1345
- at new Promise (<anonymous>)
1346
- at runWithTimeout (file:///Users/dylanhobbs/Documents/@kya-os/xmcp-i/node_modules/.pnpm/@vitest+runner@4.0.5/node_modules/@vitest/runner/dist/index.js:1602:10)
1347
- at runTest (file:///Users/dylanhobbs/Documents/@kya-os/xmcp-i/node_modules/.pnpm/@vitest+runner@4.0.5/node_modules/@vitest/runner/dist/index.js:1309:12)
1348
-  at processTicksAndRejections (node:internal/process/task_queues:103:5)
1349
-
1350
- stderr | src/services/__tests__/crypto.service.test.ts > CryptoService > verifyJWS > should handle malformed JWS - invalid JSON header
1351
- [CryptoService] Invalid JWS format: Error: Invalid header base64: Unexpected token 'o', "notjson" is not valid JSON
1352
- at CryptoService.parseJWS (/Users/dylanhobbs/Documents/@kya-os/xmcp-i/packages/mcp-i-core/src/services/crypto.service.ts:91:13)
1353
- at CryptoService.verifyJWS (/Users/dylanhobbs/Documents/@kya-os/xmcp-i/packages/mcp-i-core/src/services/crypto.service.ts:169:23)
1354
- at /Users/dylanhobbs/Documents/@kya-os/xmcp-i/packages/mcp-i-core/src/services/__tests__/crypto.service.test.ts:316:42
1355
- at file:///Users/dylanhobbs/Documents/@kya-os/xmcp-i/node_modules/.pnpm/@vitest+runner@4.0.5/node_modules/@vitest/runner/dist/index.js:157:11
1356
- at file:///Users/dylanhobbs/Documents/@kya-os/xmcp-i/node_modules/.pnpm/@vitest+runner@4.0.5/node_modules/@vitest/runner/dist/index.js:753:26
1357
- at file:///Users/dylanhobbs/Documents/@kya-os/xmcp-i/node_modules/.pnpm/@vitest+runner@4.0.5/node_modules/@vitest/runner/dist/index.js:1636:20
1358
- at new Promise (<anonymous>)
1359
- at runWithTimeout (file:///Users/dylanhobbs/Documents/@kya-os/xmcp-i/node_modules/.pnpm/@vitest+runner@4.0.5/node_modules/@vitest/runner/dist/index.js:1602:10)
1360
- at runTest (file:///Users/dylanhobbs/Documents/@kya-os/xmcp-i/node_modules/.pnpm/@vitest+runner@4.0.5/node_modules/@vitest/runner/dist/index.js:1309:12)
1361
-  at processTicksAndRejections (node:internal/process/task_queues:103:5)
1362
-
1363
- stderr | src/services/__tests__/crypto.service.test.ts > CryptoService > verifyJWS > should handle malformed JWS - invalid base64
1364
- [CryptoService] Invalid JWS format: Error: Invalid payload base64: Invalid base64url string: Invalid character
1365
- at CryptoService.parseJWS (/Users/dylanhobbs/Documents/@kya-os/xmcp-i/packages/mcp-i-core/src/services/crypto.service.ts:107:15)
1366
- at CryptoService.verifyJWS (/Users/dylanhobbs/Documents/@kya-os/xmcp-i/packages/mcp-i-core/src/services/crypto.service.ts:169:23)
1367
- at /Users/dylanhobbs/Documents/@kya-os/xmcp-i/packages/mcp-i-core/src/services/__tests__/crypto.service.test.ts:334:42
1368
- at file:///Users/dylanhobbs/Documents/@kya-os/xmcp-i/node_modules/.pnpm/@vitest+runner@4.0.5/node_modules/@vitest/runner/dist/index.js:157:11
1369
- at file:///Users/dylanhobbs/Documents/@kya-os/xmcp-i/node_modules/.pnpm/@vitest+runner@4.0.5/node_modules/@vitest/runner/dist/index.js:753:26
1370
- at file:///Users/dylanhobbs/Documents/@kya-os/xmcp-i/node_modules/.pnpm/@vitest+runner@4.0.5/node_modules/@vitest/runner/dist/index.js:1636:20
1371
- at new Promise (<anonymous>)
1372
- at runWithTimeout (file:///Users/dylanhobbs/Documents/@kya-os/xmcp-i/node_modules/.pnpm/@vitest+runner@4.0.5/node_modules/@vitest/runner/dist/index.js:1602:10)
1373
- at runTest (file:///Users/dylanhobbs/Documents/@kya-os/xmcp-i/node_modules/.pnpm/@vitest+runner@4.0.5/node_modules/@vitest/runner/dist/index.js:1309:12)
1374
-  at processTicksAndRejections (node:internal/process/task_queues:103:5)
1375
-
1376
- stderr | src/services/__tests__/crypto.service.test.ts > CryptoService > verifyJWS > should validate expectedKid option
1377
- [CryptoService] Key ID mismatch
1378
-
1379
- stderr | src/services/__tests__/crypto.service.test.ts > CryptoService > verifyJWS > should validate alg option
1380
- [CryptoService] Unsupported algorithm: EdDSA, expected RS256
1381
-
1382
- stderr | src/services/__tests__/crypto.service.test.ts > CryptoService > verifyJWS > should validate Ed25519 key length
1383
- [CryptoService] Failed to extract public key: Error: Invalid Ed25519 public key length: 5
1384
- at CryptoService.jwkToBase64PublicKey (/Users/dylanhobbs/Documents/@kya-os/xmcp-i/packages/mcp-i-core/src/services/crypto.service.ts:295:13)
1385
- at CryptoService.verifyJWS (/Users/dylanhobbs/Documents/@kya-os/xmcp-i/packages/mcp-i-core/src/services/crypto.service.ts:249:32)
1386
- at /Users/dylanhobbs/Documents/@kya-os/xmcp-i/packages/mcp-i-core/src/services/__tests__/crypto.service.test.ts:398:42
1387
- at file:///Users/dylanhobbs/Documents/@kya-os/xmcp-i/node_modules/.pnpm/@vitest+runner@4.0.5/node_modules/@vitest/runner/dist/index.js:157:11
1388
- at file:///Users/dylanhobbs/Documents/@kya-os/xmcp-i/node_modules/.pnpm/@vitest+runner@4.0.5/node_modules/@vitest/runner/dist/index.js:753:26
1389
- at file:///Users/dylanhobbs/Documents/@kya-os/xmcp-i/node_modules/.pnpm/@vitest+runner@4.0.5/node_modules/@vitest/runner/dist/index.js:1636:20
1390
- at new Promise (<anonymous>)
1391
- at runWithTimeout (file:///Users/dylanhobbs/Documents/@kya-os/xmcp-i/node_modules/.pnpm/@vitest+runner@4.0.5/node_modules/@vitest/runner/dist/index.js:1602:10)
1392
- at runTest (file:///Users/dylanhobbs/Documents/@kya-os/xmcp-i/node_modules/.pnpm/@vitest+runner@4.0.5/node_modules/@vitest/runner/dist/index.js:1309:12)
1393
-  at processTicksAndRejections (node:internal/process/task_queues:103:5)
1394
-
1395
- stderr | src/services/__tests__/crypto.service.test.ts > CryptoService > verifyJWS > should handle signature verification error
1396
- [CryptoService] Ed25519 verification error: Error: Crypto error
1397
- at /Users/dylanhobbs/Documents/@kya-os/xmcp-i/packages/mcp-i-core/src/services/__tests__/crypto.service.test.ts:449:61
1398
- at file:///Users/dylanhobbs/Documents/@kya-os/xmcp-i/node_modules/.pnpm/@vitest+runner@4.0.5/node_modules/@vitest/runner/dist/index.js:157:11
1399
- at file:///Users/dylanhobbs/Documents/@kya-os/xmcp-i/node_modules/.pnpm/@vitest+runner@4.0.5/node_modules/@vitest/runner/dist/index.js:753:26
1400
- at file:///Users/dylanhobbs/Documents/@kya-os/xmcp-i/node_modules/.pnpm/@vitest+runner@4.0.5/node_modules/@vitest/runner/dist/index.js:1636:20
1401
- at new Promise (<anonymous>)
1402
- at runWithTimeout (file:///Users/dylanhobbs/Documents/@kya-os/xmcp-i/node_modules/.pnpm/@vitest+runner@4.0.5/node_modules/@vitest/runner/dist/index.js:1602:10)
1403
- at runTest (file:///Users/dylanhobbs/Documents/@kya-os/xmcp-i/node_modules/.pnpm/@vitest+runner@4.0.5/node_modules/@vitest/runner/dist/index.js:1309:12)
1404
-  at processTicksAndRejections (node:internal/process/task_queues:103:5)
1405
- at runSuite (file:///Users/dylanhobbs/Documents/@kya-os/xmcp-i/node_modules/.pnpm/@vitest+runner@4.0.5/node_modules/@vitest/runner/dist/index.js:1468:8)
1406
- at runSuite (file:///Users/dylanhobbs/Documents/@kya-os/xmcp-i/node_modules/.pnpm/@vitest+runner@4.0.5/node_modules/@vitest/runner/dist/index.js:1468:8)
1407
-
1408
-
1409
-  ❯ src/__tests__/cache/tool-protection-cache.test.ts 1/49
1410
-  ❯ src/__tests__/runtime/route-interception.test.ts [queued]
1411
-  ❯ src/__tests__/runtime/tool-protection-enforcement.test.ts [queued]
1412
-  ❯ src/__tests__/services/agentshield-integration.test.ts 0/30
1413
-  ❯ src/__tests__/services/provider-resolver-edge-cases.test.ts [queued]
1414
-  ❯ src/__tests__/services/tool-protection.service.test.ts 49/49
1415
-  ❯ src/delegation/__tests__/vc-issuer.test.ts 0/21
1416
-  ❯ src/delegation/__tests__/vc-verifier.test.ts 0/35
1417
-  ❯ src/services/__tests__/access-control.integration.test.ts [queued]
1418
-  ❯ src/services/__tests__/access-control.service.test.ts 23/23
1419
-  ❯ src/services/__tests__/crypto.service.test.ts 34/34
1420
-  ❯ src/services/__tests__/proof-verifier.integration.test.ts [queued]
1421
-  ❯ src/services/__tests__/storage.service.test.ts 17/17
1422
-
1423
-  Test Files 4 passed (43)
1424
-  Tests 124 passed (258)
1425
-  Start at 22:55:10
1426
-  Duration 402ms
1427
- [?2026l[?2026h ✓ src/services/__tests__/storage.service.test.ts (17 tests) 25ms
1428
- ✓ src/services/__tests__/access-control.service.test.ts (23 tests) 38ms
1429
- ✓ src/services/__tests__/crypto.service.test.ts (34 tests) 22ms
1430
-
1431
-  ❯ src/__tests__/cache/tool-protection-cache.test.ts 1/49
1432
-  ❯ src/__tests__/runtime/route-interception.test.ts [queued]
1433
-  ❯ src/__tests__/runtime/tool-protection-enforcement.test.ts [queued]
1434
-  ❯ src/__tests__/services/agentshield-integration.test.ts 0/30
1435
-  ❯ src/__tests__/services/provider-resolver-edge-cases.test.ts [queued]
1436
-  ❯ src/__tests__/services/tool-protection.service.test.ts 49/49
1437
-  ❯ src/delegation/__tests__/vc-issuer.test.ts 0/21
1438
-  ❯ src/delegation/__tests__/vc-verifier.test.ts 0/35
1439
-  ❯ src/services/__tests__/access-control.integration.test.ts [queued]
1440
-  ❯ src/services/__tests__/access-control.service.test.ts 23/23
1441
-  ❯ src/services/__tests__/crypto.service.test.ts 34/34
1442
-  ❯ src/services/__tests__/proof-verifier.integration.test.ts [queued]
1443
-  ❯ src/services/__tests__/storage.service.test.ts 17/17
1444
-
1445
-  Test Files 4 passed (43)
1446
-  Tests 124 passed (258)
1447
-  Start at 22:55:10
1448
-  Duration 402ms
1449
- [?2026l[?2026h ✓ src/delegation/__tests__/vc-verifier.test.ts (35 tests) 72ms
1450
- stdout | src/__tests__/runtime/tool-protection-enforcement.test.ts > MCPIRuntimeBase - Tool Protection Enforcement > processToolCall with tool protection > should allow tool execution when no protection required
1451
- [MCP-I] Checking tool protection: {
1452
- tool: 'unprotectedTool',
1453
- agentDid: 'did:key:zmock123...',
1454
- hasDelegation: false
1455
- }
1456
-
1457
- stdout | src/__tests__/runtime/tool-protection-enforcement.test.ts > MCPIRuntimeBase - Tool Protection Enforcement > processToolCall with tool protection > should allow tool execution when no protection required
1458
- [MCP-I] Tool protection check passed (no delegation required) {
1459
- tool: 'unprotectedTool',
1460
- agentDid: 'did:key:zmock123...',
1461
- reason: 'Tool not configured to require delegation'
1462
- }
1463
-
1464
- stdout | src/__tests__/runtime/tool-protection-enforcement.test.ts > MCPIRuntimeBase - Tool Protection Enforcement > processToolCall with tool protection > should block tool execution when protection required and no delegation
1465
- [MCP-I] Checking tool protection: {
1466
- tool: 'protectedTool',
1467
- agentDid: 'did:key:zmock123...',
1468
- hasDelegation: false
1469
- }
1470
-
1471
-
1472
-  ❯ src/__tests__/cache/tool-protection-cache.test.ts 49/49
1473
-  ❯ src/__tests__/runtime/base.test.ts 0/55
1474
-  ❯ src/__tests__/runtime/route-interception.test.ts 21/21
1475
-  ❯ src/__tests__/runtime/tool-protection-enforcement.test.ts 29/29
1476
-  ❯ src/__tests__/services/agentshield-integration.test.ts 26/30
1477
-  ❯ src/__tests__/services/provider-resolver-edge-cases.test.ts [queued]
1478
-  ❯ src/config/__tests__/remote-config.spec.ts [queued]
1479
-  ❯ src/delegation/__tests__/vc-issuer.test.ts 21/21
1480
-  ❯ src/delegation/__tests__/vc-verifier.test.ts 35/35
1481
-  ❯ src/services/__tests__/access-control.integration.test.ts 0/9
1482
-  ❯ src/services/__tests__/crypto.service.test.ts 34/34
1483
-  ❯ src/services/__tests__/proof-verifier.integration.test.ts 0/13
1484
-  ❯ src/services/__tests__/proof-verifier.test.ts [queued]
1485
-
1486
-  Test Files 9 passed (43)
1487
-  Tests 304 passed (385)
1488
-  Start at 22:55:10
1489
-  Duration 503ms
1490
- [?2026l[?2026hstderr | src/__tests__/runtime/tool-protection-enforcement.test.ts > MCPIRuntimeBase - Tool Protection Enforcement > processToolCall with tool protection > should block tool execution when protection required and no delegation
1491
- [MCP-I] BLOCKED: Tool requires delegation but none provided {
1492
- tool: 'protectedTool',
1493
- requiredScopes: [ 'files:write' ],
1494
- agentDid: 'did:key:zmock123...',
1495
- resumeToken: 'resume_3jof25_mi9tfb7m',
1496
- consentUrl: 'https://kya.vouched.id/bouncer/consent?tool=protectedTool&scopes=files%3Awrite&session_id=session123&agent_did=&resume_token=resume_3jof25_mi9tfb7m'
1497
- }
1498
-
1499
-
1500
-  ❯ src/__tests__/cache/tool-protection-cache.test.ts 49/49
1501
-  ❯ src/__tests__/runtime/base.test.ts 0/55
1502
-  ❯ src/__tests__/runtime/route-interception.test.ts 21/21
1503
-  ❯ src/__tests__/runtime/tool-protection-enforcement.test.ts 29/29
1504
-  ❯ src/__tests__/services/agentshield-integration.test.ts 26/30
1505
-  ❯ src/__tests__/services/provider-resolver-edge-cases.test.ts [queued]
1506
-  ❯ src/config/__tests__/remote-config.spec.ts [queued]
1507
-  ❯ src/delegation/__tests__/vc-issuer.test.ts 21/21
1508
-  ❯ src/delegation/__tests__/vc-verifier.test.ts 35/35
1509
-  ❯ src/services/__tests__/access-control.integration.test.ts 0/9
1510
-  ❯ src/services/__tests__/crypto.service.test.ts 34/34
1511
-  ❯ src/services/__tests__/proof-verifier.integration.test.ts 0/13
1512
-  ❯ src/services/__tests__/proof-verifier.test.ts [queued]
1513
-
1514
-  Test Files 9 passed (43)
1515
-  Tests 304 passed (385)
1516
-  Start at 22:55:10
1517
-  Duration 503ms
1518
- [?2026l[?2026hstdout | src/__tests__/runtime/tool-protection-enforcement.test.ts > MCPIRuntimeBase - Tool Protection Enforcement > processToolCall with tool protection > should allow tool execution when protection required and delegation provided
1519
- [MCP-I] Checking tool protection: {
1520
- tool: 'protectedTool',
1521
- agentDid: 'did:key:zmock123...',
1522
- hasDelegation: true
1523
- }
1524
-
1525
- stdout | src/__tests__/runtime/tool-protection-enforcement.test.ts > MCPIRuntimeBase - Tool Protection Enforcement > processToolCall with tool protection > should allow tool execution when protection required and delegation provided
1526
- [MCP-I] 🔐 Verifying delegation token with AccessControlApiService {
1527
- tool: 'protectedTool',
1528
- agentDid: 'did:key:zmock123...',
1529
- hasDelegationToken: true,
1530
- hasConsentProof: false,
1531
- requiredScopes: [ 'files:write' ]
1532
- }
1533
-
1534
- stdout | src/__tests__/runtime/tool-protection-enforcement.test.ts > MCPIRuntimeBase - Tool Protection Enforcement > processToolCall with tool protection > should allow tool execution when protection required and delegation provided
1535
- [MCP-I] ✅ Delegation verification SUCCEEDED {
1536
- tool: 'protectedTool',
1537
- agentDid: 'did:key:zmock123...',
1538
- delegationId: 'test-delegation-id',
1539
- credentialScopes: [ 'files:write' ],
1540
- requiredScopes: [ 'files:write' ]
1541
- }
1542
-
1543
- stdout | src/__tests__/runtime/tool-protection-enforcement.test.ts > MCPIRuntimeBase - Tool Protection Enforcement > processToolCall with tool protection > should allow tool execution when protection required and consentProof provided
1544
- [MCP-I] Checking tool protection: {
1545
- tool: 'protectedTool',
1546
- agentDid: 'did:key:zmock123...',
1547
- hasDelegation: true
1548
- }
1549
-
1550
- stdout | src/__tests__/runtime/tool-protection-enforcement.test.ts > MCPIRuntimeBase - Tool Protection Enforcement > processToolCall with tool protection > should allow tool execution when protection required and consentProof provided
1551
- [MCP-I] 🔐 Verifying delegation token with AccessControlApiService {
1552
- tool: 'protectedTool',
1553
- agentDid: 'did:key:zmock123...',
1554
- hasDelegationToken: false,
1555
- hasConsentProof: true,
1556
- requiredScopes: [ 'files:write' ]
1557
- }
1558
-
1559
- stdout | src/__tests__/runtime/tool-protection-enforcement.test.ts > MCPIRuntimeBase - Tool Protection Enforcement > processToolCall with tool protection > should allow tool execution when protection required and consentProof provided
1560
- [MCP-I] ✅ Delegation verification SUCCEEDED {
1561
- tool: 'protectedTool',
1562
- agentDid: 'did:key:zmock123...',
1563
- delegationId: 'test-delegation-id',
1564
- credentialScopes: [ 'files:write' ],
1565
- requiredScopes: [ 'files:write' ]
1566
- }
1567
-
1568
- stdout | src/__tests__/runtime/tool-protection-enforcement.test.ts > MCPIRuntimeBase - Tool Protection Enforcement > processToolCall with tool protection > should block tool execution when delegation verification fails
1569
- [MCP-I] Checking tool protection: {
1570
- tool: 'protectedTool',
1571
- agentDid: 'did:key:zmock123...',
1572
- hasDelegation: true
1573
- }
1574
-
1575
- stdout | src/__tests__/runtime/tool-protection-enforcement.test.ts > MCPIRuntimeBase - Tool Protection Enforcement > processToolCall with tool protection > should block tool execution when delegation verification fails
1576
- [MCP-I] 🔐 Verifying delegation token with AccessControlApiService {
1577
- tool: 'protectedTool',
1578
- agentDid: 'did:key:zmock123...',
1579
- hasDelegationToken: true,
1580
- hasConsentProof: false,
1581
- requiredScopes: [ 'files:write' ]
1582
- }
1583
-
1584
-
1585
-  ❯ src/__tests__/cache/tool-protection-cache.test.ts 49/49
1586
-  ❯ src/__tests__/runtime/base.test.ts 0/55
1587
-  ❯ src/__tests__/runtime/route-interception.test.ts 21/21
1588
-  ❯ src/__tests__/runtime/tool-protection-enforcement.test.ts 29/29
1589
-  ❯ src/__tests__/services/agentshield-integration.test.ts 26/30
1590
-  ❯ src/__tests__/services/provider-resolver-edge-cases.test.ts [queued]
1591
-  ❯ src/config/__tests__/remote-config.spec.ts [queued]
1592
-  ❯ src/delegation/__tests__/vc-issuer.test.ts 21/21
1593
-  ❯ src/delegation/__tests__/vc-verifier.test.ts 35/35
1594
-  ❯ src/services/__tests__/access-control.integration.test.ts 0/9
1595
-  ❯ src/services/__tests__/crypto.service.test.ts 34/34
1596
-  ❯ src/services/__tests__/proof-verifier.integration.test.ts 0/13
1597
-  ❯ src/services/__tests__/proof-verifier.test.ts [queued]
1598
-
1599
-  Test Files 9 passed (43)
1600
-  Tests 304 passed (385)
1601
-  Start at 22:55:10
1602
-  Duration 503ms
1603
- [?2026l[?2026hstderr | src/__tests__/runtime/tool-protection-enforcement.test.ts > MCPIRuntimeBase - Tool Protection Enforcement > processToolCall with tool protection > should block tool execution when delegation verification fails
1604
- [MCP-I] ❌ Delegation verification FAILED {
1605
- tool: 'protectedTool',
1606
- agentDid: 'did:key:zmock123...',
1607
- reason: 'Delegation token expired',
1608
- errorCode: undefined,
1609
- errorMessage: undefined,
1610
- requiredScopes: [ 'files:write' ]
1611
- }
1612
-
1613
-
1614
-  ❯ src/__tests__/cache/tool-protection-cache.test.ts 49/49
1615
-  ❯ src/__tests__/runtime/base.test.ts 0/55
1616
-  ❯ src/__tests__/runtime/route-interception.test.ts 21/21
1617
-  ❯ src/__tests__/runtime/tool-protection-enforcement.test.ts 29/29
1618
-  ❯ src/__tests__/services/agentshield-integration.test.ts 26/30
1619
-  ❯ src/__tests__/services/provider-resolver-edge-cases.test.ts [queued]
1620
-  ❯ src/config/__tests__/remote-config.spec.ts [queued]
1621
-  ❯ src/delegation/__tests__/vc-issuer.test.ts 21/21
1622
-  ❯ src/delegation/__tests__/vc-verifier.test.ts 35/35
1623
-  ❯ src/services/__tests__/access-control.integration.test.ts 0/9
1624
-  ❯ src/services/__tests__/crypto.service.test.ts 34/34
1625
-  ❯ src/services/__tests__/proof-verifier.integration.test.ts 0/13
1626
-  ❯ src/services/__tests__/proof-verifier.test.ts [queued]
1627
-
1628
-  Test Files 9 passed (43)
1629
-  Tests 304 passed (385)
1630
-  Start at 22:55:10
1631
-  Duration 503ms
1632
- [?2026l[?2026hstdout | src/__tests__/runtime/tool-protection-enforcement.test.ts > MCPIRuntimeBase - Tool Protection Enforcement > processToolCall with tool protection > should block tool execution when delegation has wrong scopes
1633
- [MCP-I] Checking tool protection: {
1634
- tool: 'protectedTool',
1635
- agentDid: 'did:key:zmock123...',
1636
- hasDelegation: true
1637
- }
1638
-
1639
- stdout | src/__tests__/runtime/tool-protection-enforcement.test.ts > MCPIRuntimeBase - Tool Protection Enforcement > processToolCall with tool protection > should block tool execution when delegation has wrong scopes
1640
- [MCP-I] 🔐 Verifying delegation token with AccessControlApiService {
1641
- tool: 'protectedTool',
1642
- agentDid: 'did:key:zmock123...',
1643
- hasDelegationToken: true,
1644
- hasConsentProof: false,
1645
- requiredScopes: [ 'files:write' ]
1646
- }
1647
-
1648
-
1649
-  ❯ src/__tests__/cache/tool-protection-cache.test.ts 49/49
1650
-  ❯ src/__tests__/runtime/base.test.ts 0/55
1651
-  ❯ src/__tests__/runtime/route-interception.test.ts 21/21
1652
-  ❯ src/__tests__/runtime/tool-protection-enforcement.test.ts 29/29
1653
-  ❯ src/__tests__/services/agentshield-integration.test.ts 26/30
1654
-  ❯ src/__tests__/services/provider-resolver-edge-cases.test.ts [queued]
1655
-  ❯ src/config/__tests__/remote-config.spec.ts [queued]
1656
-  ❯ src/delegation/__tests__/vc-issuer.test.ts 21/21
1657
-  ❯ src/delegation/__tests__/vc-verifier.test.ts 35/35
1658
-  ❯ src/services/__tests__/access-control.integration.test.ts 0/9
1659
-  ❯ src/services/__tests__/crypto.service.test.ts 34/34
1660
-  ❯ src/services/__tests__/proof-verifier.integration.test.ts 0/13
1661
-  ❯ src/services/__tests__/proof-verifier.test.ts [queued]
1662
-
1663
-  Test Files 9 passed (43)
1664
-  Tests 304 passed (385)
1665
-  Start at 22:55:10
1666
-  Duration 503ms
1667
- [?2026l[?2026hstderr | src/__tests__/runtime/tool-protection-enforcement.test.ts > MCPIRuntimeBase - Tool Protection Enforcement > processToolCall with tool protection > should block tool execution when delegation has wrong scopes
1668
- [MCP-I] ❌ Delegation verification FAILED {
1669
- tool: 'protectedTool',
1670
- agentDid: 'did:key:zmock123...',
1671
- reason: 'Insufficient scopes',
1672
- errorCode: undefined,
1673
- errorMessage: undefined,
1674
- requiredScopes: [ 'files:write' ]
1675
- }
1676
-
1677
-
1678
-  ❯ src/__tests__/cache/tool-protection-cache.test.ts 49/49
1679
-  ❯ src/__tests__/runtime/base.test.ts 0/55
1680
-  ❯ src/__tests__/runtime/route-interception.test.ts 21/21
1681
-  ❯ src/__tests__/runtime/tool-protection-enforcement.test.ts 29/29
1682
-  ❯ src/__tests__/services/agentshield-integration.test.ts 26/30
1683
-  ❯ src/__tests__/services/provider-resolver-edge-cases.test.ts [queued]
1684
-  ❯ src/config/__tests__/remote-config.spec.ts [queued]
1685
-  ❯ src/delegation/__tests__/vc-issuer.test.ts 21/21
1686
-  ❯ src/delegation/__tests__/vc-verifier.test.ts 35/35
1687
-  ❯ src/services/__tests__/access-control.integration.test.ts 0/9
1688
-  ❯ src/services/__tests__/crypto.service.test.ts 34/34
1689
-  ❯ src/services/__tests__/proof-verifier.integration.test.ts 0/13
1690
-  ❯ src/services/__tests__/proof-verifier.test.ts [queued]
1691
-
1692
-  Test Files 9 passed (43)
1693
-  Tests 304 passed (385)
1694
-  Start at 22:55:10
1695
-  Duration 503ms
1696
- [?2026l[?2026hstdout | src/__tests__/runtime/tool-protection-enforcement.test.ts > MCPIRuntimeBase - Tool Protection Enforcement > processToolCall with tool protection > should handle API errors during verification gracefully
1697
- [MCP-I] Checking tool protection: {
1698
- tool: 'protectedTool',
1699
- agentDid: 'did:key:zmock123...',
1700
- hasDelegation: true
1701
- }
1702
-
1703
- stdout | src/__tests__/runtime/tool-protection-enforcement.test.ts > MCPIRuntimeBase - Tool Protection Enforcement > processToolCall with tool protection > should handle API errors during verification gracefully
1704
- [MCP-I] 🔐 Verifying delegation token with AccessControlApiService {
1705
- tool: 'protectedTool',
1706
- agentDid: 'did:key:zmock123...',
1707
- hasDelegationToken: true,
1708
- hasConsentProof: false,
1709
- requiredScopes: [ 'files:write' ]
1710
- }
1711
-
1712
-
1713
-  ❯ src/__tests__/cache/tool-protection-cache.test.ts 49/49
1714
-  ❯ src/__tests__/runtime/base.test.ts 0/55
1715
-  ❯ src/__tests__/runtime/route-interception.test.ts 21/21
1716
-  ❯ src/__tests__/runtime/tool-protection-enforcement.test.ts 29/29
1717
-  ❯ src/__tests__/services/agentshield-integration.test.ts 26/30
1718
-  ❯ src/__tests__/services/provider-resolver-edge-cases.test.ts [queued]
1719
-  ❯ src/config/__tests__/remote-config.spec.ts [queued]
1720
-  ❯ src/delegation/__tests__/vc-issuer.test.ts 21/21
1721
-  ❯ src/delegation/__tests__/vc-verifier.test.ts 35/35
1722
-  ❯ src/services/__tests__/access-control.integration.test.ts 0/9
1723
-  ❯ src/services/__tests__/crypto.service.test.ts 34/34
1724
-  ❯ src/services/__tests__/proof-verifier.integration.test.ts 0/13
1725
-  ❯ src/services/__tests__/proof-verifier.test.ts [queued]
1726
-
1727
-  Test Files 9 passed (43)
1728
-  Tests 304 passed (385)
1729
-  Start at 22:55:10
1730
-  Duration 503ms
1731
- [?2026l[?2026hstderr | src/__tests__/runtime/tool-protection-enforcement.test.ts > MCPIRuntimeBase - Tool Protection Enforcement > processToolCall with tool protection > should handle API errors during verification gracefully
1732
- [MCP-I] ❌ Delegation verification error (API failure) {
1733
- tool: 'protectedTool',
1734
- agentDid: 'did:key:zmock123...',
1735
- errorCode: 'network_error',
1736
- errorMessage: 'API unavailable',
1737
- errorDetails: {}
1738
- }
1739
-
1740
-
1741
-  ❯ src/__tests__/cache/tool-protection-cache.test.ts 49/49
1742
-  ❯ src/__tests__/runtime/base.test.ts 0/55
1743
-  ❯ src/__tests__/runtime/route-interception.test.ts 21/21
1744
-  ❯ src/__tests__/runtime/tool-protection-enforcement.test.ts 29/29
1745
-  ❯ src/__tests__/services/agentshield-integration.test.ts 26/30
1746
-  ❯ src/__tests__/services/provider-resolver-edge-cases.test.ts [queued]
1747
-  ❯ src/config/__tests__/remote-config.spec.ts [queued]
1748
-  ❯ src/delegation/__tests__/vc-issuer.test.ts 21/21
1749
-  ❯ src/delegation/__tests__/vc-verifier.test.ts 35/35
1750
-  ❯ src/services/__tests__/access-control.integration.test.ts 0/9
1751
-  ❯ src/services/__tests__/crypto.service.test.ts 34/34
1752
-  ❯ src/services/__tests__/proof-verifier.integration.test.ts 0/13
1753
-  ❯ src/services/__tests__/proof-verifier.test.ts [queued]
1754
-
1755
-  Test Files 9 passed (43)
1756
-  Tests 304 passed (385)
1757
-  Start at 22:55:10
1758
-  Duration 503ms
1759
- [?2026l[?2026hstdout | src/__tests__/runtime/tool-protection-enforcement.test.ts > MCPIRuntimeBase - Tool Protection Enforcement > processToolCall with tool protection > should allow tool execution when access control service not configured (graceful degradation)
1760
- [MCP-I] Checking tool protection: {
1761
- tool: 'protectedTool',
1762
- agentDid: 'did:key:zmock123...',
1763
- hasDelegation: true
1764
- }
1765
-
1766
-
1767
-  ❯ src/__tests__/cache/tool-protection-cache.test.ts 49/49
1768
-  ❯ src/__tests__/runtime/base.test.ts 0/55
1769
-  ❯ src/__tests__/runtime/route-interception.test.ts 21/21
1770
-  ❯ src/__tests__/runtime/tool-protection-enforcement.test.ts 29/29
1771
-  ❯ src/__tests__/services/agentshield-integration.test.ts 26/30
1772
-  ❯ src/__tests__/services/provider-resolver-edge-cases.test.ts [queued]
1773
-  ❯ src/config/__tests__/remote-config.spec.ts [queued]
1774
-  ❯ src/delegation/__tests__/vc-issuer.test.ts 21/21
1775
-  ❯ src/delegation/__tests__/vc-verifier.test.ts 35/35
1776
-  ❯ src/services/__tests__/access-control.integration.test.ts 0/9
1777
-  ❯ src/services/__tests__/crypto.service.test.ts 34/34
1778
-  ❯ src/services/__tests__/proof-verifier.integration.test.ts 0/13
1779
-  ❯ src/services/__tests__/proof-verifier.test.ts [queued]
1780
-
1781
-  Test Files 9 passed (43)
1782
-  Tests 304 passed (385)
1783
-  Start at 22:55:10
1784
-  Duration 503ms
1785
- [?2026l[?2026hstderr | src/__tests__/runtime/tool-protection-enforcement.test.ts > MCPIRuntimeBase - Tool Protection Enforcement > processToolCall with tool protection > should allow tool execution when access control service not configured (graceful degradation)
1786
- [MCP-I] ⚠️ Delegation token provided but AccessControlApiService not configured - skipping verification {
1787
- tool: 'protectedTool',
1788
- agentDid: 'did:key:zmock123...',
1789
- hasDelegationToken: true,
1790
- hasConsentProof: false
1791
- }
1792
-
1793
-
1794
-  ❯ src/__tests__/cache/tool-protection-cache.test.ts 49/49
1795
-  ❯ src/__tests__/runtime/base.test.ts 0/55
1796
-  ❯ src/__tests__/runtime/route-interception.test.ts 21/21
1797
-  ❯ src/__tests__/runtime/tool-protection-enforcement.test.ts 29/29
1798
-  ❯ src/__tests__/services/agentshield-integration.test.ts 26/30
1799
-  ❯ src/__tests__/services/provider-resolver-edge-cases.test.ts [queued]
1800
-  ❯ src/config/__tests__/remote-config.spec.ts [queued]
1801
-  ❯ src/delegation/__tests__/vc-issuer.test.ts 21/21
1802
-  ❯ src/delegation/__tests__/vc-verifier.test.ts 35/35
1803
-  ❯ src/services/__tests__/access-control.integration.test.ts 0/9
1804
-  ❯ src/services/__tests__/crypto.service.test.ts 34/34
1805
-  ❯ src/services/__tests__/proof-verifier.integration.test.ts 0/13
1806
-  ❯ src/services/__tests__/proof-verifier.test.ts [queued]
1807
-
1808
-  Test Files 9 passed (43)
1809
-  Tests 304 passed (385)
1810
-  Start at 22:55:10
1811
-  Duration 503ms
1812
- [?2026l[?2026hstdout | src/__tests__/runtime/tool-protection-enforcement.test.ts > MCPIRuntimeBase - Tool Protection Enforcement > processToolCall with tool protection > user_identifier validation > should reject delegation when user_identifier does not match session userDid
1813
- [MCP-I] Checking tool protection: {
1814
- tool: 'protectedTool',
1815
- agentDid: 'did:key:zmock123...',
1816
- hasDelegation: true
1817
- }
1818
-
1819
- stdout | src/__tests__/runtime/tool-protection-enforcement.test.ts > MCPIRuntimeBase - Tool Protection Enforcement > processToolCall with tool protection > user_identifier validation > should reject delegation when user_identifier does not match session userDid
1820
- [MCP-I] 🔐 Verifying delegation token with AccessControlApiService {
1821
- tool: 'protectedTool',
1822
- agentDid: 'did:key:zmock123...',
1823
- hasDelegationToken: true,
1824
- hasConsentProof: false,
1825
- requiredScopes: [ 'files:write' ]
1826
- }
1827
-
1828
-
1829
-  ❯ src/__tests__/cache/tool-protection-cache.test.ts 49/49
1830
-  ❯ src/__tests__/runtime/base.test.ts 0/55
1831
-  ❯ src/__tests__/runtime/route-interception.test.ts 21/21
1832
-  ❯ src/__tests__/runtime/tool-protection-enforcement.test.ts 29/29
1833
-  ❯ src/__tests__/services/agentshield-integration.test.ts 26/30
1834
-  ❯ src/__tests__/services/provider-resolver-edge-cases.test.ts [queued]
1835
-  ❯ src/config/__tests__/remote-config.spec.ts [queued]
1836
-  ❯ src/delegation/__tests__/vc-issuer.test.ts 21/21
1837
-  ❯ src/delegation/__tests__/vc-verifier.test.ts 35/35
1838
-  ❯ src/services/__tests__/access-control.integration.test.ts 0/9
1839
-  ❯ src/services/__tests__/crypto.service.test.ts 34/34
1840
-  ❯ src/services/__tests__/proof-verifier.integration.test.ts 0/13
1841
-  ❯ src/services/__tests__/proof-verifier.test.ts [queued]
1842
-
1843
-  Test Files 9 passed (43)
1844
-  Tests 304 passed (385)
1845
-  Start at 22:55:10
1846
-  Duration 503ms
1847
- [?2026l[?2026hstderr | src/__tests__/runtime/tool-protection-enforcement.test.ts > MCPIRuntimeBase - Tool Protection Enforcement > processToolCall with tool protection > user_identifier validation > should reject delegation when user_identifier does not match session userDid
1848
- [MCP-I] 🔒 SECURITY: User identifier validation FAILED {
1849
- tool: 'protectedTool',
1850
- agentDid: 'did:key:zmock123...',
1851
- delegationUserIdentifier: 'did:key:zUserB987654...',
1852
- sessionUserDid: 'did:key:zUserA123456...',
1853
- sessionId: 'session123...',
1854
- reason: 'user_identifier_mismatch',
1855
- severity: 'high'
1856
- }
1857
-
1858
-
1859
-  ❯ src/__tests__/cache/tool-protection-cache.test.ts 49/49
1860
-  ❯ src/__tests__/runtime/base.test.ts 0/55
1861
-  ❯ src/__tests__/runtime/route-interception.test.ts 21/21
1862
-  ❯ src/__tests__/runtime/tool-protection-enforcement.test.ts 29/29
1863
-  ❯ src/__tests__/services/agentshield-integration.test.ts 26/30
1864
-  ❯ src/__tests__/services/provider-resolver-edge-cases.test.ts [queued]
1865
-  ❯ src/config/__tests__/remote-config.spec.ts [queued]
1866
-  ❯ src/delegation/__tests__/vc-issuer.test.ts 21/21
1867
-  ❯ src/delegation/__tests__/vc-verifier.test.ts 35/35
1868
-  ❯ src/services/__tests__/access-control.integration.test.ts 0/9
1869
-  ❯ src/services/__tests__/crypto.service.test.ts 34/34
1870
-  ❯ src/services/__tests__/proof-verifier.integration.test.ts 0/13
1871
-  ❯ src/services/__tests__/proof-verifier.test.ts [queued]
1872
-
1873
-  Test Files 9 passed (43)
1874
-  Tests 304 passed (385)
1875
-  Start at 22:55:10
1876
-  Duration 503ms
1877
- [?2026l[?2026hstdout | src/__tests__/runtime/tool-protection-enforcement.test.ts > MCPIRuntimeBase - Tool Protection Enforcement > processToolCall with tool protection > user_identifier validation > should accept delegation when user_identifier matches session userDid
1878
- [MCP-I] Checking tool protection: {
1879
- tool: 'protectedTool',
1880
- agentDid: 'did:key:zmock123...',
1881
- hasDelegation: true
1882
- }
1883
-
1884
- stdout | src/__tests__/runtime/tool-protection-enforcement.test.ts > MCPIRuntimeBase - Tool Protection Enforcement > processToolCall with tool protection > user_identifier validation > should accept delegation when user_identifier matches session userDid
1885
- [MCP-I] 🔐 Verifying delegation token with AccessControlApiService {
1886
- tool: 'protectedTool',
1887
- agentDid: 'did:key:zmock123...',
1888
- hasDelegationToken: true,
1889
- hasConsentProof: false,
1890
- requiredScopes: [ 'files:write' ]
1891
- }
1892
-
1893
- stdout | src/__tests__/runtime/tool-protection-enforcement.test.ts > MCPIRuntimeBase - Tool Protection Enforcement > processToolCall with tool protection > user_identifier validation > should accept delegation when user_identifier matches session userDid
1894
- [MCP-I] ✅ User identifier validation PASSED {
1895
- tool: 'protectedTool',
1896
- agentDid: 'did:key:zmock123...',
1897
- userDid: 'did:key:zUserA123456...',
1898
- sessionId: 'session123...'
1899
- }
1900
- [MCP-I] ✅ Delegation verification SUCCEEDED {
1901
- tool: 'protectedTool',
1902
- agentDid: 'did:key:zmock123...',
1903
- delegationId: 'test-delegation-id',
1904
- credentialScopes: [ 'files:write' ],
1905
- requiredScopes: [ 'files:write' ]
1906
- }
1907
-
1908
- stdout | src/__tests__/runtime/tool-protection-enforcement.test.ts > MCPIRuntimeBase - Tool Protection Enforcement > processToolCall with tool protection > user_identifier validation > should handle missing user_identifier gracefully (backward compatibility)
1909
- [MCP-I] Checking tool protection: {
1910
- tool: 'protectedTool',
1911
- agentDid: 'did:key:zmock123...',
1912
- hasDelegation: true
1913
- }
1914
-
1915
- stdout | src/__tests__/runtime/tool-protection-enforcement.test.ts > MCPIRuntimeBase - Tool Protection Enforcement > processToolCall with tool protection > user_identifier validation > should handle missing user_identifier gracefully (backward compatibility)
1916
- [MCP-I] 🔐 Verifying delegation token with AccessControlApiService {
1917
- tool: 'protectedTool',
1918
- agentDid: 'did:key:zmock123...',
1919
- hasDelegationToken: true,
1920
- hasConsentProof: false,
1921
- requiredScopes: [ 'files:write' ]
1922
- }
1923
-
1924
- stdout | src/__tests__/runtime/tool-protection-enforcement.test.ts > MCPIRuntimeBase - Tool Protection Enforcement > processToolCall with tool protection > user_identifier validation > should handle missing user_identifier gracefully (backward compatibility)
1925
- [MCP-I] ✅ Delegation verification SUCCEEDED {
1926
- tool: 'protectedTool',
1927
- agentDid: 'did:key:zmock123...',
1928
- delegationId: 'test-delegation-id',
1929
- credentialScopes: [ 'files:write' ],
1930
- requiredScopes: [ 'files:write' ]
1931
- }
1932
-
1933
- stdout | src/__tests__/runtime/tool-protection-enforcement.test.ts > MCPIRuntimeBase - Tool Protection Enforcement > processToolCall with tool protection > user_identifier validation > should handle missing session userDid gracefully
1934
- [MCP-I] Checking tool protection: {
1935
- tool: 'protectedTool',
1936
- agentDid: 'did:key:zmock123...',
1937
- hasDelegation: true
1938
- }
1939
-
1940
- stdout | src/__tests__/runtime/tool-protection-enforcement.test.ts > MCPIRuntimeBase - Tool Protection Enforcement > processToolCall with tool protection > user_identifier validation > should handle missing session userDid gracefully
1941
- [MCP-I] 🔐 Verifying delegation token with AccessControlApiService {
1942
- tool: 'protectedTool',
1943
- agentDid: 'did:key:zmock123...',
1944
- hasDelegationToken: true,
1945
- hasConsentProof: false,
1946
- requiredScopes: [ 'files:write' ]
1947
- }
1948
-
1949
- stdout | src/__tests__/runtime/tool-protection-enforcement.test.ts > MCPIRuntimeBase - Tool Protection Enforcement > processToolCall with tool protection > user_identifier validation > should handle missing session userDid gracefully
1950
- [MCP-I] ✅ Delegation verification SUCCEEDED {
1951
- tool: 'protectedTool',
1952
- agentDid: 'did:key:zmock123...',
1953
- delegationId: 'test-delegation-id',
1954
- credentialScopes: [ 'files:write' ],
1955
- requiredScopes: [ 'files:write' ]
1956
- }
1957
-
1958
-
1959
-  ❯ src/__tests__/cache/tool-protection-cache.test.ts 49/49
1960
-  ❯ src/__tests__/runtime/base.test.ts 0/55
1961
-  ❯ src/__tests__/runtime/route-interception.test.ts 21/21
1962
-  ❯ src/__tests__/runtime/tool-protection-enforcement.test.ts 29/29
1963
-  ❯ src/__tests__/services/agentshield-integration.test.ts 26/30
1964
-  ❯ src/__tests__/services/provider-resolver-edge-cases.test.ts [queued]
1965
-  ❯ src/config/__tests__/remote-config.spec.ts [queued]
1966
-  ❯ src/delegation/__tests__/vc-issuer.test.ts 21/21
1967
-  ❯ src/delegation/__tests__/vc-verifier.test.ts 35/35
1968
-  ❯ src/services/__tests__/access-control.integration.test.ts 0/9
1969
-  ❯ src/services/__tests__/crypto.service.test.ts 34/34
1970
-  ❯ src/services/__tests__/proof-verifier.integration.test.ts 0/13
1971
-  ❯ src/services/__tests__/proof-verifier.test.ts [queued]
1972
-
1973
-  Test Files 9 passed (43)
1974
-  Tests 304 passed (385)
1975
-  Start at 22:55:10
1976
-  Duration 503ms
1977
- [?2026l[?2026hstderr | src/__tests__/runtime/tool-protection-enforcement.test.ts > MCPIRuntimeBase - Tool Protection Enforcement > processToolCall with tool protection > user_identifier validation > should handle missing session userDid gracefully
1978
- [MCP-I] ⚠️ Delegation has user_identifier but session missing userDid {
1979
- tool: 'protectedTool',
1980
- agentDid: 'did:key:zmock123...',
1981
- delegationUserIdentifier: 'did:key:zUserA123456...',
1982
- sessionId: 'session123...'
1983
- }
1984
-
1985
-
1986
-  ❯ src/__tests__/cache/tool-protection-cache.test.ts 49/49
1987
-  ❯ src/__tests__/runtime/base.test.ts 0/55
1988
-  ❯ src/__tests__/runtime/route-interception.test.ts 21/21
1989
-  ❯ src/__tests__/runtime/tool-protection-enforcement.test.ts 29/29
1990
-  ❯ src/__tests__/services/agentshield-integration.test.ts 26/30
1991
-  ❯ src/__tests__/services/provider-resolver-edge-cases.test.ts [queued]
1992
-  ❯ src/config/__tests__/remote-config.spec.ts [queued]
1993
-  ❯ src/delegation/__tests__/vc-issuer.test.ts 21/21
1994
-  ❯ src/delegation/__tests__/vc-verifier.test.ts 35/35
1995
-  ❯ src/services/__tests__/access-control.integration.test.ts 0/9
1996
-  ❯ src/services/__tests__/crypto.service.test.ts 34/34
1997
-  ❯ src/services/__tests__/proof-verifier.integration.test.ts 0/13
1998
-  ❯ src/services/__tests__/proof-verifier.test.ts [queued]
1999
-
2000
-  Test Files 9 passed (43)
2001
-  Tests 304 passed (385)
2002
-  Start at 22:55:10
2003
-  Duration 503ms
2004
- [?2026l[?2026hstdout | src/__tests__/runtime/tool-protection-enforcement.test.ts > MCPIRuntimeBase - Tool Protection Enforcement > processToolCall with tool protection > should create proof after successful tool execution
2005
- [MCP-I] Checking tool protection: {
2006
- tool: 'unprotectedTool',
2007
- agentDid: 'did:key:zmock123...',
2008
- hasDelegation: false
2009
- }
2010
-
2011
- stdout | src/__tests__/runtime/tool-protection-enforcement.test.ts > MCPIRuntimeBase - Tool Protection Enforcement > processToolCall with tool protection > should create proof after successful tool execution
2012
- [MCP-I] Tool protection check passed (no delegation required) {
2013
- tool: 'unprotectedTool',
2014
- agentDid: 'did:key:zmock123...',
2015
- reason: 'Tool not configured to require delegation'
2016
- }
2017
-
2018
- stdout | src/__tests__/runtime/tool-protection-enforcement.test.ts > MCPIRuntimeBase - Tool Protection Enforcement > processToolCall with tool protection > should not create proof when tool execution is blocked
2019
- [MCP-I] Checking tool protection: {
2020
- tool: 'protectedTool',
2021
- agentDid: 'did:key:zmock123...',
2022
- hasDelegation: false
2023
- }
2024
-
2025
-
2026
-  ❯ src/__tests__/cache/tool-protection-cache.test.ts 49/49
2027
-  ❯ src/__tests__/runtime/base.test.ts 0/55
2028
-  ❯ src/__tests__/runtime/route-interception.test.ts 21/21
2029
-  ❯ src/__tests__/runtime/tool-protection-enforcement.test.ts 29/29
2030
-  ❯ src/__tests__/services/agentshield-integration.test.ts 26/30
2031
-  ❯ src/__tests__/services/provider-resolver-edge-cases.test.ts [queued]
2032
-  ❯ src/config/__tests__/remote-config.spec.ts [queued]
2033
-  ❯ src/delegation/__tests__/vc-issuer.test.ts 21/21
2034
-  ❯ src/delegation/__tests__/vc-verifier.test.ts 35/35
2035
-  ❯ src/services/__tests__/access-control.integration.test.ts 0/9
2036
-  ❯ src/services/__tests__/crypto.service.test.ts 34/34
2037
-  ❯ src/services/__tests__/proof-verifier.integration.test.ts 0/13
2038
-  ❯ src/services/__tests__/proof-verifier.test.ts [queued]
2039
-
2040
-  Test Files 9 passed (43)
2041
-  Tests 304 passed (385)
2042
-  Start at 22:55:10
2043
-  Duration 503ms
2044
- [?2026l[?2026hstderr | src/__tests__/runtime/tool-protection-enforcement.test.ts > MCPIRuntimeBase - Tool Protection Enforcement > processToolCall with tool protection > should not create proof when tool execution is blocked
2045
- [MCP-I] BLOCKED: Tool requires delegation but none provided {
2046
- tool: 'protectedTool',
2047
- requiredScopes: [ 'files:write' ],
2048
- agentDid: 'did:key:zmock123...',
2049
- resumeToken: 'resume_3joebg_mi9tfb7w',
2050
- consentUrl: 'https://kya.vouched.id/bouncer/consent?tool=protectedTool&scopes=files%3Awrite&session_id=session123&agent_did=&resume_token=resume_3joebg_mi9tfb7w'
2051
- }
2052
-
2053
-
2054
-  ❯ src/__tests__/cache/tool-protection-cache.test.ts 49/49
2055
-  ❯ src/__tests__/runtime/base.test.ts 0/55
2056
-  ❯ src/__tests__/runtime/route-interception.test.ts 21/21
2057
-  ❯ src/__tests__/runtime/tool-protection-enforcement.test.ts 29/29
2058
-  ❯ src/__tests__/services/agentshield-integration.test.ts 26/30
2059
-  ❯ src/__tests__/services/provider-resolver-edge-cases.test.ts [queued]
2060
-  ❯ src/config/__tests__/remote-config.spec.ts [queued]
2061
-  ❯ src/delegation/__tests__/vc-issuer.test.ts 21/21
2062
-  ❯ src/delegation/__tests__/vc-verifier.test.ts 35/35
2063
-  ❯ src/services/__tests__/access-control.integration.test.ts 0/9
2064
-  ❯ src/services/__tests__/crypto.service.test.ts 34/34
2065
-  ❯ src/services/__tests__/proof-verifier.integration.test.ts 0/13
2066
-  ❯ src/services/__tests__/proof-verifier.test.ts [queued]
2067
-
2068
-  Test Files 9 passed (43)
2069
-  Tests 304 passed (385)
2070
-  Start at 22:55:10
2071
-  Duration 503ms
2072
- [?2026l[?2026hstdout | src/__tests__/runtime/tool-protection-enforcement.test.ts > MCPIRuntimeBase - Tool Protection Enforcement > DelegationRequiredError details > should include tool name in error
2073
- [MCP-I] Checking tool protection: {
2074
- tool: 'protectedTool',
2075
- agentDid: 'did:key:zmock123...',
2076
- hasDelegation: false
2077
- }
2078
-
2079
-
2080
-  ❯ src/__tests__/cache/tool-protection-cache.test.ts 49/49
2081
-  ❯ src/__tests__/runtime/base.test.ts 0/55
2082
-  ❯ src/__tests__/runtime/route-interception.test.ts 21/21
2083
-  ❯ src/__tests__/runtime/tool-protection-enforcement.test.ts 29/29
2084
-  ❯ src/__tests__/services/agentshield-integration.test.ts 26/30
2085
-  ❯ src/__tests__/services/provider-resolver-edge-cases.test.ts [queued]
2086
-  ❯ src/config/__tests__/remote-config.spec.ts [queued]
2087
-  ❯ src/delegation/__tests__/vc-issuer.test.ts 21/21
2088
-  ❯ src/delegation/__tests__/vc-verifier.test.ts 35/35
2089
-  ❯ src/services/__tests__/access-control.integration.test.ts 0/9
2090
-  ❯ src/services/__tests__/crypto.service.test.ts 34/34
2091
-  ❯ src/services/__tests__/proof-verifier.integration.test.ts 0/13
2092
-  ❯ src/services/__tests__/proof-verifier.test.ts [queued]
2093
-
2094
-  Test Files 9 passed (43)
2095
-  Tests 304 passed (385)
2096
-  Start at 22:55:10
2097
-  Duration 503ms
2098
- [?2026l[?2026hstderr | src/__tests__/runtime/tool-protection-enforcement.test.ts > MCPIRuntimeBase - Tool Protection Enforcement > DelegationRequiredError details > should include tool name in error
2099
- [MCP-I] BLOCKED: Tool requires delegation but none provided {
2100
- tool: 'protectedTool',
2101
- requiredScopes: [ 'files:write' ],
2102
- agentDid: 'did:key:zmock123...',
2103
- resumeToken: 'resume_3joeal_mi9tfb7w',
2104
- consentUrl: 'https://kya.vouched.id/bouncer/consent?tool=protectedTool&scopes=files%3Awrite&session_id=session123&agent_did=&resume_token=resume_3joeal_mi9tfb7w'
2105
- }
2106
-
2107
-
2108
-  ❯ src/__tests__/cache/tool-protection-cache.test.ts 49/49
2109
-  ❯ src/__tests__/runtime/base.test.ts 0/55
2110
-  ❯ src/__tests__/runtime/route-interception.test.ts 21/21
2111
-  ❯ src/__tests__/runtime/tool-protection-enforcement.test.ts 29/29
2112
-  ❯ src/__tests__/services/agentshield-integration.test.ts 26/30
2113
-  ❯ src/__tests__/services/provider-resolver-edge-cases.test.ts [queued]
2114
-  ❯ src/config/__tests__/remote-config.spec.ts [queued]
2115
-  ❯ src/delegation/__tests__/vc-issuer.test.ts 21/21
2116
-  ❯ src/delegation/__tests__/vc-verifier.test.ts 35/35
2117
-  ❯ src/services/__tests__/access-control.integration.test.ts 0/9
2118
-  ❯ src/services/__tests__/crypto.service.test.ts 34/34
2119
-  ❯ src/services/__tests__/proof-verifier.integration.test.ts 0/13
2120
-  ❯ src/services/__tests__/proof-verifier.test.ts [queued]
2121
-
2122
-  Test Files 9 passed (43)
2123
-  Tests 304 passed (385)
2124
-  Start at 22:55:10
2125
-  Duration 503ms
2126
- [?2026l[?2026hstdout | src/__tests__/runtime/tool-protection-enforcement.test.ts > MCPIRuntimeBase - Tool Protection Enforcement > DelegationRequiredError details > should include required scopes in error
2127
- [MCP-I] Checking tool protection: {
2128
- tool: 'protectedTool',
2129
- agentDid: 'did:key:zmock123...',
2130
- hasDelegation: false
2131
- }
2132
-
2133
-
2134
-  ❯ src/__tests__/cache/tool-protection-cache.test.ts 49/49
2135
-  ❯ src/__tests__/runtime/base.test.ts 0/55
2136
-  ❯ src/__tests__/runtime/route-interception.test.ts 21/21
2137
-  ❯ src/__tests__/runtime/tool-protection-enforcement.test.ts 29/29
2138
-  ❯ src/__tests__/services/agentshield-integration.test.ts 26/30
2139
-  ❯ src/__tests__/services/provider-resolver-edge-cases.test.ts [queued]
2140
-  ❯ src/config/__tests__/remote-config.spec.ts [queued]
2141
-  ❯ src/delegation/__tests__/vc-issuer.test.ts 21/21
2142
-  ❯ src/delegation/__tests__/vc-verifier.test.ts 35/35
2143
-  ❯ src/services/__tests__/access-control.integration.test.ts 0/9
2144
-  ❯ src/services/__tests__/crypto.service.test.ts 34/34
2145
-  ❯ src/services/__tests__/proof-verifier.integration.test.ts 0/13
2146
-  ❯ src/services/__tests__/proof-verifier.test.ts [queued]
2147
-
2148
-  Test Files 9 passed (43)
2149
-  Tests 304 passed (385)
2150
-  Start at 22:55:10
2151
-  Duration 503ms
2152
- [?2026l[?2026hstderr | src/__tests__/runtime/tool-protection-enforcement.test.ts > MCPIRuntimeBase - Tool Protection Enforcement > DelegationRequiredError details > should include required scopes in error
2153
- [MCP-I] BLOCKED: Tool requires delegation but none provided {
2154
- tool: 'protectedTool',
2155
- requiredScopes: [ 'files:write', 'files:read' ],
2156
- agentDid: 'did:key:zmock123...',
2157
- resumeToken: 'resume_3joeal_mi9tfb7w',
2158
- consentUrl: 'https://kya.vouched.id/bouncer/consent?tool=protectedTool&scopes=files%3Awrite%2Cfiles%3Aread&session_id=session123&agent_did=&resume_token=resume_3joeal_mi9tfb7w'
2159
- }
2160
-
2161
-
2162
-  ❯ src/__tests__/cache/tool-protection-cache.test.ts 49/49
2163
-  ❯ src/__tests__/runtime/base.test.ts 0/55
2164
-  ❯ src/__tests__/runtime/route-interception.test.ts 21/21
2165
-  ❯ src/__tests__/runtime/tool-protection-enforcement.test.ts 29/29
2166
-  ❯ src/__tests__/services/agentshield-integration.test.ts 26/30
2167
-  ❯ src/__tests__/services/provider-resolver-edge-cases.test.ts [queued]
2168
-  ❯ src/config/__tests__/remote-config.spec.ts [queued]
2169
-  ❯ src/delegation/__tests__/vc-issuer.test.ts 21/21
2170
-  ❯ src/delegation/__tests__/vc-verifier.test.ts 35/35
2171
-  ❯ src/services/__tests__/access-control.integration.test.ts 0/9
2172
-  ❯ src/services/__tests__/crypto.service.test.ts 34/34
2173
-  ❯ src/services/__tests__/proof-verifier.integration.test.ts 0/13
2174
-  ❯ src/services/__tests__/proof-verifier.test.ts [queued]
2175
-
2176
-  Test Files 9 passed (43)
2177
-  Tests 304 passed (385)
2178
-  Start at 22:55:10
2179
-  Duration 503ms
2180
- [?2026l[?2026hstdout | src/__tests__/runtime/tool-protection-enforcement.test.ts > MCPIRuntimeBase - Tool Protection Enforcement > DelegationRequiredError details > should include consent URL in error
2181
- [MCP-I] Checking tool protection: {
2182
- tool: 'protectedTool',
2183
- agentDid: 'did:key:zmock123...',
2184
- hasDelegation: false
2185
- }
2186
-
2187
-
2188
-  ❯ src/__tests__/cache/tool-protection-cache.test.ts 49/49
2189
-  ❯ src/__tests__/runtime/base.test.ts 0/55
2190
-  ❯ src/__tests__/runtime/route-interception.test.ts 21/21
2191
-  ❯ src/__tests__/runtime/tool-protection-enforcement.test.ts 29/29
2192
-  ❯ src/__tests__/services/agentshield-integration.test.ts 26/30
2193
-  ❯ src/__tests__/services/provider-resolver-edge-cases.test.ts [queued]
2194
-  ❯ src/config/__tests__/remote-config.spec.ts [queued]
2195
-  ❯ src/delegation/__tests__/vc-issuer.test.ts 21/21
2196
-  ❯ src/delegation/__tests__/vc-verifier.test.ts 35/35
2197
-  ❯ src/services/__tests__/access-control.integration.test.ts 0/9
2198
-  ❯ src/services/__tests__/crypto.service.test.ts 34/34
2199
-  ❯ src/services/__tests__/proof-verifier.integration.test.ts 0/13
2200
-  ❯ src/services/__tests__/proof-verifier.test.ts [queued]
2201
-
2202
-  Test Files 9 passed (43)
2203
-  Tests 304 passed (385)
2204
-  Start at 22:55:10
2205
-  Duration 503ms
2206
- [?2026l[?2026hstderr | src/__tests__/runtime/tool-protection-enforcement.test.ts > MCPIRuntimeBase - Tool Protection Enforcement > DelegationRequiredError details > should include consent URL in error
2207
- [MCP-I] BLOCKED: Tool requires delegation but none provided {
2208
- tool: 'protectedTool',
2209
- requiredScopes: [ 'files:write' ],
2210
- agentDid: 'did:key:zmock123...',
2211
- resumeToken: 'resume_3joeal_mi9tfb7x',
2212
- consentUrl: 'https://kya.vouched.id/bouncer/consent?tool=protectedTool&scopes=files%3Awrite&session_id=session123&agent_did=&resume_token=resume_3joeal_mi9tfb7x'
2213
- }
2214
-
2215
-
2216
-  ❯ src/__tests__/cache/tool-protection-cache.test.ts 49/49
2217
-  ❯ src/__tests__/runtime/base.test.ts 0/55
2218
-  ❯ src/__tests__/runtime/route-interception.test.ts 21/21
2219
-  ❯ src/__tests__/runtime/tool-protection-enforcement.test.ts 29/29
2220
-  ❯ src/__tests__/services/agentshield-integration.test.ts 26/30
2221
-  ❯ src/__tests__/services/provider-resolver-edge-cases.test.ts [queued]
2222
-  ❯ src/config/__tests__/remote-config.spec.ts [queued]
2223
-  ❯ src/delegation/__tests__/vc-issuer.test.ts 21/21
2224
-  ❯ src/delegation/__tests__/vc-verifier.test.ts 35/35
2225
-  ❯ src/services/__tests__/access-control.integration.test.ts 0/9
2226
-  ❯ src/services/__tests__/crypto.service.test.ts 34/34
2227
-  ❯ src/services/__tests__/proof-verifier.integration.test.ts 0/13
2228
-  ❯ src/services/__tests__/proof-verifier.test.ts [queued]
2229
-
2230
-  Test Files 9 passed (43)
2231
-  Tests 304 passed (385)
2232
-  Start at 22:55:10
2233
-  Duration 503ms
2234
- [?2026l[?2026hstdout | src/__tests__/runtime/tool-protection-enforcement.test.ts > MCPIRuntimeBase - Tool Protection Enforcement > DelegationRequiredError details > should include resume token in error
2235
- [MCP-I] Checking tool protection: {
2236
- tool: 'protectedTool',
2237
- agentDid: 'did:key:zmock123...',
2238
- hasDelegation: false
2239
- }
2240
-
2241
-
2242
-  ❯ src/__tests__/cache/tool-protection-cache.test.ts 49/49
2243
-  ❯ src/__tests__/runtime/base.test.ts 0/55
2244
-  ❯ src/__tests__/runtime/route-interception.test.ts 21/21
2245
-  ❯ src/__tests__/runtime/tool-protection-enforcement.test.ts 29/29
2246
-  ❯ src/__tests__/services/agentshield-integration.test.ts 26/30
2247
-  ❯ src/__tests__/services/provider-resolver-edge-cases.test.ts [queued]
2248
-  ❯ src/config/__tests__/remote-config.spec.ts [queued]
2249
-  ❯ src/delegation/__tests__/vc-issuer.test.ts 21/21
2250
-  ❯ src/delegation/__tests__/vc-verifier.test.ts 35/35
2251
-  ❯ src/services/__tests__/access-control.integration.test.ts 0/9
2252
-  ❯ src/services/__tests__/crypto.service.test.ts 34/34
2253
-  ❯ src/services/__tests__/proof-verifier.integration.test.ts 0/13
2254
-  ❯ src/services/__tests__/proof-verifier.test.ts [queued]
2255
-
2256
-  Test Files 9 passed (43)
2257
-  Tests 304 passed (385)
2258
-  Start at 22:55:10
2259
-  Duration 503ms
2260
- [?2026l[?2026hstderr | src/__tests__/runtime/tool-protection-enforcement.test.ts > MCPIRuntimeBase - Tool Protection Enforcement > DelegationRequiredError details > should include resume token in error
2261
- [MCP-I] BLOCKED: Tool requires delegation but none provided {
2262
- tool: 'protectedTool',
2263
- requiredScopes: [ 'files:write' ],
2264
- agentDid: 'did:key:zmock123...',
2265
- resumeToken: 'resume_3joe9q_mi9tfb7x',
2266
- consentUrl: 'https://kya.vouched.id/bouncer/consent?tool=protectedTool&scopes=files%3Awrite&session_id=session123&agent_did=&resume_token=resume_3joe9q_mi9tfb7x'
2267
- }
2268
-
2269
-
2270
-  ❯ src/__tests__/cache/tool-protection-cache.test.ts 49/49
2271
-  ❯ src/__tests__/runtime/base.test.ts 0/55
2272
-  ❯ src/__tests__/runtime/route-interception.test.ts 21/21
2273
-  ❯ src/__tests__/runtime/tool-protection-enforcement.test.ts 29/29
2274
-  ❯ src/__tests__/services/agentshield-integration.test.ts 26/30
2275
-  ❯ src/__tests__/services/provider-resolver-edge-cases.test.ts [queued]
2276
-  ❯ src/config/__tests__/remote-config.spec.ts [queued]
2277
-  ❯ src/delegation/__tests__/vc-issuer.test.ts 21/21
2278
-  ❯ src/delegation/__tests__/vc-verifier.test.ts 35/35
2279
-  ❯ src/services/__tests__/access-control.integration.test.ts 0/9
2280
-  ❯ src/services/__tests__/crypto.service.test.ts 34/34
2281
-  ❯ src/services/__tests__/proof-verifier.integration.test.ts 0/13
2282
-  ❯ src/services/__tests__/proof-verifier.test.ts [queued]
2283
-
2284
-  Test Files 9 passed (43)
2285
-  Tests 304 passed (385)
2286
-  Start at 22:55:10
2287
-  Duration 503ms
2288
- [?2026l[?2026hstdout | src/__tests__/runtime/tool-protection-enforcement.test.ts > MCPIRuntimeBase - Tool Protection Enforcement > DelegationRequiredError details > should include intercepted call context in error
2289
- [MCP-I] Checking tool protection: {
2290
- tool: 'protectedTool',
2291
- agentDid: 'did:key:zmock123...',
2292
- hasDelegation: false
2293
- }
2294
-
2295
-
2296
-  ❯ src/__tests__/cache/tool-protection-cache.test.ts 49/49
2297
-  ❯ src/__tests__/runtime/base.test.ts 0/55
2298
-  ❯ src/__tests__/runtime/route-interception.test.ts 21/21
2299
-  ❯ src/__tests__/runtime/tool-protection-enforcement.test.ts 29/29
2300
-  ❯ src/__tests__/services/agentshield-integration.test.ts 26/30
2301
-  ❯ src/__tests__/services/provider-resolver-edge-cases.test.ts [queued]
2302
-  ❯ src/config/__tests__/remote-config.spec.ts [queued]
2303
-  ❯ src/delegation/__tests__/vc-issuer.test.ts 21/21
2304
-  ❯ src/delegation/__tests__/vc-verifier.test.ts 35/35
2305
-  ❯ src/services/__tests__/access-control.integration.test.ts 0/9
2306
-  ❯ src/services/__tests__/crypto.service.test.ts 34/34
2307
-  ❯ src/services/__tests__/proof-verifier.integration.test.ts 0/13
2308
-  ❯ src/services/__tests__/proof-verifier.test.ts [queued]
2309
-
2310
-  Test Files 9 passed (43)
2311
-  Tests 304 passed (385)
2312
-  Start at 22:55:10
2313
-  Duration 503ms
2314
- [?2026l[?2026hstderr | src/__tests__/runtime/tool-protection-enforcement.test.ts > MCPIRuntimeBase - Tool Protection Enforcement > DelegationRequiredError details > should include intercepted call context in error
2315
- [MCP-I] BLOCKED: Tool requires delegation but none provided {
2316
- tool: 'protectedTool',
2317
- requiredScopes: [ 'files:write' ],
2318
- agentDid: 'did:key:zmock123...',
2319
- resumeToken: 'resume_cn1syl_mi9tfb7x',
2320
- consentUrl: 'https://kya.vouched.id/bouncer/consent?tool=protectedTool&scopes=files%3Awrite&session_id=session123&agent_did=&resume_token=resume_cn1syl_mi9tfb7x'
2321
- }
2322
-
2323
-
2324
-  ❯ src/__tests__/cache/tool-protection-cache.test.ts 49/49
2325
-  ❯ src/__tests__/runtime/base.test.ts 0/55
2326
-  ❯ src/__tests__/runtime/route-interception.test.ts 21/21
2327
-  ❯ src/__tests__/runtime/tool-protection-enforcement.test.ts 29/29
2328
-  ❯ src/__tests__/services/agentshield-integration.test.ts 26/30
2329
-  ❯ src/__tests__/services/provider-resolver-edge-cases.test.ts [queued]
2330
-  ❯ src/config/__tests__/remote-config.spec.ts [queued]
2331
-  ❯ src/delegation/__tests__/vc-issuer.test.ts 21/21
2332
-  ❯ src/delegation/__tests__/vc-verifier.test.ts 35/35
2333
-  ❯ src/services/__tests__/access-control.integration.test.ts 0/9
2334
-  ❯ src/services/__tests__/crypto.service.test.ts 34/34
2335
-  ❯ src/services/__tests__/proof-verifier.integration.test.ts 0/13
2336
-  ❯ src/services/__tests__/proof-verifier.test.ts [queued]
2337
-
2338
-  Test Files 9 passed (43)
2339
-  Tests 304 passed (385)
2340
-  Start at 22:55:10
2341
-  Duration 503ms
2342
- [?2026l[?2026hstdout | src/__tests__/runtime/tool-protection-enforcement.test.ts > MCPIRuntimeBase - Tool Protection Enforcement > audit logging > should log tool protection check when audit enabled
2343
- [MCP-I] Checking tool protection: {
2344
- tool: 'testTool',
2345
- agentDid: 'did:key:zmock123...',
2346
- hasDelegation: false
2347
- }
2348
-
2349
- stdout | src/__tests__/runtime/tool-protection-enforcement.test.ts > MCPIRuntimeBase - Tool Protection Enforcement > audit logging > should log tool protection check when audit enabled
2350
- [MCP-I] Tool protection check passed (no delegation required) {
2351
- tool: 'testTool',
2352
- agentDid: 'did:key:zmock123...',
2353
- reason: 'Tool not configured to require delegation'
2354
- }
2355
-
2356
- stdout | src/__tests__/runtime/tool-protection-enforcement.test.ts > MCPIRuntimeBase - Tool Protection Enforcement > audit logging > should log blocked tool call when audit enabled
2357
- [MCP-I] Checking tool protection: {
2358
- tool: 'protectedTool',
2359
- agentDid: 'did:key:zmock123...',
2360
- hasDelegation: false
2361
- }
2362
-
2363
- stdout | src/__tests__/runtime/tool-protection-enforcement.test.ts > MCPIRuntimeBase - Tool Protection Enforcement > tool protection service integration > should use agent DID from identity for protection check
2364
- [MCP-I] Checking tool protection: {
2365
- tool: 'testTool',
2366
- agentDid: 'did:key:zmock123...',
2367
- hasDelegation: false
2368
- }
2369
-
2370
- stdout | src/__tests__/runtime/tool-protection-enforcement.test.ts > MCPIRuntimeBase - Tool Protection Enforcement > tool protection service integration > should use agent DID from identity for protection check
2371
- [MCP-I] Tool protection check passed (no delegation required) {
2372
- tool: 'testTool',
2373
- agentDid: 'did:key:zmock123...',
2374
- reason: 'Tool not configured to require delegation'
2375
- }
2376
-
2377
- stdout | src/__tests__/runtime/tool-protection-enforcement.test.ts > MCPIRuntimeBase - Tool Protection Enforcement > tool protection service integration > should handle tool protection service errors gracefully
2378
- [MCP-I] Checking tool protection: {
2379
- tool: 'testTool',
2380
- agentDid: 'did:key:zmock123...',
2381
- hasDelegation: false
2382
- }
2383
-
2384
- stdout | src/__tests__/runtime/tool-protection-enforcement.test.ts > MCPIRuntimeBase - Tool Protection Enforcement > edge cases > should handle empty required scopes array
2385
- [MCP-I] Checking tool protection: {
2386
- tool: 'protectedTool',
2387
- agentDid: 'did:key:zmock123...',
2388
- hasDelegation: false
2389
- }
2390
-
2391
-
2392
-  ❯ src/__tests__/cache/tool-protection-cache.test.ts 49/49
2393
-  ❯ src/__tests__/runtime/base.test.ts 0/55
2394
-  ❯ src/__tests__/runtime/route-interception.test.ts 21/21
2395
-  ❯ src/__tests__/runtime/tool-protection-enforcement.test.ts 29/29
2396
-  ❯ src/__tests__/services/agentshield-integration.test.ts 26/30
2397
-  ❯ src/__tests__/services/provider-resolver-edge-cases.test.ts [queued]
2398
-  ❯ src/config/__tests__/remote-config.spec.ts [queued]
2399
-  ❯ src/delegation/__tests__/vc-issuer.test.ts 21/21
2400
-  ❯ src/delegation/__tests__/vc-verifier.test.ts 35/35
2401
-  ❯ src/services/__tests__/access-control.integration.test.ts 0/9
2402
-  ❯ src/services/__tests__/crypto.service.test.ts 34/34
2403
-  ❯ src/services/__tests__/proof-verifier.integration.test.ts 0/13
2404
-  ❯ src/services/__tests__/proof-verifier.test.ts [queued]
2405
-
2406
-  Test Files 9 passed (43)
2407
-  Tests 304 passed (385)
2408
-  Start at 22:55:10
2409
-  Duration 503ms
2410
- [?2026l[?2026hstderr | src/__tests__/runtime/tool-protection-enforcement.test.ts > MCPIRuntimeBase - Tool Protection Enforcement > edge cases > should handle empty required scopes array
2411
- [MCP-I] BLOCKED: Tool requires delegation but none provided {
2412
- tool: 'protectedTool',
2413
- requiredScopes: [],
2414
- agentDid: 'did:key:zmock123...',
2415
- resumeToken: 'resume_3jodpx_mi9tfb7z',
2416
- consentUrl: 'https://kya.vouched.id/bouncer/consent?tool=protectedTool&scopes=&session_id=session123&agent_did=&resume_token=resume_3jodpx_mi9tfb7z'
2417
- }
2418
-
2419
-
2420
-  ❯ src/__tests__/cache/tool-protection-cache.test.ts 49/49
2421
-  ❯ src/__tests__/runtime/base.test.ts 0/55
2422
-  ❯ src/__tests__/runtime/route-interception.test.ts 21/21
2423
-  ❯ src/__tests__/runtime/tool-protection-enforcement.test.ts 29/29
2424
-  ❯ src/__tests__/services/agentshield-integration.test.ts 26/30
2425
-  ❯ src/__tests__/services/provider-resolver-edge-cases.test.ts [queued]
2426
-  ❯ src/config/__tests__/remote-config.spec.ts [queued]
2427
-  ❯ src/delegation/__tests__/vc-issuer.test.ts 21/21
2428
-  ❯ src/delegation/__tests__/vc-verifier.test.ts 35/35
2429
-  ❯ src/services/__tests__/access-control.integration.test.ts 0/9
2430
-  ❯ src/services/__tests__/crypto.service.test.ts 34/34
2431
-  ❯ src/services/__tests__/proof-verifier.integration.test.ts 0/13
2432
-  ❯ src/services/__tests__/proof-verifier.test.ts [queued]
2433
-
2434
-  Test Files 9 passed (43)
2435
-  Tests 304 passed (385)
2436
-  Start at 22:55:10
2437
-  Duration 503ms
2438
- [?2026l[?2026hstdout | src/__tests__/runtime/tool-protection-enforcement.test.ts > MCPIRuntimeBase - Tool Protection Enforcement > edge cases > should handle multiple required scopes
2439
- [MCP-I] Checking tool protection: {
2440
- tool: 'protectedTool',
2441
- agentDid: 'did:key:zmock123...',
2442
- hasDelegation: false
2443
- }
2444
-
2445
-
2446
-  ❯ src/__tests__/cache/tool-protection-cache.test.ts 49/49
2447
-  ❯ src/__tests__/runtime/base.test.ts 0/55
2448
-  ❯ src/__tests__/runtime/route-interception.test.ts 21/21
2449
-  ❯ src/__tests__/runtime/tool-protection-enforcement.test.ts 29/29
2450
-  ❯ src/__tests__/services/agentshield-integration.test.ts 26/30
2451
-  ❯ src/__tests__/services/provider-resolver-edge-cases.test.ts [queued]
2452
-  ❯ src/config/__tests__/remote-config.spec.ts [queued]
2453
-  ❯ src/delegation/__tests__/vc-issuer.test.ts 21/21
2454
-  ❯ src/delegation/__tests__/vc-verifier.test.ts 35/35
2455
-  ❯ src/services/__tests__/access-control.integration.test.ts 0/9
2456
-  ❯ src/services/__tests__/crypto.service.test.ts 34/34
2457
-  ❯ src/services/__tests__/proof-verifier.integration.test.ts 0/13
2458
-  ❯ src/services/__tests__/proof-verifier.test.ts [queued]
2459
-
2460
-  Test Files 9 passed (43)
2461
-  Tests 304 passed (385)
2462
-  Start at 22:55:10
2463
-  Duration 503ms
2464
- [?2026l[?2026hstderr | src/__tests__/runtime/tool-protection-enforcement.test.ts > MCPIRuntimeBase - Tool Protection Enforcement > edge cases > should handle multiple required scopes
2465
- [MCP-I] BLOCKED: Tool requires delegation but none provided {
2466
- tool: 'protectedTool',
2467
- requiredScopes: [ 'scope1', 'scope2', 'scope3' ],
2468
- agentDid: 'did:key:zmock123...',
2469
- resumeToken: 'resume_3jodpx_mi9tfb7z',
2470
- consentUrl: 'https://kya.vouched.id/bouncer/consent?tool=protectedTool&scopes=scope1%2Cscope2%2Cscope3&session_id=session123&agent_did=&resume_token=resume_3jodpx_mi9tfb7z'
2471
- }
2472
-
2473
-
2474
-  ❯ src/__tests__/cache/tool-protection-cache.test.ts 49/49
2475
-  ❯ src/__tests__/runtime/base.test.ts 0/55
2476
-  ❯ src/__tests__/runtime/route-interception.test.ts 21/21
2477
-  ❯ src/__tests__/runtime/tool-protection-enforcement.test.ts 29/29
2478
-  ❯ src/__tests__/services/agentshield-integration.test.ts 26/30
2479
-  ❯ src/__tests__/services/provider-resolver-edge-cases.test.ts [queued]
2480
-  ❯ src/config/__tests__/remote-config.spec.ts [queued]
2481
-  ❯ src/delegation/__tests__/vc-issuer.test.ts 21/21
2482
-  ❯ src/delegation/__tests__/vc-verifier.test.ts 35/35
2483
-  ❯ src/services/__tests__/access-control.integration.test.ts 0/9
2484
-  ❯ src/services/__tests__/crypto.service.test.ts 34/34
2485
-  ❯ src/services/__tests__/proof-verifier.integration.test.ts 0/13
2486
-  ❯ src/services/__tests__/proof-verifier.test.ts [queued]
2487
-
2488
-  Test Files 9 passed (43)
2489
-  Tests 304 passed (385)
2490
-  Start at 22:55:10
2491
-  Duration 503ms
2492
- [?2026l[?2026hstdout | src/__tests__/runtime/tool-protection-enforcement.test.ts > MCPIRuntimeBase - Tool Protection Enforcement > edge cases > should handle session without id
2493
- [MCP-I] Checking tool protection: {
2494
- tool: 'protectedTool',
2495
- agentDid: 'did:key:zmock123...',
2496
- hasDelegation: false
2497
- }
2498
-
2499
-
2500
-  ❯ src/__tests__/cache/tool-protection-cache.test.ts 49/49
2501
-  ❯ src/__tests__/runtime/base.test.ts 0/55
2502
-  ❯ src/__tests__/runtime/route-interception.test.ts 21/21
2503
-  ❯ src/__tests__/runtime/tool-protection-enforcement.test.ts 29/29
2504
-  ❯ src/__tests__/services/agentshield-integration.test.ts 26/30
2505
-  ❯ src/__tests__/services/provider-resolver-edge-cases.test.ts [queued]
2506
-  ❯ src/config/__tests__/remote-config.spec.ts [queued]
2507
-  ❯ src/delegation/__tests__/vc-issuer.test.ts 21/21
2508
-  ❯ src/delegation/__tests__/vc-verifier.test.ts 35/35
2509
-  ❯ src/services/__tests__/access-control.integration.test.ts 0/9
2510
-  ❯ src/services/__tests__/crypto.service.test.ts 34/34
2511
-  ❯ src/services/__tests__/proof-verifier.integration.test.ts 0/13
2512
-  ❯ src/services/__tests__/proof-verifier.test.ts [queued]
2513
-
2514
-  Test Files 9 passed (43)
2515
-  Tests 304 passed (385)
2516
-  Start at 22:55:10
2517
-  Duration 503ms
2518
- [?2026l[?2026hstderr | src/__tests__/runtime/tool-protection-enforcement.test.ts > MCPIRuntimeBase - Tool Protection Enforcement > edge cases > should handle session without id
2519
- [MCP-I] BLOCKED: Tool requires delegation but none provided {
2520
- tool: 'protectedTool',
2521
- requiredScopes: [ 'files:write' ],
2522
- agentDid: 'did:key:zmock123...',
2523
- resumeToken: 'resume_9idmot_mi9tfb7z',
2524
- consentUrl: 'https://kya.vouched.id/bouncer/consent?tool=protectedTool&scopes=files%3Awrite&session_id=&agent_did=&resume_token=resume_9idmot_mi9tfb7z'
2525
- }
2526
-
2527
-
2528
-  ❯ src/__tests__/cache/tool-protection-cache.test.ts 49/49
2529
-  ❯ src/__tests__/runtime/base.test.ts 0/55
2530
-  ❯ src/__tests__/runtime/route-interception.test.ts 21/21
2531
-  ❯ src/__tests__/runtime/tool-protection-enforcement.test.ts 29/29
2532
-  ❯ src/__tests__/services/agentshield-integration.test.ts 26/30
2533
-  ❯ src/__tests__/services/provider-resolver-edge-cases.test.ts [queued]
2534
-  ❯ src/config/__tests__/remote-config.spec.ts [queued]
2535
-  ❯ src/delegation/__tests__/vc-issuer.test.ts 21/21
2536
-  ❯ src/delegation/__tests__/vc-verifier.test.ts 35/35
2537
-  ❯ src/services/__tests__/access-control.integration.test.ts 0/9
2538
-  ❯ src/services/__tests__/crypto.service.test.ts 34/34
2539
-  ❯ src/services/__tests__/proof-verifier.integration.test.ts 0/13
2540
-  ❯ src/services/__tests__/proof-verifier.test.ts [queued]
2541
-
2542
-  Test Files 9 passed (43)
2543
-  Tests 304 passed (385)
2544
-  Start at 22:55:10
2545
-  Duration 503ms
2546
- [?2026l[?2026hstdout | src/__tests__/runtime/tool-protection-enforcement.test.ts > MCPIRuntimeBase - Tool Protection Enforcement > edge cases > should handle handler errors independently of protection
2547
- [MCP-I] Checking tool protection: {
2548
- tool: 'errorTool',
2549
- agentDid: 'did:key:zmock123...',
2550
- hasDelegation: false
2551
- }
2552
-
2553
- stdout | src/__tests__/runtime/tool-protection-enforcement.test.ts > MCPIRuntimeBase - Tool Protection Enforcement > edge cases > should handle handler errors independently of protection
2554
- [MCP-I] Tool protection check passed (no delegation required) {
2555
- tool: 'errorTool',
2556
- agentDid: 'did:key:zmock123...',
2557
- reason: 'Tool not configured to require delegation'
2558
- }
2559
-
2560
- ✓ src/__tests__/cache/tool-protection-cache.test.ts (49 tests) 164ms
2561
-
2562
-  ❯ src/__tests__/cache/tool-protection-cache.test.ts 49/49
2563
-  ❯ src/__tests__/runtime/base.test.ts 0/55
2564
-  ❯ src/__tests__/runtime/route-interception.test.ts 21/21
2565
-  ❯ src/__tests__/runtime/tool-protection-enforcement.test.ts 29/29
2566
-  ❯ src/__tests__/services/agentshield-integration.test.ts 26/30
2567
-  ❯ src/__tests__/services/provider-resolver-edge-cases.test.ts [queued]
2568
-  ❯ src/config/__tests__/remote-config.spec.ts [queued]
2569
-  ❯ src/delegation/__tests__/vc-issuer.test.ts 21/21
2570
-  ❯ src/delegation/__tests__/vc-verifier.test.ts 35/35
2571
-  ❯ src/services/__tests__/access-control.integration.test.ts 0/9
2572
-  ❯ src/services/__tests__/crypto.service.test.ts 34/34
2573
-  ❯ src/services/__tests__/proof-verifier.integration.test.ts 0/13
2574
-  ❯ src/services/__tests__/proof-verifier.test.ts [queued]
2575
-
2576
-  Test Files 9 passed (43)
2577
-  Tests 304 passed (385)
2578
-  Start at 22:55:10
2579
-  Duration 503ms
2580
- [?2026l[?2026hstderr | src/services/__tests__/access-control.integration.test.ts > AccessControlApiService Integration > Proof Submission Flow > should submit proof end-to-end
2581
- [AccessControl] 🔍 RAW API RESPONSE (before parsing): {
2582
- correlationId: 'b53d6558-29a7-4f75-a41b-ab2e6fb1ec94',
2583
- status: 200,
2584
- statusText: '',
2585
- headers: { 'content-type': 'application/json' },
2586
- responseTextLength: 100,
2587
- responseTextPreview: '{"success":true,"accepted":1,"rejected":0,"outcomes":{"success":1,"failed":0,"blocked":0,"error":0}}',
2588
- fullResponseText: '{"success":true,"accepted":1,"rejected":0,"outcomes":{"success":1,"failed":0,"blocked":0,"error":0}}'
2589
- }
2590
- [AccessControl] 🔍 PARSED RESPONSE DATA: {
2591
- correlationId: 'b53d6558-29a7-4f75-a41b-ab2e6fb1ec94',
2592
- status: 200,
2593
- responseDataType: 'object',
2594
- responseDataKeys: [ 'success', 'accepted', 'rejected', 'outcomes' ],
2595
- responseData: '{\n' +
2596
- ' "success": true,\n' +
2597
- ' "accepted": 1,\n' +
2598
- ' "rejected": 0,\n' +
2599
- ' "outcomes": {\n' +
2600
- ' "success": 1,\n' +
2601
- ' "failed": 0,\n' +
2602
- ' "blocked": 0,\n' +
2603
- ' "error": 0\n' +
2604
- ' }\n' +
2605
- '}'
2606
- }
2607
- [AccessControl] Raw response received: {
2608
- "success": true,
2609
- "accepted": 1,
2610
- "rejected": 0,
2611
- "outcomes": {
2612
- "success": 1,
2613
- "failed": 0,
2614
- "blocked": 0,
2615
- "error": 0
2616
- }
2617
- }
2618
-
2619
- stderr | src/services/__tests__/access-control.integration.test.ts > AccessControlApiService Integration > Proof Submission Flow > should handle proof submission with errors
2620
- [AccessControl] 🔍 RAW API RESPONSE (before parsing): {
2621
- correlationId: '64ba7812-ac73-45b4-8348-9a66bff0346d',
2622
- status: 200,
2623
- statusText: '',
2624
- headers: { 'content-type': 'application/json' },
2625
- responseTextLength: 200,
2626
- responseTextPreview: '{"success":true,"accepted":0,"rejected":1,"outcomes":{"success":0,"failed":1,"blocked":0,"error":0},"errors":[{"proof_index":0,"error":{"code":"invalid_signature","message":"Invalid JWS signature"}}]}',
2627
- fullResponseText: '{"success":true,"accepted":0,"rejected":1,"outcomes":{"success":0,"failed":1,"blocked":0,"error":0},"errors":[{"proof_index":0,"error":{"code":"invalid_signature","message":"Invalid JWS signature"}}]}'
2628
- }
2629
- [AccessControl] 🔍 PARSED RESPONSE DATA: {
2630
- correlationId: '64ba7812-ac73-45b4-8348-9a66bff0346d',
2631
- status: 200,
2632
- responseDataType: 'object',
2633
- responseDataKeys: [ 'success', 'accepted', 'rejected', 'outcomes', 'errors' ],
2634
- responseData: '{\n' +
2635
- ' "success": true,\n' +
2636
- ' "accepted": 0,\n' +
2637
- ' "rejected": 1,\n' +
2638
- ' "outcomes": {\n' +
2639
- ' "success": 0,\n' +
2640
- ' "failed": 1,\n' +
2641
- ' "blocked": 0,\n' +
2642
- ' "error": 0\n' +
2643
- ' },\n' +
2644
- ' "errors": [\n' +
2645
- ' {\n' +
2646
- ' "proof_index": 0,\n' +
2647
- ' "error": {\n' +
2648
- ' "code": "invalid_signature",\n' +
2649
- ' "message": "Invalid JWS signature"\n' +
2650
- ' }\n' +
2651
- ' }\n' +
2652
- ' ]\n' +
2653
- '}'
2654
- }
2655
- [AccessControl] Raw response received: {
2656
- "success": true,
2657
- "accepted": 0,
2658
- "rejected": 1,
2659
- "outcomes": {
2660
- "success": 0,
2661
- "failed": 1,
2662
- "blocked": 0,
2663
- "error": 0
2664
- },
2665
- "errors": [
2666
- {
2667
- "proof_index": 0,
2668
- "error": {
2669
- "code": "invalid_signature",
2670
- "message": "Invalid JWS signature"
2671
- }
2672
- }
2673
- ]
2674
- }
2675
-
2676
- stderr | src/services/__tests__/access-control.integration.test.ts > AccessControlApiService Integration > Proof Verification Flow > should verify proof using ProofVerifier
2677
- [CryptoService] Key ID mismatch
2678
-
2679
-
2680
-  ❯ src/__tests__/cache/tool-protection-cache.test.ts 49/49
2681
-  ❯ src/__tests__/runtime/base.test.ts 0/55
2682
-  ❯ src/__tests__/runtime/route-interception.test.ts 21/21
2683
-  ❯ src/__tests__/runtime/tool-protection-enforcement.test.ts 29/29
2684
-  ❯ src/__tests__/services/agentshield-integration.test.ts 26/30
2685
-  ❯ src/__tests__/services/provider-resolver-edge-cases.test.ts [queued]
2686
-  ❯ src/config/__tests__/remote-config.spec.ts [queued]
2687
-  ❯ src/delegation/__tests__/vc-issuer.test.ts 21/21
2688
-  ❯ src/delegation/__tests__/vc-verifier.test.ts 35/35
2689
-  ❯ src/services/__tests__/access-control.integration.test.ts 0/9
2690
-  ❯ src/services/__tests__/crypto.service.test.ts 34/34
2691
-  ❯ src/services/__tests__/proof-verifier.integration.test.ts 0/13
2692
-  ❯ src/services/__tests__/proof-verifier.test.ts [queued]
2693
-
2694
-  Test Files 9 passed (43)
2695
-  Tests 304 passed (385)
2696
-  Start at 22:55:10
2697
-  Duration 503ms
2698
- [?2026l[?2026h ✓ src/__tests__/runtime/tool-protection-enforcement.test.ts (29 tests) 22ms
2699
- ✓ src/delegation/__tests__/vc-issuer.test.ts (21 tests) 144ms
2700
- ✓ src/__tests__/runtime/route-interception.test.ts (21 tests) 36ms
2701
-
2702
-  ❯ src/__tests__/cache/tool-protection-cache.test.ts 49/49
2703
-  ❯ src/__tests__/runtime/base.test.ts 0/55
2704
-  ❯ src/__tests__/runtime/route-interception.test.ts 21/21
2705
-  ❯ src/__tests__/runtime/tool-protection-enforcement.test.ts 29/29
2706
-  ❯ src/__tests__/services/agentshield-integration.test.ts 26/30
2707
-  ❯ src/__tests__/services/provider-resolver-edge-cases.test.ts [queued]
2708
-  ❯ src/config/__tests__/remote-config.spec.ts [queued]
2709
-  ❯ src/delegation/__tests__/vc-issuer.test.ts 21/21
2710
-  ❯ src/delegation/__tests__/vc-verifier.test.ts 35/35
2711
-  ❯ src/services/__tests__/access-control.integration.test.ts 0/9
2712
-  ❯ src/services/__tests__/crypto.service.test.ts 34/34
2713
-  ❯ src/services/__tests__/proof-verifier.integration.test.ts 0/13
2714
-  ❯ src/services/__tests__/proof-verifier.test.ts [queued]
2715
-
2716
-  Test Files 9 passed (43)
2717
-  Tests 304 passed (385)
2718
-  Start at 22:55:10
2719
-  Duration 503ms
2720
- [?2026l[?2026hstderr | src/services/__tests__/proof-verifier.integration.test.ts > ProofVerifier Integration - Real DID Resolution > did:web Resolution (HTTP) > should handle HTTP errors gracefully
2721
- [ProofVerifier] Failed to fetch public key from DID: Error: Failed to resolve did:web:nonexistent-domain-that-does-not-exist-12345.com: fetch failed
2722
- at Object.resolveDID (/Users/dylanhobbs/Documents/@kya-os/xmcp-i/packages/mcp-i-core/src/services/__tests__/proof-verifier.integration.test.ts:143:19)
2723
-  at processTicksAndRejections (node:internal/process/task_queues:103:5)
2724
- at ProofVerifier.fetchPublicKeyFromDID (/Users/dylanhobbs/Documents/@kya-os/xmcp-i/packages/mcp-i-core/src/services/proof-verifier.ts:348:22)
2725
- at /Users/dylanhobbs/Documents/@kya-os/xmcp-i/packages/mcp-i-core/src/services/__tests__/proof-verifier.integration.test.ts:252:7
2726
- at file:///Users/dylanhobbs/Documents/@kya-os/xmcp-i/node_modules/.pnpm/@vitest+runner@4.0.5/node_modules/@vitest/runner/dist/index.js:753:20
2727
-
2728
- stderr | src/services/__tests__/proof-verifier.integration.test.ts > ProofVerifier Integration - Real DID Resolution > did:web Resolution (HTTP) > should handle HTTP errors gracefully
2729
- [ProofVerifier] Failed to fetch public key from DID: Error: Failed to resolve did:web:nonexistent-domain-that-does-not-exist-12345.com: fetch failed
2730
- at Object.resolveDID (/Users/dylanhobbs/Documents/@kya-os/xmcp-i/packages/mcp-i-core/src/services/__tests__/proof-verifier.integration.test.ts:143:19)
2731
-  at processTicksAndRejections (node:internal/process/task_queues:103:5)
2732
- at ProofVerifier.fetchPublicKeyFromDID (/Users/dylanhobbs/Documents/@kya-os/xmcp-i/packages/mcp-i-core/src/services/proof-verifier.ts:348:22)
2733
- at /Users/dylanhobbs/Documents/@kya-os/xmcp-i/packages/mcp-i-core/src/services/__tests__/proof-verifier.integration.test.ts:257:9
2734
- at file:///Users/dylanhobbs/Documents/@kya-os/xmcp-i/node_modules/.pnpm/@vitest+runner@4.0.5/node_modules/@vitest/runner/dist/index.js:753:20
2735
-
2736
-
2737
-  ❯ src/__tests__/cache/tool-protection-cache.test.ts 49/49
2738
-  ❯ src/__tests__/runtime/base.test.ts 0/55
2739
-  ❯ src/__tests__/runtime/route-interception.test.ts 21/21
2740
-  ❯ src/__tests__/runtime/tool-protection-enforcement.test.ts 29/29
2741
-  ❯ src/__tests__/services/agentshield-integration.test.ts 26/30
2742
-  ❯ src/__tests__/services/provider-resolver-edge-cases.test.ts [queued]
2743
-  ❯ src/config/__tests__/remote-config.spec.ts [queued]
2744
-  ❯ src/delegation/__tests__/vc-issuer.test.ts 21/21
2745
-  ❯ src/delegation/__tests__/vc-verifier.test.ts 35/35
2746
-  ❯ src/services/__tests__/access-control.integration.test.ts 0/9
2747
-  ❯ src/services/__tests__/crypto.service.test.ts 34/34
2748
-  ❯ src/services/__tests__/proof-verifier.integration.test.ts 0/13
2749
-  ❯ src/services/__tests__/proof-verifier.test.ts [queued]
2750
-
2751
-  Test Files 9 passed (43)
2752
-  Tests 304 passed (385)
2753
-  Start at 22:55:10
2754
-  Duration 503ms
2755
- [?2026l[?2026h ✓ src/services/__tests__/proof-verifier.integration.test.ts (13 tests | 1 skipped) 86ms
2756
- ✓ src/__tests__/runtime/base.test.ts (55 tests) 16ms
2757
-
2758
-  ❯ src/__tests__/identity/user-did-manager.test.ts [queued]
2759
-  ❯ src/__tests__/integration/full-flow.test.ts 0/21
2760
-  ❯ src/__tests__/providers/base.test.ts 14/14
2761
-  ❯ src/__tests__/providers/memory.test.ts [queued]
2762
-  ❯ src/__tests__/regression/phase2-regression.test.ts [queued]
2763
-  ❯ src/__tests__/runtime/base-extensions.test.ts 38/38
2764
-  ❯ src/__tests__/runtime/base.test.ts 55/55
2765
-  ❯ src/__tests__/services/agentshield-integration.test.ts 26/30
2766
-  ❯ src/__tests__/services/provider-resolver-edge-cases.test.ts [queued]
2767
-  ❯ src/config/__tests__/remote-config.spec.ts 9/9
2768
-  ❯ src/delegation/__tests__/cascading-revocation.test.ts [queued]
2769
-  ❯ src/services/__tests__/access-control.integration.test.ts 9/9
2770
-  ❯ src/services/__tests__/proof-verifier.test.ts 21/21
2771
-
2772
-  Test Files 16 passed (43)
2773
-  Tests 462 passed | 1 skipped (488)
2774
-  Start at 22:55:10
2775
-  Duration 602ms
2776
- [?2026l[?2026hstderr | src/services/__tests__/proof-verifier.test.ts > ProofVerifier Security > Signature Verification > should handle signature verification errors gracefully
2777
- [CryptoService] Ed25519 verification error: Error: Crypto error
2778
- at /Users/dylanhobbs/Documents/@kya-os/xmcp-i/packages/mcp-i-core/src/services/__tests__/proof-verifier.test.ts:328:9
2779
- at file:///Users/dylanhobbs/Documents/@kya-os/xmcp-i/node_modules/.pnpm/@vitest+runner@4.0.5/node_modules/@vitest/runner/dist/index.js:157:11
2780
- at file:///Users/dylanhobbs/Documents/@kya-os/xmcp-i/node_modules/.pnpm/@vitest+runner@4.0.5/node_modules/@vitest/runner/dist/index.js:753:26
2781
- at file:///Users/dylanhobbs/Documents/@kya-os/xmcp-i/node_modules/.pnpm/@vitest+runner@4.0.5/node_modules/@vitest/runner/dist/index.js:1636:20
2782
- at new Promise (<anonymous>)
2783
- at runWithTimeout (file:///Users/dylanhobbs/Documents/@kya-os/xmcp-i/node_modules/.pnpm/@vitest+runner@4.0.5/node_modules/@vitest/runner/dist/index.js:1602:10)
2784
- at runTest (file:///Users/dylanhobbs/Documents/@kya-os/xmcp-i/node_modules/.pnpm/@vitest+runner@4.0.5/node_modules/@vitest/runner/dist/index.js:1309:12)
2785
-  at processTicksAndRejections (node:internal/process/task_queues:103:5)
2786
- at runSuite (file:///Users/dylanhobbs/Documents/@kya-os/xmcp-i/node_modules/.pnpm/@vitest+runner@4.0.5/node_modules/@vitest/runner/dist/index.js:1468:8)
2787
- at runSuite (file:///Users/dylanhobbs/Documents/@kya-os/xmcp-i/node_modules/.pnpm/@vitest+runner@4.0.5/node_modules/@vitest/runner/dist/index.js:1468:8)
2788
-
2789
-
2790
-  ❯ src/__tests__/identity/user-did-manager.test.ts [queued]
2791
-  ❯ src/__tests__/integration/full-flow.test.ts 0/21
2792
-  ❯ src/__tests__/providers/base.test.ts 14/14
2793
-  ❯ src/__tests__/providers/memory.test.ts [queued]
2794
-  ❯ src/__tests__/regression/phase2-regression.test.ts [queued]
2795
-  ❯ src/__tests__/runtime/base-extensions.test.ts 38/38
2796
-  ❯ src/__tests__/runtime/base.test.ts 55/55
2797
-  ❯ src/__tests__/services/agentshield-integration.test.ts 26/30
2798
-  ❯ src/__tests__/services/provider-resolver-edge-cases.test.ts [queued]
2799
-  ❯ src/config/__tests__/remote-config.spec.ts 9/9
2800
-  ❯ src/delegation/__tests__/cascading-revocation.test.ts [queued]
2801
-  ❯ src/services/__tests__/access-control.integration.test.ts 9/9
2802
-  ❯ src/services/__tests__/proof-verifier.test.ts 21/21
2803
-
2804
-  Test Files 16 passed (43)
2805
-  Tests 462 passed | 1 skipped (488)
2806
-  Start at 22:55:10
2807
-  Duration 602ms
2808
- [?2026l[?2026h ✓ src/services/__tests__/proof-verifier.test.ts (21 tests) 11ms
2809
-
2810
-  ❯ src/__tests__/identity/user-did-manager.test.ts [queued]
2811
-  ❯ src/__tests__/integration/full-flow.test.ts 0/21
2812
-  ❯ src/__tests__/providers/base.test.ts 14/14
2813
-  ❯ src/__tests__/providers/memory.test.ts [queued]
2814
-  ❯ src/__tests__/regression/phase2-regression.test.ts [queued]
2815
-  ❯ src/__tests__/runtime/base-extensions.test.ts 38/38
2816
-  ❯ src/__tests__/runtime/base.test.ts 55/55
2817
-  ❯ src/__tests__/services/agentshield-integration.test.ts 26/30
2818
-  ❯ src/__tests__/services/provider-resolver-edge-cases.test.ts [queued]
2819
-  ❯ src/config/__tests__/remote-config.spec.ts 9/9
2820
-  ❯ src/delegation/__tests__/cascading-revocation.test.ts [queued]
2821
-  ❯ src/services/__tests__/access-control.integration.test.ts 9/9
2822
-  ❯ src/services/__tests__/proof-verifier.test.ts 21/21
2823
-
2824
-  Test Files 16 passed (43)
2825
-  Tests 462 passed | 1 skipped (488)
2826
-  Start at 22:55:10
2827
-  Duration 602ms
2828
- [?2026l[?2026hstderr | src/config/__tests__/remote-config.spec.ts > fetchRemoteConfig > Error handling > should return null if API request fails
2829
- [RemoteConfig] API returned 404: Not Found
2830
-
2831
-
2832
-  ❯ src/__tests__/identity/user-did-manager.test.ts [queued]
2833
-  ❯ src/__tests__/integration/full-flow.test.ts 0/21
2834
-  ❯ src/__tests__/providers/base.test.ts 14/14
2835
-  ❯ src/__tests__/providers/memory.test.ts [queued]
2836
-  ❯ src/__tests__/regression/phase2-regression.test.ts [queued]
2837
-  ❯ src/__tests__/runtime/base-extensions.test.ts 38/38
2838
-  ❯ src/__tests__/runtime/base.test.ts 55/55
2839
-  ❯ src/__tests__/services/agentshield-integration.test.ts 26/30
2840
-  ❯ src/__tests__/services/provider-resolver-edge-cases.test.ts [queued]
2841
-  ❯ src/config/__tests__/remote-config.spec.ts 9/9
2842
-  ❯ src/delegation/__tests__/cascading-revocation.test.ts [queued]
2843
-  ❯ src/services/__tests__/access-control.integration.test.ts 9/9
2844
-  ❯ src/services/__tests__/proof-verifier.test.ts 21/21
2845
-
2846
-  Test Files 16 passed (43)
2847
-  Tests 462 passed | 1 skipped (488)
2848
-  Start at 22:55:10
2849
-  Duration 602ms
2850
- [?2026l[?2026h ✓ src/services/__tests__/access-control.integration.test.ts (9 tests) 136ms
2851
-
2852
-  ❯ src/__tests__/identity/user-did-manager.test.ts [queued]
2853
-  ❯ src/__tests__/integration/full-flow.test.ts 0/21
2854
-  ❯ src/__tests__/providers/base.test.ts 14/14
2855
-  ❯ src/__tests__/providers/memory.test.ts [queued]
2856
-  ❯ src/__tests__/regression/phase2-regression.test.ts [queued]
2857
-  ❯ src/__tests__/runtime/base-extensions.test.ts 38/38
2858
-  ❯ src/__tests__/runtime/base.test.ts 55/55
2859
-  ❯ src/__tests__/services/agentshield-integration.test.ts 26/30
2860
-  ❯ src/__tests__/services/provider-resolver-edge-cases.test.ts [queued]
2861
-  ❯ src/config/__tests__/remote-config.spec.ts 9/9
2862
-  ❯ src/delegation/__tests__/cascading-revocation.test.ts [queued]
2863
-  ❯ src/services/__tests__/access-control.integration.test.ts 9/9
2864
-  ❯ src/services/__tests__/proof-verifier.test.ts 21/21
2865
-
2866
-  Test Files 16 passed (43)
2867
-  Tests 462 passed | 1 skipped (488)
2868
-  Start at 22:55:10
2869
-  Duration 602ms
2870
- [?2026l[?2026hstderr | src/config/__tests__/remote-config.spec.ts > fetchRemoteConfig > Error handling > should return null if API throws error
2871
- [RemoteConfig] Failed to fetch config: Error: Network error
2872
- at /Users/dylanhobbs/Documents/@kya-os/xmcp-i/packages/mcp-i-core/src/config/__tests__/remote-config.spec.ts:170:35
2873
- at file:///Users/dylanhobbs/Documents/@kya-os/xmcp-i/node_modules/.pnpm/@vitest+runner@4.0.5/node_modules/@vitest/runner/dist/index.js:157:11
2874
- at file:///Users/dylanhobbs/Documents/@kya-os/xmcp-i/node_modules/.pnpm/@vitest+runner@4.0.5/node_modules/@vitest/runner/dist/index.js:753:26
2875
- at file:///Users/dylanhobbs/Documents/@kya-os/xmcp-i/node_modules/.pnpm/@vitest+runner@4.0.5/node_modules/@vitest/runner/dist/index.js:1636:20
2876
- at new Promise (<anonymous>)
2877
- at runWithTimeout (file:///Users/dylanhobbs/Documents/@kya-os/xmcp-i/node_modules/.pnpm/@vitest+runner@4.0.5/node_modules/@vitest/runner/dist/index.js:1602:10)
2878
- at runTest (file:///Users/dylanhobbs/Documents/@kya-os/xmcp-i/node_modules/.pnpm/@vitest+runner@4.0.5/node_modules/@vitest/runner/dist/index.js:1309:12)
2879
-  at processTicksAndRejections (node:internal/process/task_queues:103:5)
2880
- at runSuite (file:///Users/dylanhobbs/Documents/@kya-os/xmcp-i/node_modules/.pnpm/@vitest+runner@4.0.5/node_modules/@vitest/runner/dist/index.js:1468:8)
2881
- at runSuite (file:///Users/dylanhobbs/Documents/@kya-os/xmcp-i/node_modules/.pnpm/@vitest+runner@4.0.5/node_modules/@vitest/runner/dist/index.js:1468:8)
2882
-
2883
- stderr | src/config/__tests__/remote-config.spec.ts > fetchRemoteConfig > Error handling > should return null if neither projectId nor agentDid provided
2884
- [RemoteConfig] Neither projectId nor agentDid provided
2885
-
2886
- stderr | src/config/__tests__/remote-config.spec.ts > fetchRemoteConfig > Error handling > should handle cache read errors gracefully
2887
- [RemoteConfig] Cache read failed: Error: Cache error
2888
- at /Users/dylanhobbs/Documents/@kya-os/xmcp-i/packages/mcp-i-core/src/config/__tests__/remote-config.spec.ts:198:50
2889
- at file:///Users/dylanhobbs/Documents/@kya-os/xmcp-i/node_modules/.pnpm/@vitest+runner@4.0.5/node_modules/@vitest/runner/dist/index.js:157:11
2890
- at file:///Users/dylanhobbs/Documents/@kya-os/xmcp-i/node_modules/.pnpm/@vitest+runner@4.0.5/node_modules/@vitest/runner/dist/index.js:753:26
2891
- at file:///Users/dylanhobbs/Documents/@kya-os/xmcp-i/node_modules/.pnpm/@vitest+runner@4.0.5/node_modules/@vitest/runner/dist/index.js:1636:20
2892
- at new Promise (<anonymous>)
2893
- at runWithTimeout (file:///Users/dylanhobbs/Documents/@kya-os/xmcp-i/node_modules/.pnpm/@vitest+runner@4.0.5/node_modules/@vitest/runner/dist/index.js:1602:10)
2894
- at runTest (file:///Users/dylanhobbs/Documents/@kya-os/xmcp-i/node_modules/.pnpm/@vitest+runner@4.0.5/node_modules/@vitest/runner/dist/index.js:1309:12)
2895
-  at processTicksAndRejections (node:internal/process/task_queues:103:5)
2896
- at runSuite (file:///Users/dylanhobbs/Documents/@kya-os/xmcp-i/node_modules/.pnpm/@vitest+runner@4.0.5/node_modules/@vitest/runner/dist/index.js:1468:8)
2897
- at runSuite (file:///Users/dylanhobbs/Documents/@kya-os/xmcp-i/node_modules/.pnpm/@vitest+runner@4.0.5/node_modules/@vitest/runner/dist/index.js:1468:8)
2898
-
2899
-
2900
-  ❯ src/__tests__/identity/user-did-manager.test.ts [queued]
2901
-  ❯ src/__tests__/integration/full-flow.test.ts 0/21
2902
-  ❯ src/__tests__/providers/base.test.ts 14/14
2903
-  ❯ src/__tests__/providers/memory.test.ts [queued]
2904
-  ❯ src/__tests__/regression/phase2-regression.test.ts [queued]
2905
-  ❯ src/__tests__/runtime/base-extensions.test.ts 38/38
2906
-  ❯ src/__tests__/runtime/base.test.ts 55/55
2907
-  ❯ src/__tests__/services/agentshield-integration.test.ts 26/30
2908
-  ❯ src/__tests__/services/provider-resolver-edge-cases.test.ts [queued]
2909
-  ❯ src/config/__tests__/remote-config.spec.ts 9/9
2910
-  ❯ src/delegation/__tests__/cascading-revocation.test.ts [queued]
2911
-  ❯ src/services/__tests__/access-control.integration.test.ts 9/9
2912
-  ❯ src/services/__tests__/proof-verifier.test.ts 21/21
2913
-
2914
-  Test Files 16 passed (43)
2915
-  Tests 462 passed | 1 skipped (488)
2916
-  Start at 22:55:10
2917
-  Duration 602ms
2918
- [?2026l[?2026h ✓ src/config/__tests__/remote-config.spec.ts (9 tests) 10ms
2919
- ✓ src/__tests__/providers/base.test.ts (14 tests) 7ms
2920
- ✓ src/__tests__/runtime/base-extensions.test.ts (38 tests) 12ms
2921
-
2922
-  ❯ src/__tests__/identity/user-did-manager.test.ts [queued]
2923
-  ❯ src/__tests__/integration/full-flow.test.ts 0/21
2924
-  ❯ src/__tests__/providers/base.test.ts 14/14
2925
-  ❯ src/__tests__/providers/memory.test.ts [queued]
2926
-  ❯ src/__tests__/regression/phase2-regression.test.ts [queued]
2927
-  ❯ src/__tests__/runtime/base-extensions.test.ts 38/38
2928
-  ❯ src/__tests__/runtime/base.test.ts 55/55
2929
-  ❯ src/__tests__/services/agentshield-integration.test.ts 26/30
2930
-  ❯ src/__tests__/services/provider-resolver-edge-cases.test.ts [queued]
2931
-  ❯ src/config/__tests__/remote-config.spec.ts 9/9
2932
-  ❯ src/delegation/__tests__/cascading-revocation.test.ts [queued]
2933
-  ❯ src/services/__tests__/access-control.integration.test.ts 9/9
2934
-  ❯ src/services/__tests__/proof-verifier.test.ts 21/21
2935
-
2936
-  Test Files 16 passed (43)
2937
-  Tests 462 passed | 1 skipped (488)
2938
-  Start at 22:55:10
2939
-  Duration 602ms
2940
- [?2026l[?2026hstdout | src/__tests__/integration/full-flow.test.ts > Full Flow Integration > Tool protection enforcement flow > should allow unprotected tool calls
2941
- [ToolProtectionService] Config loaded from API {
2942
- source: 'api',
2943
- toolCount: 1,
2944
- protectedTools: [],
2945
- agentDid: 'did:key:z6MkhaXgBZDv...',
2946
- projectId: 'test-project',
2947
- cacheTtlMs: 300000,
2948
- cacheExpiresAt: '2025-11-22T05:00:11.188Z'
2949
- }
2950
-
2951
- stdout | src/__tests__/integration/full-flow.test.ts > Full Flow Integration > Tool protection enforcement flow > should intercept protected tool calls without delegation
2952
- [ToolProtectionService] Config loaded from API {
2953
- source: 'api',
2954
- toolCount: 1,
2955
- protectedTools: [ 'checkout' ],
2956
- agentDid: 'did:key:z6MkhaXgBZDv...',
2957
- projectId: 'test-project',
2958
- cacheTtlMs: 300000,
2959
- cacheExpiresAt: '2025-11-22T05:00:11.190Z'
2960
- }
2961
-
2962
- stdout | src/__tests__/integration/full-flow.test.ts > Full Flow Integration > Tool protection enforcement flow > should intercept protected tool calls without delegation
2963
- [ToolProtectionService] Protection check {
2964
- tool: 'checkout',
2965
- agentDid: 'did:key:z6MkhaXgBZDv...',
2966
- found: true,
2967
- isWildcard: false,
2968
- requiresDelegation: true,
2969
- availableTools: [ 'checkout' ]
2970
- }
2971
-
2972
- stdout | src/__tests__/integration/full-flow.test.ts > Full Flow Integration > AgentShield integration flow > should fetch tool protection config from AgentShield
2973
- [ToolProtectionService] Config loaded from API {
2974
- source: 'api',
2975
- toolCount: 1,
2976
- protectedTools: [ 'protected_tool' ],
2977
- agentDid: 'did:key:z6MkhaXgBZDv...',
2978
- projectId: 'test-project',
2979
- cacheTtlMs: 300000,
2980
- cacheExpiresAt: '2025-11-22T05:00:11.191Z'
2981
- }
2982
-
2983
- stdout | src/__tests__/integration/full-flow.test.ts > Full Flow Integration > AgentShield integration flow > should cache tool protection config
2984
- [ToolProtectionService] Config loaded from API {
2985
- source: 'api',
2986
- toolCount: 1,
2987
- protectedTools: [ 'tool1' ],
2988
- agentDid: 'did:key:z6MkhaXgBZDv...',
2989
- projectId: 'test-project',
2990
- cacheTtlMs: 300000,
2991
- cacheExpiresAt: '2025-11-22T05:00:11.193Z'
2992
- }
2993
-
2994
-
2995
-  ❯ src/__tests__/identity/user-did-manager.test.ts 17/17
2996
-  ❯ src/__tests__/integration.test.ts 0/9
2997
-  ❯ src/__tests__/integration/full-flow.test.ts 21/21
2998
-  ❯ src/__tests__/providers/base.test.ts 14/14
2999
-  ❯ src/__tests__/providers/memory.test.ts 34/34
3000
-  ❯ src/__tests__/regression/phase2-regression.test.ts 12/12
3001
-  ❯ src/__tests__/runtime/base-extensions.test.ts 38/38
3002
-  ❯ src/__tests__/services/agentshield-integration.test.ts 26/30
3003
-  ❯ src/__tests__/services/provider-resolver-edge-cases.test.ts [queued]
3004
-  ❯ src/__tests__/services/tool-protection-oauth-provider.test.ts [queued]
3005
-  ❯ src/delegation/__tests__/bitstring.test.ts [queued]
3006
-  ❯ src/delegation/__tests__/cascading-revocation.test.ts 23/23
3007
-  ❯ src/delegation/__tests__/delegation-graph.test.ts [queued]
3008
-
3009
-  Test Files 21 passed (43)
3010
-  Tests 569 passed | 1 skipped (583)
3011
-  Start at 22:55:10
3012
-  Duration 702ms
3013
- [?2026l[?2026hstderr | src/__tests__/integration/full-flow.test.ts > Full Flow Integration > AgentShield integration flow > should use fallback config when API fails
3014
- [ToolProtectionService] API fetch failed, using fallback config { agentDid: 'did:key:z6MkhaXgBZDv...', error: 'Network error' }
3015
-
3016
- stderr | src/__tests__/integration/full-flow.test.ts > Full Flow Integration > Error handling in full flow > should handle tool protection service errors gracefully
3017
- [ToolProtectionService] API fetch failed, no fallback, failing closed (deny-all) {
3018
- agentDid: 'did:key:z6MkhaXgBZDv...',
3019
- error: 'Network error',
3020
- cacheKey: 'config:tool-protections:test-project'
3021
- }
3022
-
3023
- stderr | src/__tests__/integration/full-flow.test.ts > Full Flow Integration > Error handling in full flow > should handle network timeouts
3024
- [ToolProtectionService] API fetch failed, using fallback config { agentDid: 'did:key:z6MkhaXgBZDv...', error: 'Network timeout' }
3025
-
3026
-
3027
-  ❯ src/__tests__/identity/user-did-manager.test.ts 17/17
3028
-  ❯ src/__tests__/integration.test.ts 0/9
3029
-  ❯ src/__tests__/integration/full-flow.test.ts 21/21
3030
-  ❯ src/__tests__/providers/base.test.ts 14/14
3031
-  ❯ src/__tests__/providers/memory.test.ts 34/34
3032
-  ❯ src/__tests__/regression/phase2-regression.test.ts 12/12
3033
-  ❯ src/__tests__/runtime/base-extensions.test.ts 38/38
3034
-  ❯ src/__tests__/services/agentshield-integration.test.ts 26/30
3035
-  ❯ src/__tests__/services/provider-resolver-edge-cases.test.ts [queued]
3036
-  ❯ src/__tests__/services/tool-protection-oauth-provider.test.ts [queued]
3037
-  ❯ src/delegation/__tests__/bitstring.test.ts [queued]
3038
-  ❯ src/delegation/__tests__/cascading-revocation.test.ts 23/23
3039
-  ❯ src/delegation/__tests__/delegation-graph.test.ts [queued]
3040
-
3041
-  Test Files 21 passed (43)
3042
-  Tests 569 passed | 1 skipped (583)
3043
-  Start at 22:55:10
3044
-  Duration 702ms
3045
- [?2026l[?2026hstdout | src/__tests__/integration/full-flow.test.ts > Full Flow Integration > Cache integration in full flow > should share cache across multiple service instances
3046
- [ToolProtectionService] Config loaded from API {
3047
- source: 'api',
3048
- toolCount: 1,
3049
- protectedTools: [ 'tool1' ],
3050
- agentDid: 'did:key:z6MkhaXgBZDv...',
3051
- projectId: 'test-project',
3052
- cacheTtlMs: 300000,
3053
- cacheExpiresAt: '2025-11-22T05:00:11.195Z'
3054
- }
3055
-
3056
- stdout | src/__tests__/integration/full-flow.test.ts > Full Flow Integration > Cache integration in full flow > should clear cache when needed
3057
- [ToolProtectionService] Config loaded from API {
3058
- source: 'api',
3059
- toolCount: 1,
3060
- protectedTools: [ 'tool1' ],
3061
- agentDid: 'did:key:z6MkhaXgBZDv...',
3062
- projectId: 'test-project',
3063
- cacheTtlMs: 300000,
3064
- cacheExpiresAt: '2025-11-22T05:00:11.195Z'
3065
- }
3066
-
3067
- stdout | src/__tests__/integration/full-flow.test.ts > Full Flow Integration > Cache integration in full flow > should clear cache when needed
3068
- [ToolProtectionService] Config loaded from API {
3069
- source: 'api',
3070
- toolCount: 1,
3071
- protectedTools: [ 'tool1' ],
3072
- agentDid: 'did:key:z6MkhaXgBZDv...',
3073
- projectId: 'test-project',
3074
- cacheTtlMs: 300000,
3075
- cacheExpiresAt: '2025-11-22T05:00:11.196Z'
3076
- }
3077
-
3078
- stdout | src/__tests__/integration/full-flow.test.ts > Full Flow Integration > Real-world e-commerce scenario > should handle complete e-commerce flow with tool protection
3079
- [ToolProtectionService] Config loaded from API {
3080
- source: 'api',
3081
- toolCount: 3,
3082
- protectedTools: [ 'add_to_cart', 'checkout' ],
3083
- agentDid: 'did:key:z6MkhaXgBZDv...',
3084
- projectId: 'test-project',
3085
- cacheTtlMs: 300000,
3086
- cacheExpiresAt: '2025-11-22T05:00:11.196Z'
3087
- }
3088
-
3089
- stdout | src/__tests__/integration/full-flow.test.ts > Full Flow Integration > Real-world e-commerce scenario > should handle complete e-commerce flow with tool protection
3090
- [ToolProtectionService] Protection check {
3091
- tool: 'add_to_cart',
3092
- agentDid: 'did:key:z6MkhaXgBZDv...',
3093
- found: true,
3094
- isWildcard: false,
3095
- requiresDelegation: true,
3096
- availableTools: [ 'search_products', 'add_to_cart', 'checkout' ]
3097
- }
3098
-
3099
- stdout | src/__tests__/integration/full-flow.test.ts > Full Flow Integration > Concurrent operations > should handle concurrent cache operations
3100
- [ToolProtectionService] Config loaded from API {
3101
- source: 'api',
3102
- toolCount: 1,
3103
- protectedTools: [ 'tool1' ],
3104
- agentDid: 'did:key:z6MkhaXgBZDv...',
3105
- projectId: 'test-project',
3106
- cacheTtlMs: 300000,
3107
- cacheExpiresAt: '2025-11-22T05:00:11.196Z'
3108
- }
3109
- [ToolProtectionService] Config loaded from API {
3110
- source: 'api',
3111
- toolCount: 1,
3112
- protectedTools: [ 'tool1' ],
3113
- agentDid: 'did:key:z6MkhaXgBZDv...',
3114
- projectId: 'test-project',
3115
- cacheTtlMs: 300000,
3116
- cacheExpiresAt: '2025-11-22T05:00:11.196Z'
3117
- }
3118
- [ToolProtectionService] Config loaded from API {
3119
- source: 'api',
3120
- toolCount: 1,
3121
- protectedTools: [ 'tool1' ],
3122
- agentDid: 'did:key:z6MkhaXgBZDv...',
3123
- projectId: 'test-project',
3124
- cacheTtlMs: 300000,
3125
- cacheExpiresAt: '2025-11-22T05:00:11.196Z'
3126
- }
3127
-
3128
- ✓ src/__tests__/providers/memory.test.ts (34 tests) 9ms
3129
-
3130
-  ❯ src/__tests__/identity/user-did-manager.test.ts 17/17
3131
-  ❯ src/__tests__/integration.test.ts 0/9
3132
-  ❯ src/__tests__/integration/full-flow.test.ts 21/21
3133
-  ❯ src/__tests__/providers/base.test.ts 14/14
3134
-  ❯ src/__tests__/providers/memory.test.ts 34/34
3135
-  ❯ src/__tests__/regression/phase2-regression.test.ts 12/12
3136
-  ❯ src/__tests__/runtime/base-extensions.test.ts 38/38
3137
-  ❯ src/__tests__/services/agentshield-integration.test.ts 26/30
3138
-  ❯ src/__tests__/services/provider-resolver-edge-cases.test.ts [queued]
3139
-  ❯ src/__tests__/services/tool-protection-oauth-provider.test.ts [queued]
3140
-  ❯ src/delegation/__tests__/bitstring.test.ts [queued]
3141
-  ❯ src/delegation/__tests__/cascading-revocation.test.ts 23/23
3142
-  ❯ src/delegation/__tests__/delegation-graph.test.ts [queued]
3143
-
3144
-  Test Files 21 passed (43)
3145
-  Tests 569 passed | 1 skipped (583)
3146
-  Start at 22:55:10
3147
-  Duration 702ms
3148
- [?2026l[?2026hstderr | src/__tests__/identity/user-did-manager.test.ts > UserDidManager > error handling > should handle storage.get errors gracefully
3149
- [UserDidManager] Storage.get failed, generating new DID: Error: Storage error
3150
- at /Users/dylanhobbs/Documents/@kya-os/xmcp-i/packages/mcp-i-core/src/__tests__/identity/user-did-manager.test.ts:187:67
3151
- at file:///Users/dylanhobbs/Documents/@kya-os/xmcp-i/node_modules/.pnpm/@vitest+runner@4.0.5/node_modules/@vitest/runner/dist/index.js:157:11
3152
- at file:///Users/dylanhobbs/Documents/@kya-os/xmcp-i/node_modules/.pnpm/@vitest+runner@4.0.5/node_modules/@vitest/runner/dist/index.js:753:26
3153
- at file:///Users/dylanhobbs/Documents/@kya-os/xmcp-i/node_modules/.pnpm/@vitest+runner@4.0.5/node_modules/@vitest/runner/dist/index.js:1636:20
3154
- at new Promise (<anonymous>)
3155
- at runWithTimeout (file:///Users/dylanhobbs/Documents/@kya-os/xmcp-i/node_modules/.pnpm/@vitest+runner@4.0.5/node_modules/@vitest/runner/dist/index.js:1602:10)
3156
- at runTest (file:///Users/dylanhobbs/Documents/@kya-os/xmcp-i/node_modules/.pnpm/@vitest+runner@4.0.5/node_modules/@vitest/runner/dist/index.js:1309:12)
3157
-  at processTicksAndRejections (node:internal/process/task_queues:103:5)
3158
- at runSuite (file:///Users/dylanhobbs/Documents/@kya-os/xmcp-i/node_modules/.pnpm/@vitest+runner@4.0.5/node_modules/@vitest/runner/dist/index.js:1468:8)
3159
- at runSuite (file:///Users/dylanhobbs/Documents/@kya-os/xmcp-i/node_modules/.pnpm/@vitest+runner@4.0.5/node_modules/@vitest/runner/dist/index.js:1468:8)
3160
-
3161
-
3162
-  ❯ src/__tests__/identity/user-did-manager.test.ts 17/17
3163
-  ❯ src/__tests__/integration.test.ts 0/9
3164
-  ❯ src/__tests__/integration/full-flow.test.ts 21/21
3165
-  ❯ src/__tests__/providers/base.test.ts 14/14
3166
-  ❯ src/__tests__/providers/memory.test.ts 34/34
3167
-  ❯ src/__tests__/regression/phase2-regression.test.ts 12/12
3168
-  ❯ src/__tests__/runtime/base-extensions.test.ts 38/38
3169
-  ❯ src/__tests__/services/agentshield-integration.test.ts 26/30
3170
-  ❯ src/__tests__/services/provider-resolver-edge-cases.test.ts [queued]
3171
-  ❯ src/__tests__/services/tool-protection-oauth-provider.test.ts [queued]
3172
-  ❯ src/delegation/__tests__/bitstring.test.ts [queued]
3173
-  ❯ src/delegation/__tests__/cascading-revocation.test.ts 23/23
3174
-  ❯ src/delegation/__tests__/delegation-graph.test.ts [queued]
3175
-
3176
-  Test Files 21 passed (43)
3177
-  Tests 569 passed | 1 skipped (583)
3178
-  Start at 22:55:10
3179
-  Duration 702ms
3180
- [?2026l[?2026h ✓ src/__tests__/integration/full-flow.test.ts (21 tests) 24ms
3181
-
3182
-  ❯ src/__tests__/identity/user-did-manager.test.ts 17/17
3183
-  ❯ src/__tests__/integration.test.ts 0/9
3184
-  ❯ src/__tests__/integration/full-flow.test.ts 21/21
3185
-  ❯ src/__tests__/providers/base.test.ts 14/14
3186
-  ❯ src/__tests__/providers/memory.test.ts 34/34
3187
-  ❯ src/__tests__/regression/phase2-regression.test.ts 12/12
3188
-  ❯ src/__tests__/runtime/base-extensions.test.ts 38/38
3189
-  ❯ src/__tests__/services/agentshield-integration.test.ts 26/30
3190
-  ❯ src/__tests__/services/provider-resolver-edge-cases.test.ts [queued]
3191
-  ❯ src/__tests__/services/tool-protection-oauth-provider.test.ts [queued]
3192
-  ❯ src/delegation/__tests__/bitstring.test.ts [queued]
3193
-  ❯ src/delegation/__tests__/cascading-revocation.test.ts 23/23
3194
-  ❯ src/delegation/__tests__/delegation-graph.test.ts [queued]
3195
-
3196
-  Test Files 21 passed (43)
3197
-  Tests 569 passed | 1 skipped (583)
3198
-  Start at 22:55:10
3199
-  Duration 702ms
3200
- [?2026l[?2026hstderr | src/__tests__/identity/user-did-manager.test.ts > UserDidManager > error handling > should handle storage.set errors gracefully
3201
- [UserDidManager] Storage.set failed, continuing with cached DID: Error: Storage error
3202
- at /Users/dylanhobbs/Documents/@kya-os/xmcp-i/packages/mcp-i-core/src/__tests__/identity/user-did-manager.test.ts:196:67
3203
- at file:///Users/dylanhobbs/Documents/@kya-os/xmcp-i/node_modules/.pnpm/@vitest+runner@4.0.5/node_modules/@vitest/runner/dist/index.js:157:11
3204
- at file:///Users/dylanhobbs/Documents/@kya-os/xmcp-i/node_modules/.pnpm/@vitest+runner@4.0.5/node_modules/@vitest/runner/dist/index.js:753:26
3205
- at file:///Users/dylanhobbs/Documents/@kya-os/xmcp-i/node_modules/.pnpm/@vitest+runner@4.0.5/node_modules/@vitest/runner/dist/index.js:1636:20
3206
- at new Promise (<anonymous>)
3207
- at runWithTimeout (file:///Users/dylanhobbs/Documents/@kya-os/xmcp-i/node_modules/.pnpm/@vitest+runner@4.0.5/node_modules/@vitest/runner/dist/index.js:1602:10)
3208
- at runTest (file:///Users/dylanhobbs/Documents/@kya-os/xmcp-i/node_modules/.pnpm/@vitest+runner@4.0.5/node_modules/@vitest/runner/dist/index.js:1309:12)
3209
-  at processTicksAndRejections (node:internal/process/task_queues:103:5)
3210
- at runSuite (file:///Users/dylanhobbs/Documents/@kya-os/xmcp-i/node_modules/.pnpm/@vitest+runner@4.0.5/node_modules/@vitest/runner/dist/index.js:1468:8)
3211
- at runSuite (file:///Users/dylanhobbs/Documents/@kya-os/xmcp-i/node_modules/.pnpm/@vitest+runner@4.0.5/node_modules/@vitest/runner/dist/index.js:1468:8)
3212
-
3213
- stderr | src/__tests__/identity/user-did-manager.test.ts > UserDidManager > error handling > should handle storage.delete errors gracefully
3214
- [UserDidManager] Storage.delete failed, continuing: Error: Storage error
3215
- at /Users/dylanhobbs/Documents/@kya-os/xmcp-i/packages/mcp-i-core/src/__tests__/identity/user-did-manager.test.ts:206:70
3216
-  at processTicksAndRejections (node:internal/process/task_queues:103:5)
3217
- at file:///Users/dylanhobbs/Documents/@kya-os/xmcp-i/node_modules/.pnpm/@vitest+runner@4.0.5/node_modules/@vitest/runner/dist/index.js:753:20
3218
-
3219
-
3220
-  ❯ src/__tests__/identity/user-did-manager.test.ts 17/17
3221
-  ❯ src/__tests__/integration.test.ts 0/9
3222
-  ❯ src/__tests__/integration/full-flow.test.ts 21/21
3223
-  ❯ src/__tests__/providers/base.test.ts 14/14
3224
-  ❯ src/__tests__/providers/memory.test.ts 34/34
3225
-  ❯ src/__tests__/regression/phase2-regression.test.ts 12/12
3226
-  ❯ src/__tests__/runtime/base-extensions.test.ts 38/38
3227
-  ❯ src/__tests__/services/agentshield-integration.test.ts 26/30
3228
-  ❯ src/__tests__/services/provider-resolver-edge-cases.test.ts [queued]
3229
-  ❯ src/__tests__/services/tool-protection-oauth-provider.test.ts [queued]
3230
-  ❯ src/delegation/__tests__/bitstring.test.ts [queued]
3231
-  ❯ src/delegation/__tests__/cascading-revocation.test.ts 23/23
3232
-  ❯ src/delegation/__tests__/delegation-graph.test.ts [queued]
3233
-
3234
-  Test Files 21 passed (43)
3235
-  Tests 569 passed | 1 skipped (583)
3236
-  Start at 22:55:10
3237
-  Duration 702ms
3238
- [?2026l[?2026h ✓ src/__tests__/identity/user-did-manager.test.ts (17 tests) 13ms
3239
- ✓ src/delegation/__tests__/cascading-revocation.test.ts (23 tests) 9ms
3240
- stdout | src/__tests__/regression/phase2-regression.test.ts > Phase 2 Regression Tests > Backward Compatibility > Phase 1 tools (no oauthProvider) > should work with Phase 1 tools that don't specify oauthProvider
3241
- [ToolProtectionService] Config loaded from API {
3242
- source: 'api',
3243
- toolCount: 1,
3244
- protectedTools: [ 'phase1_tool' ],
3245
- agentDid: 'did:key:z6MkhaXgBZDv...',
3246
- projectId: 'none',
3247
- cacheTtlMs: 300000,
3248
- cacheExpiresAt: '2025-11-22T05:00:11.223Z'
3249
- }
3250
-
3251
- stdout | src/__tests__/regression/phase2-regression.test.ts > Phase 2 Regression Tests > Backward Compatibility > Old API endpoint format > should still support old endpoint format (tools array)
3252
- [ToolProtectionService] Config loaded from API {
3253
- source: 'api',
3254
- toolCount: 1,
3255
- protectedTools: [ 'old_tool' ],
3256
- agentDid: 'did:key:z6MkhaXgBZDv...',
3257
- projectId: 'none',
3258
- cacheTtlMs: 300000,
3259
- cacheExpiresAt: '2025-11-22T05:00:11.230Z'
3260
- }
3261
-
3262
- stdout | src/__tests__/regression/phase2-regression.test.ts > Phase 2 Regression Tests > Backward Compatibility > Old API endpoint format > should still support old endpoint format (tools object)
3263
- [ToolProtectionService] Config loaded from API {
3264
- source: 'api',
3265
- toolCount: 1,
3266
- protectedTools: [ 'old_tool' ],
3267
- agentDid: 'did:key:z6MkhaXgBZDv...',
3268
- projectId: 'none',
3269
- cacheTtlMs: 300000,
3270
- cacheExpiresAt: '2025-11-22T05:00:11.230Z'
3271
- }
3272
-
3273
- stdout | src/__tests__/regression/phase2-regression.test.ts > Phase 2 Regression Tests > Backward Compatibility > snake_case field names > should still support snake_case field names
3274
- [ToolProtectionService] Config loaded from API {
3275
- source: 'api',
3276
- toolCount: 1,
3277
- protectedTools: [ 'tool_with_snake_case' ],
3278
- agentDid: 'did:key:z6MkhaXgBZDv...',
3279
- projectId: 'test-project-123',
3280
- cacheTtlMs: 300000,
3281
- cacheExpiresAt: '2025-11-22T05:00:11.230Z'
3282
- }
3283
-
3284
-
3285
-  ❯ src/__tests__/identity/user-did-manager.test.ts 17/17
3286
-  ❯ src/__tests__/integration.test.ts 0/9
3287
-  ❯ src/__tests__/integration/full-flow.test.ts 21/21
3288
-  ❯ src/__tests__/providers/base.test.ts 14/14
3289
-  ❯ src/__tests__/providers/memory.test.ts 34/34
3290
-  ❯ src/__tests__/regression/phase2-regression.test.ts 12/12
3291
-  ❯ src/__tests__/runtime/base-extensions.test.ts 38/38
3292
-  ❯ src/__tests__/services/agentshield-integration.test.ts 26/30
3293
-  ❯ src/__tests__/services/provider-resolver-edge-cases.test.ts [queued]
3294
-  ❯ src/__tests__/services/tool-protection-oauth-provider.test.ts [queued]
3295
-  ❯ src/delegation/__tests__/bitstring.test.ts [queued]
3296
-  ❯ src/delegation/__tests__/cascading-revocation.test.ts 23/23
3297
-  ❯ src/delegation/__tests__/delegation-graph.test.ts [queued]
3298
-
3299
-  Test Files 21 passed (43)
3300
-  Tests 569 passed | 1 skipped (583)
3301
-  Start at 22:55:10
3302
-  Duration 702ms
3303
- [?2026l[?2026hstderr | src/__tests__/regression/phase2-regression.test.ts > Phase 2 Regression Tests > No Regressions > Phase 1 OAuth flow > should still work with Phase 1 OAuth flow (no oauthProvider)
3304
- [ProviderResolver] Tool does not specify oauthProvider. Using first configured provider "github" as fallback. This is deprecated - configure oauthProvider in AgentShield dashboard for Phase 2+.
3305
-
3306
-
3307
-  ❯ src/__tests__/identity/user-did-manager.test.ts 17/17
3308
-  ❯ src/__tests__/integration.test.ts 0/9
3309
-  ❯ src/__tests__/integration/full-flow.test.ts 21/21
3310
-  ❯ src/__tests__/providers/base.test.ts 14/14
3311
-  ❯ src/__tests__/providers/memory.test.ts 34/34
3312
-  ❯ src/__tests__/regression/phase2-regression.test.ts 12/12
3313
-  ❯ src/__tests__/runtime/base-extensions.test.ts 38/38
3314
-  ❯ src/__tests__/services/agentshield-integration.test.ts 26/30
3315
-  ❯ src/__tests__/services/provider-resolver-edge-cases.test.ts [queued]
3316
-  ❯ src/__tests__/services/tool-protection-oauth-provider.test.ts [queued]
3317
-  ❯ src/delegation/__tests__/bitstring.test.ts [queued]
3318
-  ❯ src/delegation/__tests__/cascading-revocation.test.ts 23/23
3319
-  ❯ src/delegation/__tests__/delegation-graph.test.ts [queued]
3320
-
3321
-  Test Files 21 passed (43)
3322
-  Tests 569 passed | 1 skipped (583)
3323
-  Start at 22:55:10
3324
-  Duration 702ms
3325
- [?2026l[?2026hstdout | src/__tests__/regression/phase2-regression.test.ts > Phase 2 Regression Tests > Mixed Phase 1 and Phase 2 tools > should handle mix of Phase 1 and Phase 2 tools in same project
3326
- [ToolProtectionService] Config loaded from API {
3327
- source: 'api',
3328
- toolCount: 2,
3329
- protectedTools: [ 'phase1_tool', 'phase2_tool' ],
3330
- agentDid: 'did:key:z6MkhaXgBZDv...',
3331
- projectId: 'test-project-123',
3332
- cacheTtlMs: 300000,
3333
- cacheExpiresAt: '2025-11-22T05:00:11.231Z'
3334
- }
3335
-
3336
- ✓ src/__tests__/regression/phase2-regression.test.ts (12 tests) 9ms
3337
- stdout | src/__tests__/integration.test.ts > Integration Tests > Full handshake and tool execution flow > should complete full authentication and tool execution cycle
3338
- [AUDIT] {"event":"runtime_initialized","data":{"did":"did:key:zkOezRGpyV9bCR1aeBUO7TMpul1RRJGr8","environment":"development","userDidGeneration":"disabled"},"timestamp":1763787311278,"timestampFormatted":"2025-11-22T04:55:11.278Z"}
3339
-
3340
- stdout | src/__tests__/integration.test.ts > Integration Tests > Full handshake and tool execution flow > should complete full authentication and tool execution cycle
3341
- [AUDIT] {"event":"tool_executed","data":{"tool":"greetingTool","sessionId":"2bb2866140ffca69c9f8fa62836a5a7f","timestamp":1763787311278},"timestamp":1763787311278,"timestampFormatted":"2025-11-22T04:55:11.278Z"}
3342
-
3343
- stdout | src/__tests__/integration.test.ts > Integration Tests > Session expiry handling > should handle expired sessions correctly
3344
- [AUDIT] {"event":"runtime_initialized","data":{"did":"did:key:zDg3Hh_ZLpWSxVaen9X--yw9Wor0a1x4T","environment":"development","userDidGeneration":"disabled"},"timestamp":1763787311282,"timestampFormatted":"2025-11-22T04:55:11.282Z"}
3345
-
3346
- stdout | src/__tests__/integration.test.ts > Integration Tests > Key rotation flow > should handle key rotation and maintain functionality
3347
- [AUDIT] {"event":"runtime_initialized","data":{"did":"did:key:zSWtr5oYKyxzByFsEH1yYbpLZslcbMNGn","environment":"development","userDidGeneration":"disabled"},"timestamp":1763787311283,"timestampFormatted":"2025-11-22T04:55:11.283Z"}
3348
-
3349
- stdout | src/__tests__/integration.test.ts > Integration Tests > Key rotation flow > should handle key rotation and maintain functionality
3350
- [AUDIT] {"event":"keys_rotated","data":{"oldDid":"did:key:zSWtr5oYKyxzByFsEH1yYbpLZslcbMNGn","newDid":"did:key:zRCgjffXRsT1jCVjrMHFT-M_DXvh59lAV","timestamp":1763787311283},"timestamp":1763787311283,"timestampFormatted":"2025-11-22T04:55:11.283Z"}
3351
-
3352
- stdout | src/__tests__/integration.test.ts > Integration Tests > Well-known endpoints > should provide identity discovery endpoints
3353
- [AUDIT] {"event":"runtime_initialized","data":{"did":"did:key:zQXv3AfpBQNwuJifmDo-eNmGv6lu7nFYv","environment":"development","userDidGeneration":"disabled"},"timestamp":1763787311283,"timestampFormatted":"2025-11-22T04:55:11.283Z"}
3354
-
3355
- stdout | src/__tests__/integration.test.ts > Integration Tests > Nonce replay protection > should prevent nonce reuse
3356
- [AUDIT] {"event":"runtime_initialized","data":{"did":"did:key:zceHuzfLuiiU4ekM_6KA1pp7UpcKi7e15","environment":"development","userDidGeneration":"disabled"},"timestamp":1763787311284,"timestampFormatted":"2025-11-22T04:55:11.284Z"}
3357
-
3358
- stdout | src/__tests__/integration.test.ts > Integration Tests > Error handling > should handle network errors gracefully
3359
- [AUDIT] {"event":"runtime_initialized","data":{"did":"did:key:zuQ1qwWQvq7VPj-KGuImlm5QfiOIf7-qZ","environment":"development","userDidGeneration":"disabled"},"timestamp":1763787311284,"timestampFormatted":"2025-11-22T04:55:11.284Z"}
3360
-
3361
- stdout | src/__tests__/integration.test.ts > Integration Tests > Error handling > should handle malformed DID documents
3362
- [AUDIT] {"event":"runtime_initialized","data":{"did":"did:key:z95g0app0WKvEyhiTVRStY31wIfcsRuD9","environment":"development","userDidGeneration":"disabled"},"timestamp":1763787311284,"timestampFormatted":"2025-11-22T04:55:11.284Z"}
3363
-
3364
- stdout | src/__tests__/integration.test.ts > Integration Tests > Debug endpoint > should provide debug information in development
3365
- [AUDIT] {"event":"runtime_initialized","data":{"did":"did:key:zEJ9nGkCd3t7_fjI9TTYqjp8WTdbVlmnn","environment":"development","userDidGeneration":"disabled"},"timestamp":1763787311284,"timestampFormatted":"2025-11-22T04:55:11.284Z"}
3366
-
3367
- stdout | src/__tests__/integration.test.ts > Integration Tests > Debug endpoint > should be disabled in production
3368
- [AUDIT] {"event":"runtime_initialized","data":{"did":"did:key:zaBUTzT5XSb9YPQuJFOGk7rpSObrXIBRg","environment":"development","userDidGeneration":"disabled"},"timestamp":1763787311284,"timestampFormatted":"2025-11-22T04:55:11.284Z"}
3369
-
3370
-
3371
-  ❯ src/__tests__/identity/user-did-manager.test.ts 17/17
3372
-  ❯ src/__tests__/integration.test.ts 0/9
3373
-  ❯ src/__tests__/integration/full-flow.test.ts 21/21
3374
-  ❯ src/__tests__/providers/base.test.ts 14/14
3375
-  ❯ src/__tests__/providers/memory.test.ts 34/34
3376
-  ❯ src/__tests__/regression/phase2-regression.test.ts 12/12
3377
-  ❯ src/__tests__/runtime/base-extensions.test.ts 38/38
3378
-  ❯ src/__tests__/services/agentshield-integration.test.ts 26/30
3379
-  ❯ src/__tests__/services/provider-resolver-edge-cases.test.ts [queued]
3380
-  ❯ src/__tests__/services/tool-protection-oauth-provider.test.ts [queued]
3381
-  ❯ src/delegation/__tests__/bitstring.test.ts [queued]
3382
-  ❯ src/delegation/__tests__/cascading-revocation.test.ts 23/23
3383
-  ❯ src/delegation/__tests__/delegation-graph.test.ts [queued]
3384
-
3385
-  Test Files 21 passed (43)
3386
-  Tests 569 passed | 1 skipped (583)
3387
-  Start at 22:55:10
3388
-  Duration 702ms
3389
- [?2026l[?2026h ✓ src/__tests__/integration.test.ts (9 tests) 7ms
3390
- ✓ src/delegation/__tests__/delegation-graph.test.ts (28 tests) 7ms
3391
- ✓ src/__tests__/runtime/proof-client-did.test.ts (17 tests) 6ms
3392
- ✓ src/delegation/__tests__/bitstring.test.ts (30 tests) 5ms
3393
- stdout | src/services/__tests__/provider-resolver.test.ts > ProviderResolver > resolveProvider - Priority 2: Scope inference > should infer provider from github scope prefix
3394
- [ProviderResolver] Inferred provider "github" from scopes
3395
-
3396
- stdout | src/services/__tests__/provider-resolver.test.ts > ProviderResolver > resolveProvider - Priority 2: Scope inference > should infer provider from gmail scope prefix (maps to google)
3397
- [ProviderResolver] Inferred provider "google" from scopes
3398
-
3399
-
3400
-  ❯ src/__tests__/runtime/audit-logger.test.ts 0/9
3401
-  ❯ src/__tests__/runtime/delegation-flow.test.ts 0/4
3402
-  ❯ src/__tests__/runtime/proof-client-did.test.ts 17/17
3403
-  ❯ src/__tests__/services/agentshield-integration.test.ts 26/30
3404
-  ❯ src/__tests__/services/provider-resolver-edge-cases.test.ts [queued]
3405
-  ❯ src/__tests__/services/tool-protection-oauth-provider.test.ts 14/14
3406
-  ❯ src/compliance/__tests__/schema-verifier.test.ts 0/30
3407
-  ❯ src/delegation/__tests__/bitstring.test.ts 30/30
3408
-  ❯ src/delegation/storage/__tests__/memory-graph-storage.test.ts 27/27
3409
-  ❯ src/delegation/storage/__tests__/memory-statuslist-storage.test.ts [queued]
3410
-  ❯ src/services/__tests__/batch-delegation.service.test.ts 11/11
3411
-  ❯ src/services/__tests__/provider-resolution.integration.test.ts 0/6
3412
-  ❯ src/services/__tests__/provider-resolver.test.ts 8/8
3413
-
3414
-  Test Files 29 passed (43)
3415
-  Tests 713 passed | 1 skipped (767)
3416
-  Start at 22:55:10
3417
-  Duration 909ms
3418
- [?2026l[?2026hstderr | src/services/__tests__/provider-resolver.test.ts > ProviderResolver > resolveProvider - Priority 2: Scope inference > should return null for ambiguous scopes
3419
- [ProviderResolver] Tool does not specify oauthProvider. Using first configured provider "github" as fallback. This is deprecated - configure oauthProvider in AgentShield dashboard for Phase 2+.
3420
-
3421
-
3422
-  ❯ src/__tests__/runtime/audit-logger.test.ts 0/9
3423
-  ❯ src/__tests__/runtime/delegation-flow.test.ts 0/4
3424
-  ❯ src/__tests__/runtime/proof-client-did.test.ts 17/17
3425
-  ❯ src/__tests__/services/agentshield-integration.test.ts 26/30
3426
-  ❯ src/__tests__/services/provider-resolver-edge-cases.test.ts [queued]
3427
-  ❯ src/__tests__/services/tool-protection-oauth-provider.test.ts 14/14
3428
-  ❯ src/compliance/__tests__/schema-verifier.test.ts 0/30
3429
-  ❯ src/delegation/__tests__/bitstring.test.ts 30/30
3430
-  ❯ src/delegation/storage/__tests__/memory-graph-storage.test.ts 27/27
3431
-  ❯ src/delegation/storage/__tests__/memory-statuslist-storage.test.ts [queued]
3432
-  ❯ src/services/__tests__/batch-delegation.service.test.ts 11/11
3433
-  ❯ src/services/__tests__/provider-resolution.integration.test.ts 0/6
3434
-  ❯ src/services/__tests__/provider-resolver.test.ts 8/8
3435
-
3436
-  Test Files 29 passed (43)
3437
-  Tests 713 passed | 1 skipped (767)
3438
-  Start at 22:55:10
3439
-  Duration 909ms
3440
- [?2026l[?2026h ✓ src/services/__tests__/provider-resolver.test.ts (8 tests) 8ms
3441
- stdout | src/__tests__/services/tool-protection-oauth-provider.test.ts > ToolProtectionService - oauthProvider Parsing > New endpoint format (toolProtections object) > should parse oauthProvider from camelCase field
3442
- [ToolProtectionService] Config loaded from API {
3443
- source: 'api',
3444
- toolCount: 2,
3445
- protectedTools: [ 'read_repos', 'send_email' ],
3446
- agentDid: 'did:key:z6MkhaXgBZDv...',
3447
- projectId: 'test-project-123',
3448
- cacheTtlMs: 300000,
3449
- cacheExpiresAt: '2025-11-22T05:00:11.392Z'
3450
- }
3451
-
3452
- stdout | src/__tests__/services/tool-protection-oauth-provider.test.ts > ToolProtectionService - oauthProvider Parsing > New endpoint format (toolProtections object) > should parse oauthProvider from snake_case field
3453
- [ToolProtectionService] Config loaded from API {
3454
- source: 'api',
3455
- toolCount: 1,
3456
- protectedTools: [ 'read_repos' ],
3457
- agentDid: 'did:key:z6MkhaXgBZDv...',
3458
- projectId: 'test-project-123',
3459
- cacheTtlMs: 300000,
3460
- cacheExpiresAt: '2025-11-22T05:00:11.395Z'
3461
- }
3462
-
3463
- stdout | src/__tests__/services/tool-protection-oauth-provider.test.ts > ToolProtectionService - oauthProvider Parsing > New endpoint format (toolProtections object) > should prefer camelCase over snake_case when both present
3464
- [ToolProtectionService] Config loaded from API {
3465
- source: 'api',
3466
- toolCount: 1,
3467
- protectedTools: [ 'read_repos' ],
3468
- agentDid: 'did:key:z6MkhaXgBZDv...',
3469
- projectId: 'test-project-123',
3470
- cacheTtlMs: 300000,
3471
- cacheExpiresAt: '2025-11-22T05:00:11.395Z'
3472
- }
3473
-
3474
- stdout | src/__tests__/services/tool-protection-oauth-provider.test.ts > ToolProtectionService - oauthProvider Parsing > New endpoint format (toolProtections object) > should handle missing oauthProvider field (backward compatible)
3475
- [ToolProtectionService] Config loaded from API {
3476
- source: 'api',
3477
- toolCount: 1,
3478
- protectedTools: [ 'read_repos' ],
3479
- agentDid: 'did:key:z6MkhaXgBZDv...',
3480
- projectId: 'test-project-123',
3481
- cacheTtlMs: 300000,
3482
- cacheExpiresAt: '2025-11-22T05:00:11.396Z'
3483
- }
3484
-
3485
- stdout | src/__tests__/services/tool-protection-oauth-provider.test.ts > ToolProtectionService - oauthProvider Parsing > Old endpoint format (tools array) > should parse oauthProvider from array format with camelCase
3486
- [ToolProtectionService] Config loaded from API {
3487
- source: 'api',
3488
- toolCount: 2,
3489
- protectedTools: [ 'read_repos', 'send_email' ],
3490
- agentDid: 'did:key:z6MkhaXgBZDv...',
3491
- projectId: 'none',
3492
- cacheTtlMs: 300000,
3493
- cacheExpiresAt: '2025-11-22T05:00:11.396Z'
3494
- }
3495
-
3496
- stdout | src/__tests__/services/tool-protection-oauth-provider.test.ts > ToolProtectionService - oauthProvider Parsing > Old endpoint format (tools array) > should parse oauthProvider from array format with snake_case
3497
- [ToolProtectionService] Config loaded from API {
3498
- source: 'api',
3499
- toolCount: 1,
3500
- protectedTools: [ 'read_repos' ],
3501
- agentDid: 'did:key:z6MkhaXgBZDv...',
3502
- projectId: 'none',
3503
- cacheTtlMs: 300000,
3504
- cacheExpiresAt: '2025-11-22T05:00:11.396Z'
3505
- }
3506
-
3507
- stdout | src/__tests__/services/tool-protection-oauth-provider.test.ts > ToolProtectionService - oauthProvider Parsing > Old endpoint format (tools array) > should prefer camelCase over snake_case in array format
3508
- [ToolProtectionService] Config loaded from API {
3509
- source: 'api',
3510
- toolCount: 1,
3511
- protectedTools: [ 'read_repos' ],
3512
- agentDid: 'did:key:z6MkhaXgBZDv...',
3513
- projectId: 'none',
3514
- cacheTtlMs: 300000,
3515
- cacheExpiresAt: '2025-11-22T05:00:11.397Z'
3516
- }
3517
-
3518
- stdout | src/__tests__/services/tool-protection-oauth-provider.test.ts > ToolProtectionService - oauthProvider Parsing > Old endpoint format (tools object) > should parse oauthProvider from object format with camelCase
3519
- [ToolProtectionService] Config loaded from API {
3520
- source: 'api',
3521
- toolCount: 2,
3522
- protectedTools: [ 'read_repos', 'send_email' ],
3523
- agentDid: 'did:key:z6MkhaXgBZDv...',
3524
- projectId: 'none',
3525
- cacheTtlMs: 300000,
3526
- cacheExpiresAt: '2025-11-22T05:00:11.397Z'
3527
- }
3528
-
3529
- stdout | src/__tests__/services/tool-protection-oauth-provider.test.ts > ToolProtectionService - oauthProvider Parsing > Old endpoint format (tools object) > should parse oauthProvider from object format with snake_case
3530
- [ToolProtectionService] Config loaded from API {
3531
- source: 'api',
3532
- toolCount: 1,
3533
- protectedTools: [ 'read_repos' ],
3534
- agentDid: 'did:key:z6MkhaXgBZDv...',
3535
- projectId: 'none',
3536
- cacheTtlMs: 300000,
3537
- cacheExpiresAt: '2025-11-22T05:00:11.397Z'
3538
- }
3539
-
3540
- stdout | src/__tests__/services/tool-protection-oauth-provider.test.ts > ToolProtectionService - oauthProvider Parsing > Old endpoint format (tools object) > should prefer camelCase over snake_case in object format
3541
- [ToolProtectionService] Config loaded from API {
3542
- source: 'api',
3543
- toolCount: 1,
3544
- protectedTools: [ 'read_repos' ],
3545
- agentDid: 'did:key:z6MkhaXgBZDv...',
3546
- projectId: 'none',
3547
- cacheTtlMs: 300000,
3548
- cacheExpiresAt: '2025-11-22T05:00:11.397Z'
3549
- }
3550
-
3551
- stdout | src/__tests__/services/tool-protection-oauth-provider.test.ts > ToolProtectionService - oauthProvider Parsing > Caching > should cache oauthProvider field correctly
3552
- [ToolProtectionService] Config loaded from API {
3553
- source: 'api',
3554
- toolCount: 1,
3555
- protectedTools: [ 'read_repos' ],
3556
- agentDid: 'did:key:z6MkhaXgBZDv...',
3557
- projectId: 'test-project-123',
3558
- cacheTtlMs: 300000,
3559
- cacheExpiresAt: '2025-11-22T05:00:11.397Z'
3560
- }
3561
-
3562
- stdout | src/__tests__/services/tool-protection-oauth-provider.test.ts > ToolProtectionService - oauthProvider Parsing > oauthProvider field inclusion > should include oauthProvider in returned ToolProtection objects when present
3563
- [ToolProtectionService] Config loaded from API {
3564
- source: 'api',
3565
- toolCount: 2,
3566
- protectedTools: [ 'tool_with_provider', 'tool_without_provider' ],
3567
- agentDid: 'did:key:z6MkhaXgBZDv...',
3568
- projectId: 'test-project-123',
3569
- cacheTtlMs: 300000,
3570
- cacheExpiresAt: '2025-11-22T05:00:11.398Z'
3571
- }
3572
-
3573
- stdout | src/__tests__/services/tool-protection-oauth-provider.test.ts > ToolProtectionService - oauthProvider Parsing > oauthProvider field inclusion > should handle empty string oauthProvider gracefully
3574
- [ToolProtectionService] Config loaded from API {
3575
- source: 'api',
3576
- toolCount: 1,
3577
- protectedTools: [ 'tool_with_empty_provider' ],
3578
- agentDid: 'did:key:z6MkhaXgBZDv...',
3579
- projectId: 'test-project-123',
3580
- cacheTtlMs: 300000,
3581
- cacheExpiresAt: '2025-11-22T05:00:11.398Z'
3582
- }
3583
-
3584
- ✓ src/delegation/storage/__tests__/memory-graph-storage.test.ts (27 tests) 4ms
3585
- ✓ src/__tests__/services/tool-protection-oauth-provider.test.ts (14 tests) 7ms
3586
- ✓ src/services/__tests__/batch-delegation.service.test.ts (11 tests) 4ms
3587
-
3588
-  ❯ src/__tests__/runtime/audit-logger.test.ts 0/9
3589
-  ❯ src/__tests__/runtime/delegation-flow.test.ts 0/4
3590
-  ❯ src/__tests__/runtime/proof-client-did.test.ts 17/17
3591
-  ❯ src/__tests__/services/agentshield-integration.test.ts 26/30
3592
-  ❯ src/__tests__/services/provider-resolver-edge-cases.test.ts [queued]
3593
-  ❯ src/__tests__/services/tool-protection-oauth-provider.test.ts 14/14
3594
-  ❯ src/compliance/__tests__/schema-verifier.test.ts 0/30
3595
-  ❯ src/delegation/__tests__/bitstring.test.ts 30/30
3596
-  ❯ src/delegation/storage/__tests__/memory-graph-storage.test.ts 27/27
3597
-  ❯ src/delegation/storage/__tests__/memory-statuslist-storage.test.ts [queued]
3598
-  ❯ src/services/__tests__/batch-delegation.service.test.ts 11/11
3599
-  ❯ src/services/__tests__/provider-resolution.integration.test.ts 0/6
3600
-  ❯ src/services/__tests__/provider-resolver.test.ts 8/8
3601
-
3602
-  Test Files 29 passed (43)
3603
-  Tests 713 passed | 1 skipped (767)
3604
-  Start at 22:55:10
3605
-  Duration 909ms
3606
- [?2026l[?2026hstderr | src/services/__tests__/provider-resolution.integration.test.ts > Provider Resolution Integration > Backward compatibility > should work with Phase 1 tools (no oauthProvider field)
3607
- [ProviderResolver] Tool does not specify oauthProvider. Using first configured provider "github" as fallback. This is deprecated - configure oauthProvider in AgentShield dashboard for Phase 2+.
3608
-
3609
-
3610
-  ❯ src/__tests__/runtime/audit-logger.test.ts 0/9
3611
-  ❯ src/__tests__/runtime/delegation-flow.test.ts 0/4
3612
-  ❯ src/__tests__/runtime/proof-client-did.test.ts 17/17
3613
-  ❯ src/__tests__/services/agentshield-integration.test.ts 26/30
3614
-  ❯ src/__tests__/services/provider-resolver-edge-cases.test.ts [queued]
3615
-  ❯ src/__tests__/services/tool-protection-oauth-provider.test.ts 14/14
3616
-  ❯ src/compliance/__tests__/schema-verifier.test.ts 0/30
3617
-  ❯ src/delegation/__tests__/bitstring.test.ts 30/30
3618
-  ❯ src/delegation/storage/__tests__/memory-graph-storage.test.ts 27/27
3619
-  ❯ src/delegation/storage/__tests__/memory-statuslist-storage.test.ts [queued]
3620
-  ❯ src/services/__tests__/batch-delegation.service.test.ts 11/11
3621
-  ❯ src/services/__tests__/provider-resolution.integration.test.ts 0/6
3622
-  ❯ src/services/__tests__/provider-resolver.test.ts 8/8
3623
-
3624
-  Test Files 29 passed (43)
3625
-  Tests 713 passed | 1 skipped (767)
3626
-  Start at 22:55:10
3627
-  Duration 909ms
3628
- [?2026l[?2026h ✓ src/services/__tests__/provider-resolution.integration.test.ts (6 tests) 4ms
3629
- ✓ src/__tests__/runtime/audit-logger.test.ts (9 tests) 6ms
3630
- ✓ src/__tests__/runtime/delegation-flow.test.ts (4 tests) 8ms
3631
- ✓ src/compliance/__tests__/schema-verifier.test.ts (30 tests) 11ms
3632
- ✓ src/delegation/storage/__tests__/memory-statuslist-storage.test.ts (14 tests) 4ms
3633
- ✓ src/services/__tests__/oauth-provider-registry.test.ts (9 tests) 4ms
3634
- ✓ src/delegation/__tests__/utils.test.ts (28 tests) 3ms
3635
- ✓ src/utils/__tests__/did-helpers.test.ts (11 tests) 2ms
3636
-
3637
-  ❯ src/__tests__/config/provider-runtime-config.test.ts 0/9
3638
-  ❯ src/__tests__/delegation-e2e.test.ts [queued]
3639
-  ❯ src/__tests__/index.test.ts [queued]
3640
-  ❯ src/__tests__/services/agentshield-integration.test.ts 26/30
3641
-  ❯ src/__tests__/services/provider-resolver-edge-cases.test.ts [queued]
3642
-  ❯ src/delegation/__tests__/audience-validator.test.ts [queued]
3643
-
3644
-  Test Files 37 passed (43)
3645
-  Tests 824 passed | 1 skipped (838)
3646
-  Start at 22:55:10
3647
-  Duration 1.01s
3648
- [?2026l[?2026h ✓ src/__tests__/config/provider-runtime-config.test.ts (9 tests) 2ms
3649
- ✓ src/delegation/__tests__/audience-validator.test.ts (5 tests) 2ms
3650
- ↓ src/__tests__/delegation-e2e.test.ts (14 tests | 14 skipped)
3651
- ✓ src/__tests__/index.test.ts (4 tests) 2ms
3652
- stdout | src/__tests__/services/agentshield-integration.test.ts > AgentShield Integration > Caching Integration > should respect cache TTL
3653
- [ToolProtectionService] Config loaded from API {
3654
- source: 'api',
3655
- toolCount: 0,
3656
- protectedTools: [],
3657
- agentDid: 'did:key:z6MkhaXgBZDv...',
3658
- projectId: 'test-project-123',
3659
- cacheTtlMs: 1000,
3660
- cacheExpiresAt: '2025-11-22T04:55:12.940Z'
3661
- }
3662
-
3663
- stdout | src/__tests__/services/agentshield-integration.test.ts > AgentShield Integration > Real-world Scenarios > should handle typical e-commerce tool protection config
3664
- [ToolProtectionService] Config loaded from API {
3665
- source: 'api',
3666
- toolCount: 4,
3667
- protectedTools: [ 'add_to_cart', 'checkout' ],
3668
- agentDid: 'did:key:z6MkhaXgBZDv...',
3669
- projectId: 'test-project-123',
3670
- cacheTtlMs: 300000,
3671
- cacheExpiresAt: '2025-11-22T05:00:11.940Z'
3672
- }
3673
-
3674
-
3675
-  ❯ src/__tests__/services/agentshield-integration.test.ts 27/30
3676
-  ❯ src/__tests__/services/provider-resolver-edge-cases.test.ts [queued]
3677
-
3678
-  Test Files 40 passed | 1 skipped (43)
3679
-  Tests 843 passed | 15 skipped (861)
3680
-  Start at 22:55:10
3681
-  Duration 1.41s
3682
- [?2026l[?2026hstderr | src/__tests__/services/agentshield-integration.test.ts > AgentShield Integration > Real-world Scenarios > should handle API rate limiting gracefully
3683
- [ToolProtectionService] API fetch failed, using fallback config {
3684
- agentDid: 'did:key:z6MkhaXgBZDv...',
3685
- error: 'Failed to fetch bouncer config: 429 Too Many Requests - Rate limit exceeded'
3686
- }
3687
-
3688
-
3689
-  ❯ src/__tests__/services/agentshield-integration.test.ts 27/30
3690
-  ❯ src/__tests__/services/provider-resolver-edge-cases.test.ts [queued]
3691
-
3692
-  Test Files 40 passed | 1 skipped (43)
3693
-  Tests 843 passed | 15 skipped (861)
3694
-  Start at 22:55:10
3695
-  Duration 1.41s
3696
- [?2026l[?2026hstdout | src/__tests__/services/agentshield-integration.test.ts > AgentShield Integration > Real-world Scenarios > should handle concurrent requests
3697
- [ToolProtectionService] Config loaded from API {
3698
- source: 'api',
3699
- toolCount: 1,
3700
- protectedTools: [ 'tool1' ],
3701
- agentDid: 'did:key:z6MkhaXgBZDv...',
3702
- projectId: 'test-project-123',
3703
- cacheTtlMs: 300000,
3704
- cacheExpiresAt: '2025-11-22T05:00:11.941Z'
3705
- }
3706
- [ToolProtectionService] Config loaded from API {
3707
- source: 'api',
3708
- toolCount: 1,
3709
- protectedTools: [ 'tool1' ],
3710
- agentDid: 'did:key:z6MkhaXgBZDv...',
3711
- projectId: 'test-project-123',
3712
- cacheTtlMs: 300000,
3713
- cacheExpiresAt: '2025-11-22T05:00:11.941Z'
3714
- }
3715
- [ToolProtectionService] Config loaded from API {
3716
- source: 'api',
3717
- toolCount: 1,
3718
- protectedTools: [ 'tool1' ],
3719
- agentDid: 'did:key:z6MkhaXgBZDv...',
3720
- projectId: 'test-project-123',
3721
- cacheTtlMs: 300000,
3722
- cacheExpiresAt: '2025-11-22T05:00:11.941Z'
3723
- }
3724
-
3725
-
3726
-  ❯ src/__tests__/services/agentshield-integration.test.ts 27/30
3727
-  ❯ src/__tests__/services/provider-resolver-edge-cases.test.ts [queued]
3728
-
3729
-  Test Files 40 passed | 1 skipped (43)
3730
-  Tests 843 passed | 15 skipped (861)
3731
-  Start at 22:55:10
3732
-  Duration 1.41s
3733
- [?2026l ✓ src/__tests__/services/agentshield-integration.test.ts (30 tests) 1113ms
3734
- ✓ should respect cache TTL  1101ms
3735
-
3736
- ⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯ Failed Suites 1 ⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯
3737
-
3738
-  FAIL  src/__tests__/services/provider-resolver-edge-cases.test.ts [ src/__tests__/services/provider-resolver-edge-cases.test.ts ]
3739
- Error: Cannot find module '../provider-resolver.js' imported from '/Users/dylanhobbs/Documents/@kya-os/xmcp-i/packages/mcp-i-core/src/__tests__/services/provider-resolver-edge-cases.test.ts'
3740
-  ❯ src/__tests__/services/provider-resolver-edge-cases.test.ts:11:1
3741
-  9| 
3742
-  10| import { describe, it, expect, beforeEach, vi } from "vitest";
3743
-  11| import { ProviderResolver } from "../provider-resolver.js";
3744
-  | ^
3745
-  12| import { OAuthProviderRegistry } from "../oauth-provider-registry.js";
3746
-  13| import { OAuthConfigService } from "../oauth-config.service.js";
3747
-
3748
- ⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯[1/1]⎯
3749
-
3750
-
3751
-  Test Files  1 failed | 41 passed | 1 skipped (43)
3752
-  Tests  846 passed | 15 skipped (861)
3753
-  Start at  22:55:10
3754
-  Duration  1.57s (transform 2.42s, setup 0ms, collect 3.92s, tests 2.09s, environment 4ms, prepare 986ms)
3755
-
3756
- [?25h ELIFECYCLE  Command failed with exit code 1.
1
+
2
+ > @kya-os/mcp-i-core@1.2.2-canary.26 test:coverage /Users/dylanhobbs/Documents/@kya-os/xmcp-i/packages/mcp-i-core
3
+ > vitest run --coverage
4
+
5
+ The CJS build of Vite's Node API is deprecated. See https://vite.dev/guide/troubleshooting.html#vite-cjs-node-api-deprecated for more details.
6
+
7
+ RUN v1.6.1 /Users/dylanhobbs/Documents/@kya-os/xmcp-i/packages/mcp-i-core
8
+
9
+
10
+ ⎯⎯⎯⎯⎯⎯ Unhandled Error ⎯⎯⎯⎯⎯⎯⎯
11
+ TypeError: The "original" argument must be of type function. Received an instance of Object
12
+ promisify node:internal/util:463:3
13
+ ❯ Object.<anonymous> ../../node_modules/.pnpm/test-exclude@6.0.0/node_modules/test-exclude/index.js:5:14
14
+ ❯ Module._compile node:internal/modules/cjs/loader:1760:14
15
+ ❯ Object..js node:internal/modules/cjs/loader:1892:10
16
+ ❯ Module.load node:internal/modules/cjs/loader:1480:32
17
+ ❯ Module._load node:internal/modules/cjs/loader:1299:12
18
+ ❯ TracingChannel.traceSync node:diagnostics_channel:328:14
19
+ wrapModuleLoad node:internal/modules/cjs/loader:245:24
20
+ ❯ loadCJSModuleWithModuleLoad node:internal/modules/esm/translators:336:3
21
+ ❯ ModuleWrap.<anonymous> node:internal/modules/esm/translators:239:7
22
+
23
+ ⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯
24
+ Serialized Error: { code: 'ERR_INVALID_ARG_TYPE' }
25
+
26
+
27
+
28
+  ELIFECYCLE  Command failed with exit code 1.