@frontmcp/testing 0.6.3 → 0.7.1

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.
Files changed (94) hide show
  1. package/assertions/index.d.ts +1 -0
  2. package/assertions/index.d.ts.map +1 -0
  3. package/assertions/mcp-assertions.d.ts +1 -0
  4. package/assertions/mcp-assertions.d.ts.map +1 -0
  5. package/auth/auth-headers.d.ts +1 -0
  6. package/auth/auth-headers.d.ts.map +1 -0
  7. package/auth/index.d.ts +1 -0
  8. package/auth/index.d.ts.map +1 -0
  9. package/auth/mock-api-server.d.ts +61 -6
  10. package/auth/mock-api-server.d.ts.map +1 -0
  11. package/auth/mock-oauth-server.d.ts +1 -0
  12. package/auth/mock-oauth-server.d.ts.map +1 -0
  13. package/auth/token-factory.d.ts +1 -0
  14. package/auth/token-factory.d.ts.map +1 -0
  15. package/auth/user-fixtures.d.ts +1 -0
  16. package/auth/user-fixtures.d.ts.map +1 -0
  17. package/client/index.d.ts +1 -0
  18. package/client/index.d.ts.map +1 -0
  19. package/client/mcp-test-client.builder.d.ts +1 -0
  20. package/client/mcp-test-client.builder.d.ts.map +1 -0
  21. package/client/mcp-test-client.d.ts +1 -0
  22. package/client/mcp-test-client.d.ts.map +1 -0
  23. package/client/mcp-test-client.types.d.ts +1 -0
  24. package/client/mcp-test-client.types.d.ts.map +1 -0
  25. package/errors/index.d.ts +1 -0
  26. package/errors/index.d.ts.map +1 -0
  27. package/esm/index.mjs +169 -72
  28. package/esm/matchers/index.mjs +4 -14
  29. package/esm/package.json +3 -3
  30. package/esm/setup.mjs +4 -14
  31. package/example-tools/index.d.ts +1 -0
  32. package/example-tools/index.d.ts.map +1 -0
  33. package/example-tools/tool-configs.d.ts +15 -4
  34. package/example-tools/tool-configs.d.ts.map +1 -0
  35. package/expect.d.ts +1 -0
  36. package/expect.d.ts.map +1 -0
  37. package/fixtures/fixture-types.d.ts +1 -0
  38. package/fixtures/fixture-types.d.ts.map +1 -0
  39. package/fixtures/index.d.ts +1 -0
  40. package/fixtures/index.d.ts.map +1 -0
  41. package/fixtures/test-fixture.d.ts +1 -0
  42. package/fixtures/test-fixture.d.ts.map +1 -0
  43. package/http-mock/http-mock.d.ts +1 -0
  44. package/http-mock/http-mock.d.ts.map +1 -0
  45. package/http-mock/http-mock.types.d.ts +1 -0
  46. package/http-mock/http-mock.types.d.ts.map +1 -0
  47. package/http-mock/index.d.ts +1 -0
  48. package/http-mock/index.d.ts.map +1 -0
  49. package/index.d.ts +3 -2
  50. package/index.d.ts.map +1 -0
  51. package/index.js +170 -73
  52. package/interceptor/index.d.ts +1 -0
  53. package/interceptor/index.d.ts.map +1 -0
  54. package/interceptor/interceptor-chain.d.ts +1 -0
  55. package/interceptor/interceptor-chain.d.ts.map +1 -0
  56. package/interceptor/interceptor.types.d.ts +1 -0
  57. package/interceptor/interceptor.types.d.ts.map +1 -0
  58. package/interceptor/mock-registry.d.ts +1 -0
  59. package/interceptor/mock-registry.d.ts.map +1 -0
  60. package/matchers/index.d.ts +1 -0
  61. package/matchers/index.d.ts.map +1 -0
  62. package/matchers/index.js +4 -14
  63. package/matchers/matcher-types.d.ts +1 -0
  64. package/matchers/matcher-types.d.ts.map +1 -0
  65. package/matchers/mcp-matchers.d.ts +1 -0
  66. package/matchers/mcp-matchers.d.ts.map +1 -0
  67. package/package.json +3 -3
  68. package/platform/index.d.ts +2 -1
  69. package/platform/index.d.ts.map +1 -0
  70. package/platform/platform-client-info.d.ts +1 -0
  71. package/platform/platform-client-info.d.ts.map +1 -0
  72. package/platform/platform-types.d.ts +12 -12
  73. package/platform/platform-types.d.ts.map +1 -0
  74. package/playwright/index.d.ts +1 -0
  75. package/playwright/index.d.ts.map +1 -0
  76. package/server/index.d.ts +1 -0
  77. package/server/index.d.ts.map +1 -0
  78. package/server/test-server.d.ts +1 -0
  79. package/server/test-server.d.ts.map +1 -0
  80. package/setup.d.ts +1 -0
  81. package/setup.d.ts.map +1 -0
  82. package/setup.js +4 -14
  83. package/transport/index.d.ts +1 -0
  84. package/transport/index.d.ts.map +1 -0
  85. package/transport/streamable-http.transport.d.ts +1 -0
  86. package/transport/streamable-http.transport.d.ts.map +1 -0
  87. package/transport/transport.interface.d.ts +1 -0
  88. package/transport/transport.interface.d.ts.map +1 -0
  89. package/ui/index.d.ts +1 -0
  90. package/ui/index.d.ts.map +1 -0
  91. package/ui/ui-assertions.d.ts +5 -4
  92. package/ui/ui-assertions.d.ts.map +1 -0
  93. package/ui/ui-matchers.d.ts +1 -0
  94. package/ui/ui-matchers.d.ts.map +1 -0
package/index.js CHANGED
@@ -85,9 +85,9 @@ __export(index_exports, {
85
85
  interceptors: () => interceptors,
86
86
  isError: () => isError,
87
87
  isExtAppsPlatform: () => isExtAppsPlatform,
88
- isFrontmcpPlatform: () => isFrontmcpPlatform,
89
88
  isOpenAIPlatform: () => isOpenAIPlatform,
90
89
  isSuccessful: () => isSuccessful,
90
+ isUiPlatform: () => isUiPlatform,
91
91
  mcpMatchers: () => mcpMatchers,
92
92
  mockResponse: () => mockResponse,
93
93
  test: () => test,
@@ -2422,6 +2422,9 @@ var MockAPIServer = class {
2422
2422
  constructor(options) {
2423
2423
  this.options = options;
2424
2424
  this.routes = options.routes ?? [];
2425
+ for (const route of this.routes) {
2426
+ this.validateRoute(route);
2427
+ }
2425
2428
  }
2426
2429
  /**
2427
2430
  * Start the mock API server
@@ -2432,13 +2435,14 @@ var MockAPIServer = class {
2432
2435
  }
2433
2436
  const port = this.options.port ?? 0;
2434
2437
  return new Promise((resolve, reject) => {
2435
- this.server = (0, import_http2.createServer)(this.handleRequest.bind(this));
2436
- this.server.on("error", (err) => {
2438
+ const server = (0, import_http2.createServer)(this.handleRequest.bind(this));
2439
+ this.server = server;
2440
+ server.on("error", (err) => {
2437
2441
  this.log(`Server error: ${err.message}`);
2438
2442
  reject(err);
2439
2443
  });
2440
- this.server.listen(port, () => {
2441
- const address = this.server.address();
2444
+ server.listen(port, () => {
2445
+ const address = server.address();
2442
2446
  if (!address || typeof address === "string") {
2443
2447
  reject(new Error("Failed to get server address"));
2444
2448
  return;
@@ -2458,11 +2462,12 @@ var MockAPIServer = class {
2458
2462
  * Stop the mock API server
2459
2463
  */
2460
2464
  async stop() {
2461
- if (!this.server) {
2465
+ const server = this.server;
2466
+ if (!server) {
2462
2467
  return;
2463
2468
  }
2464
2469
  return new Promise((resolve, reject) => {
2465
- this.server.close((err) => {
2470
+ server.close((err) => {
2466
2471
  if (err) {
2467
2472
  reject(err);
2468
2473
  } else {
@@ -2487,6 +2492,7 @@ var MockAPIServer = class {
2487
2492
  * Add a route dynamically
2488
2493
  */
2489
2494
  addRoute(route) {
2495
+ this.validateRoute(route);
2490
2496
  this.routes.push(route);
2491
2497
  }
2492
2498
  /**
@@ -2498,6 +2504,18 @@ var MockAPIServer = class {
2498
2504
  // ═══════════════════════════════════════════════════════════════════
2499
2505
  // PRIVATE
2500
2506
  // ═══════════════════════════════════════════════════════════════════
2507
+ validateRoute(route) {
2508
+ const method = route.method ?? "UNKNOWN";
2509
+ const path = route.path ?? "<unknown>";
2510
+ const hasHandler = typeof route.handler === "function";
2511
+ const hasResponse = route.response != null;
2512
+ if (hasHandler && hasResponse) {
2513
+ throw new Error(`Mock route ${method} ${path} must define either 'handler' or 'response', not both`);
2514
+ }
2515
+ if (!hasHandler && !hasResponse) {
2516
+ throw new Error(`Mock route ${method} ${path} must define either 'handler' or 'response'`);
2517
+ }
2518
+ }
2501
2519
  async handleRequest(req, res) {
2502
2520
  const url = req.url ?? "/";
2503
2521
  const method = (req.method ?? "GET").toUpperCase();
@@ -2517,17 +2535,55 @@ var MockAPIServer = class {
2517
2535
  this.log("Served OpenAPI spec");
2518
2536
  return;
2519
2537
  }
2520
- const route = this.findRoute(method, url);
2521
- if (route) {
2522
- const status = route.response.status ?? 200;
2523
- const headers = {
2524
- "Content-Type": "application/json",
2525
- ...route.response.headers
2526
- };
2527
- res.writeHead(status, headers);
2528
- res.end(JSON.stringify(route.response.body));
2529
- this.log(`Matched route: ${method} ${route.path} -> ${status}`);
2530
- return;
2538
+ const matchResult = this.findRoute(method, url);
2539
+ if (matchResult) {
2540
+ const { route, params } = matchResult;
2541
+ if (route.handler) {
2542
+ let body;
2543
+ if (["POST", "PUT", "PATCH"].includes(method)) {
2544
+ body = await this.parseBody(req);
2545
+ }
2546
+ const queryString = url.includes("?") ? url.split("?")[1] : "";
2547
+ const query = {};
2548
+ if (queryString) {
2549
+ const searchParams = new URLSearchParams(queryString);
2550
+ searchParams.forEach((value, key) => {
2551
+ query[key] = value;
2552
+ });
2553
+ }
2554
+ const mockReq = {
2555
+ url,
2556
+ method,
2557
+ headers: this.normalizeHeaders(req.headers),
2558
+ params,
2559
+ query,
2560
+ body
2561
+ };
2562
+ const mockRes = {
2563
+ json: (responseBody, status = 200) => {
2564
+ res.writeHead(status, { "Content-Type": "application/json" });
2565
+ res.end(JSON.stringify(responseBody));
2566
+ },
2567
+ send: (responseBody, status = 200, headers = {}) => {
2568
+ res.writeHead(status, { "Content-Type": "application/json", ...headers });
2569
+ res.end(JSON.stringify(responseBody));
2570
+ }
2571
+ };
2572
+ await route.handler(mockReq, mockRes);
2573
+ this.log(`Matched route with handler: ${method} ${route.path}`);
2574
+ return;
2575
+ }
2576
+ if (route.response) {
2577
+ const status = route.response.status ?? 200;
2578
+ const headers = {
2579
+ "Content-Type": "application/json",
2580
+ ...route.response.headers
2581
+ };
2582
+ res.writeHead(status, headers);
2583
+ res.end(JSON.stringify(route.response.body));
2584
+ this.log(`Matched route: ${method} ${route.path} -> ${status}`);
2585
+ return;
2586
+ }
2531
2587
  }
2532
2588
  res.writeHead(404, { "Content-Type": "application/json" });
2533
2589
  res.end(JSON.stringify({ error: "not_found", message: `No mock for ${method} ${url}` }));
@@ -2539,18 +2595,87 @@ var MockAPIServer = class {
2539
2595
  }
2540
2596
  findRoute(method, url) {
2541
2597
  const path = url.split("?")[0];
2542
- return this.routes.find((route) => {
2543
- if (route.method !== method) return false;
2544
- if (route.path === path) return true;
2598
+ for (const route of this.routes) {
2599
+ if (route.method !== method) continue;
2600
+ if (route.path === path) {
2601
+ return { route, params: {} };
2602
+ }
2545
2603
  const routeParts = route.path.split("/");
2546
2604
  const urlParts = path.split("/");
2547
- if (routeParts.length !== urlParts.length) return false;
2548
- return routeParts.every((part, i) => {
2549
- if (part.startsWith(":")) return true;
2550
- return part === urlParts[i];
2551
- });
2605
+ if (routeParts.length !== urlParts.length) continue;
2606
+ const params = {};
2607
+ let match = true;
2608
+ for (let i = 0; i < routeParts.length; i++) {
2609
+ if (routeParts[i].startsWith(":")) {
2610
+ params[routeParts[i].slice(1)] = urlParts[i];
2611
+ } else if (routeParts[i] !== urlParts[i]) {
2612
+ match = false;
2613
+ break;
2614
+ }
2615
+ }
2616
+ if (match) {
2617
+ return { route, params };
2618
+ }
2619
+ }
2620
+ return void 0;
2621
+ }
2622
+ /**
2623
+ * Parse request body as JSON
2624
+ */
2625
+ async parseBody(req) {
2626
+ const maxBodyBytes = this.options.maxBodyBytes ?? 1 * 1024 * 1024;
2627
+ const bodyTimeoutMs = this.options.bodyTimeoutMs ?? 1e4;
2628
+ return new Promise((resolve, reject) => {
2629
+ let body = "";
2630
+ let bodyBytes = 0;
2631
+ const onData = (chunk) => {
2632
+ bodyBytes += chunk.length;
2633
+ if (bodyBytes > maxBodyBytes) {
2634
+ cleanup();
2635
+ req.destroy();
2636
+ reject(new Error(`Request body too large (>${maxBodyBytes} bytes)`));
2637
+ return;
2638
+ }
2639
+ body += chunk.toString();
2640
+ };
2641
+ const cleanup = () => {
2642
+ req.off("data", onData);
2643
+ req.off("end", onEnd);
2644
+ req.off("error", onError);
2645
+ clearTimeout(timeout);
2646
+ };
2647
+ const timeout = setTimeout(() => {
2648
+ cleanup();
2649
+ req.destroy();
2650
+ reject(new Error(`Request body read timed out after ${bodyTimeoutMs}ms`));
2651
+ }, bodyTimeoutMs);
2652
+ const onEnd = () => {
2653
+ cleanup();
2654
+ try {
2655
+ resolve(body ? JSON.parse(body) : void 0);
2656
+ } catch {
2657
+ resolve(body);
2658
+ }
2659
+ };
2660
+ const onError = (error) => {
2661
+ cleanup();
2662
+ reject(error);
2663
+ };
2664
+ req.on("data", onData);
2665
+ req.once("end", onEnd);
2666
+ req.once("error", onError);
2552
2667
  });
2553
2668
  }
2669
+ /**
2670
+ * Normalize headers to lowercase keys
2671
+ */
2672
+ normalizeHeaders(headers) {
2673
+ const normalized = {};
2674
+ for (const [key, value] of Object.entries(headers)) {
2675
+ normalized[key.toLowerCase()] = Array.isArray(value) ? value[0] : value;
2676
+ }
2677
+ return normalized;
2678
+ }
2554
2679
  log(message) {
2555
2680
  if (this.options.debug) {
2556
2681
  console.log(`[MockAPIServer] ${message}`);
@@ -3254,10 +3379,8 @@ function getPlatformMetaNamespace(platform) {
3254
3379
  switch (platform) {
3255
3380
  case "openai":
3256
3381
  return "openai";
3257
- case "ext-apps":
3258
- return "ui";
3259
3382
  default:
3260
- return "frontmcp";
3383
+ return "ui";
3261
3384
  }
3262
3385
  }
3263
3386
  function getPlatformMimeType(platform) {
@@ -3269,37 +3392,31 @@ function isOpenAIPlatform(platform) {
3269
3392
  function isExtAppsPlatform(platform) {
3270
3393
  return platform === "ext-apps";
3271
3394
  }
3272
- function isFrontmcpPlatform(platform) {
3273
- return platform !== "openai" && platform !== "ext-apps";
3395
+ function isUiPlatform(platform) {
3396
+ return platform !== "openai";
3274
3397
  }
3275
3398
  function getToolsListMetaPrefixes(platform) {
3276
3399
  switch (platform) {
3277
3400
  case "openai":
3278
3401
  return ["openai/"];
3279
- case "ext-apps":
3280
- return ["ui/"];
3281
3402
  default:
3282
- return ["frontmcp/", "ui/"];
3403
+ return ["ui/"];
3283
3404
  }
3284
3405
  }
3285
3406
  function getToolCallMetaPrefixes(platform) {
3286
3407
  switch (platform) {
3287
3408
  case "openai":
3288
3409
  return ["openai/"];
3289
- case "ext-apps":
3290
- return ["ui/"];
3291
3410
  default:
3292
- return ["frontmcp/", "ui/"];
3411
+ return ["ui/"];
3293
3412
  }
3294
3413
  }
3295
3414
  function getForbiddenMetaPrefixes(platform) {
3296
3415
  switch (platform) {
3297
3416
  case "openai":
3298
3417
  return ["ui/", "frontmcp/"];
3299
- case "ext-apps":
3300
- return ["openai/", "frontmcp/"];
3301
3418
  default:
3302
- return ["openai/"];
3419
+ return ["openai/", "frontmcp/"];
3303
3420
  }
3304
3421
  }
3305
3422
 
@@ -3580,11 +3697,8 @@ var toHavePlatformMimeType = function(received, platform) {
3580
3697
  case "openai":
3581
3698
  mimeTypeKey = "openai/mimeType";
3582
3699
  break;
3583
- case "ext-apps":
3584
- mimeTypeKey = "ui/mimeType";
3585
- break;
3586
3700
  default:
3587
- mimeTypeKey = "frontmcp/mimeType";
3701
+ mimeTypeKey = "ui/mimeType";
3588
3702
  }
3589
3703
  const actualMimeType = meta[mimeTypeKey];
3590
3704
  const pass = actualMimeType === expectedMimeType;
@@ -3606,11 +3720,8 @@ var toHavePlatformHtml = function(received, platform) {
3606
3720
  case "openai":
3607
3721
  htmlKey = "openai/html";
3608
3722
  break;
3609
- case "ext-apps":
3610
- htmlKey = "ui/html";
3611
- break;
3612
3723
  default:
3613
- htmlKey = "frontmcp/html";
3724
+ htmlKey = "ui/html";
3614
3725
  }
3615
3726
  const html = meta[htmlKey];
3616
3727
  const pass = typeof html === "string" && html.length > 0;
@@ -4533,12 +4644,12 @@ var UIAssertions = {
4533
4644
  UIAssertions.assertPlatformMeta(result, "ext-apps");
4534
4645
  },
4535
4646
  /**
4536
- * Assert tool result has correct meta keys for FrontMCP platforms (Claude, Cursor, etc.).
4537
- * Verifies frontmcp/* + ui/* keys are present and openai/* keys are absent.
4647
+ * Assert tool result has correct meta keys for ui/* platforms (Claude, Cursor, etc.).
4648
+ * Verifies ui/* keys are present and openai/*, frontmcp/* keys are absent.
4538
4649
  * @param result - The tool result wrapper
4539
- * @throws Error if meta keys don't match FrontMCP expectations
4650
+ * @throws Error if meta keys don't match ui/* expectations
4540
4651
  */
4541
- assertFrontmcpMeta(result) {
4652
+ assertUiMeta(result) {
4542
4653
  UIAssertions.assertPlatformMeta(result, "claude");
4543
4654
  },
4544
4655
  /**
@@ -4604,11 +4715,8 @@ var UIAssertions = {
4604
4715
  case "openai":
4605
4716
  mimeTypeKey = "openai/mimeType";
4606
4717
  break;
4607
- case "ext-apps":
4608
- mimeTypeKey = "ui/mimeType";
4609
- break;
4610
4718
  default:
4611
- mimeTypeKey = "frontmcp/mimeType";
4719
+ mimeTypeKey = "ui/mimeType";
4612
4720
  }
4613
4721
  const actualMimeType = meta[mimeTypeKey];
4614
4722
  if (actualMimeType !== expectedMimeType) {
@@ -4634,11 +4742,8 @@ var UIAssertions = {
4634
4742
  case "openai":
4635
4743
  htmlKey = "openai/html";
4636
4744
  break;
4637
- case "ext-apps":
4638
- htmlKey = "ui/html";
4639
- break;
4640
4745
  default:
4641
- htmlKey = "frontmcp/html";
4746
+ htmlKey = "ui/html";
4642
4747
  }
4643
4748
  const html = meta[htmlKey];
4644
4749
  if (typeof html !== "string" || html.length === 0) {
@@ -4787,18 +4892,10 @@ var EXPECTED_OPENAI_TOOLS_LIST_META_KEYS = [
4787
4892
  var EXPECTED_OPENAI_TOOL_CALL_META_KEYS = ["openai/html", "openai/mimeType", "openai/type"];
4788
4893
  var EXPECTED_EXTAPPS_TOOLS_LIST_META_KEYS = ["ui/resourceUri", "ui/mimeType", "ui/cdn", "ui/type"];
4789
4894
  var EXPECTED_EXTAPPS_TOOL_CALL_META_KEYS = ["ui/html", "ui/mimeType", "ui/type"];
4790
- var EXPECTED_FRONTMCP_TOOLS_LIST_META_KEYS = [
4791
- "frontmcp/outputTemplate",
4792
- "frontmcp/resultCanProduceWidget",
4793
- "ui/cdn",
4794
- "ui/type"
4795
- ];
4796
- var EXPECTED_FRONTMCP_TOOL_CALL_META_KEYS = [
4797
- "frontmcp/html",
4798
- "frontmcp/mimeType",
4799
- "ui/html",
4800
- "ui/mimeType"
4801
- ];
4895
+ var EXPECTED_GENERIC_TOOLS_LIST_META_KEYS = ["ui/resourceUri", "ui/mimeType", "ui/cdn", "ui/type"];
4896
+ var EXPECTED_GENERIC_TOOL_CALL_META_KEYS = ["ui/html", "ui/mimeType", "ui/type"];
4897
+ var EXPECTED_FRONTMCP_TOOLS_LIST_META_KEYS = EXPECTED_GENERIC_TOOLS_LIST_META_KEYS;
4898
+ var EXPECTED_FRONTMCP_TOOL_CALL_META_KEYS = EXPECTED_GENERIC_TOOL_CALL_META_KEYS;
4802
4899
  // Annotate the CommonJS export names for ESM import in node:
4803
4900
  0 && (module.exports = {
4804
4901
  AssertionError,
@@ -4856,9 +4953,9 @@ var EXPECTED_FRONTMCP_TOOL_CALL_META_KEYS = [
4856
4953
  interceptors,
4857
4954
  isError,
4858
4955
  isExtAppsPlatform,
4859
- isFrontmcpPlatform,
4860
4956
  isOpenAIPlatform,
4861
4957
  isSuccessful,
4958
+ isUiPlatform,
4862
4959
  mcpMatchers,
4863
4960
  mockResponse,
4864
4961
  test,
@@ -5,3 +5,4 @@
5
5
  export type { InterceptorContext, InterceptorResult, RequestInterceptor, ResponseInterceptorContext, ResponseInterceptorResult, ResponseInterceptor, MockDefinition, MockRegistry, MockHandle, InterceptorChain, } from './interceptor.types';
6
6
  export { DefaultMockRegistry, mockResponse } from './mock-registry';
7
7
  export { DefaultInterceptorChain, interceptors } from './interceptor-chain';
8
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/interceptor/index.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAGH,YAAY,EACV,kBAAkB,EAClB,iBAAiB,EACjB,kBAAkB,EAClB,0BAA0B,EAC1B,yBAAyB,EACzB,mBAAmB,EACnB,cAAc,EACd,YAAY,EACZ,UAAU,EACV,gBAAgB,GACjB,MAAM,qBAAqB,CAAC;AAG7B,OAAO,EAAE,mBAAmB,EAAE,YAAY,EAAE,MAAM,iBAAiB,CAAC;AACpE,OAAO,EAAE,uBAAuB,EAAE,YAAY,EAAE,MAAM,qBAAqB,CAAC"}
@@ -75,3 +75,4 @@ export declare const interceptors: {
75
75
  */
76
76
  modifyResponse(method: string, modifier: (response: JsonRpcResponse) => JsonRpcResponse): ResponseInterceptor;
77
77
  };
78
+ //# sourceMappingURL=interceptor-chain.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"interceptor-chain.d.ts","sourceRoot":"","sources":["../../src/interceptor/interceptor-chain.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,KAAK,EAAE,cAAc,EAAE,eAAe,EAAE,MAAM,kCAAkC,CAAC;AACxF,OAAO,KAAK,EACV,gBAAgB,EAChB,kBAAkB,EAClB,mBAAmB,EACnB,kBAAkB,EAIlB,YAAY,EACb,MAAM,qBAAqB,CAAC;AAG7B;;GAEG;AACH,qBAAa,uBAAwB,YAAW,gBAAgB;IAC9D,OAAO,EAAE,kBAAkB,EAAE,CAAM;IACnC,QAAQ,EAAE,mBAAmB,EAAE,CAAM;IACrC,KAAK,EAAE,YAAY,CAAC;;IAMpB;;OAEG;IACH,qBAAqB,CAAC,WAAW,EAAE,kBAAkB,GAAG,MAAM,IAAI;IAUlE;;OAEG;IACH,sBAAsB,CAAC,WAAW,EAAE,mBAAmB,GAAG,MAAM,IAAI;IAUpE;;;;;;OAMG;IACG,cAAc,CAClB,OAAO,EAAE,cAAc,EACvB,IAAI,EAAE,kBAAkB,CAAC,MAAM,CAAC,GAC/B,OAAO,CACN;QAAE,IAAI,EAAE,UAAU,CAAC;QAAC,OAAO,EAAE,cAAc,CAAA;KAAE,GAC7C;QAAE,IAAI,EAAE,MAAM,CAAC;QAAC,QAAQ,EAAE,eAAe,CAAA;KAAE,GAC3C;QAAE,IAAI,EAAE,OAAO,CAAC;QAAC,KAAK,EAAE,KAAK,CAAA;KAAE,CAClC;IAyDD;;OAEG;IACG,eAAe,CACnB,OAAO,EAAE,cAAc,EACvB,QAAQ,EAAE,eAAe,EACzB,UAAU,EAAE,MAAM,GACjB,OAAO,CAAC,eAAe,CAAC;IA0B3B;;OAEG;IACH,KAAK,IAAI,IAAI;CAKd;AASD;;GAEG;AACH,eAAO,MAAM,YAAY;IACvB;;OAEG;mBACW,CAAC,OAAO,EAAE,MAAM,EAAE,IAAI,CAAC,EAAE,OAAO,KAAK,IAAI,GAAiB,kBAAkB;IAO1F;;OAEG;cACO,MAAM,GAAG,kBAAkB;IAOrC;;OAEG;wBACiB,CAAC,GAAG,EAAE,kBAAkB,KAAK,OAAO,SAAS,KAAK,GAAG,MAAM,GAAG,kBAAkB;IAUpG;;OAEG;yBACkB,MAAM,YAAY,CAAC,OAAO,EAAE,cAAc,KAAK,cAAc,GAAG,kBAAkB;IASvG;;OAEG;2BACmB,CAAC,OAAO,EAAE,MAAM,EAAE,IAAI,CAAC,EAAE,OAAO,KAAK,IAAI,GAAiB,mBAAmB;IAQnG;;OAEG;2BACoB,MAAM,YAAY,CAAC,QAAQ,EAAE,eAAe,KAAK,eAAe,GAAG,mBAAmB;CAQ9G,CAAC"}
@@ -129,3 +129,4 @@ export interface InterceptorChain {
129
129
  */
130
130
  processResponse(request: JsonRpcRequest, response: JsonRpcResponse, durationMs: number): Promise<JsonRpcResponse>;
131
131
  }
132
+ //# sourceMappingURL=interceptor.types.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"interceptor.types.d.ts","sourceRoot":"","sources":["../../src/interceptor/interceptor.types.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,KAAK,EAAE,cAAc,EAAE,eAAe,EAAE,MAAM,kCAAkC,CAAC;AAExF;;GAEG;AACH,MAAM,WAAW,kBAAkB;IACjC,2BAA2B;IAC3B,OAAO,EAAE,cAAc,CAAC;IACxB,uBAAuB;IACvB,IAAI,EAAE;QACJ,sCAAsC;QACtC,SAAS,EAAE,IAAI,CAAC;QAChB,gCAAgC;QAChC,SAAS,EAAE,MAAM,CAAC;QAClB,8BAA8B;QAC9B,SAAS,CAAC,EAAE,MAAM,CAAC;KACpB,CAAC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AAE,UAAU,EAAE,MAAM,GAAG,OAAO,CAAC,eAAe,CAAC,CAAC;CACnH"}
@@ -80,3 +80,4 @@ export declare const mockResponse: {
80
80
  forbidden: (id?: string | number | null) => JsonRpcResponse;
81
81
  };
82
82
  };
83
+ //# sourceMappingURL=mock-registry.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"mock-registry.d.ts","sourceRoot":"","sources":["../../src/interceptor/mock-registry.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,KAAK,EAAE,cAAc,EAAE,eAAe,EAAE,MAAM,kCAAkC,CAAC;AACxF,OAAO,KAAK,EAAE,cAAc,EAAE,YAAY,EAAE,UAAU,EAAE,MAAM,qBAAqB,CAAC;AAYpF;;GAEG;AACH,qBAAa,mBAAoB,YAAW,YAAY;IACtD,OAAO,CAAC,KAAK,CAAmB;IAEhC,GAAG,CAAC,IAAI,EAAE,cAAc,GAAG,UAAU;IAsBrC,KAAK,IAAI,IAAI;IAIb,MAAM,IAAI,cAAc,EAAE;IAI1B,KAAK,CAAC,OAAO,EAAE,cAAc,GAAG,cAAc,GAAG,SAAS;IAiC1D;;OAEG;IACH,OAAO,CAAC,WAAW;CAkCpB;AAED;;GAEG;AACH,eAAO,MAAM,YAAY;IACvB;;OAEG;YACK,CAAC,UAAU,CAAC,OAAM,MAAM,GAAG,MAAM,GAAO,eAAe;IAQ/D;;OAEG;gBACS,MAAM,WAAW,MAAM,SAAS,OAAO,OAAM,MAAM,GAAG,MAAM,GAAG,IAAI,GAAO,eAAe;IAQrG;;OAEG;wBAEQ,KAAK,CAAC;QAAE,IAAI,EAAE,MAAM,CAAC;QAAC,IAAI,EAAE,MAAM,CAAA;KAAE,GAAG;QAAE,IAAI,EAAE,OAAO,CAAC;QAAC,IAAI,EAAE,MAAM,CAAC;QAAC,QAAQ,EAAE,MAAM,CAAA;KAAE,CAAC,OAC9F,MAAM,GAAG,MAAM,GAClB,eAAe;IAQlB;;OAEG;qBAEM,KAAK,CAAC;QAAE,IAAI,EAAE,MAAM,CAAC;QAAC,WAAW,CAAC,EAAE,MAAM,CAAC;QAAC,WAAW,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAA;KAAE,CAAC,OACvF,MAAM,GAAG,MAAM,GAClB,eAAe;IAQlB;;OAEG;6BAEU,KAAK,CAAC;QAAE,GAAG,EAAE,MAAM,CAAC;QAAC,IAAI,CAAC,EAAE,MAAM,CAAC;QAAC,WAAW,CAAC,EAAE,MAAM,CAAC;QAAC,QAAQ,CAAC,EAAE,MAAM,CAAA;KAAE,CAAC,OACrF,MAAM,GAAG,MAAM,GAClB,eAAe;IAQlB;;OAEG;2BAES,KAAK,CAAC;QAAE,GAAG,EAAE,MAAM,CAAC;QAAC,IAAI,CAAC,EAAE,MAAM,CAAC;QAAC,IAAI,CAAC,EAAE,MAAM,CAAC;QAAC,QAAQ,CAAC,EAAE,MAAM,CAAA;KAAE,CAAC,OAC7E,MAAM,GAAG,MAAM,GAClB,eAAe;IAQlB;;OAEG;;iCAEwB,MAAM,OAAM,MAAM,GAAG,MAAM,GAAG,IAAI;iCAGlC,MAAM,OAAM,MAAM,GAAG,MAAM,GAAG,IAAI;iCAGlC,MAAM,OAAM,MAAM,GAAG,MAAM,GAAG,IAAI;gCAGnC,MAAM,OAAM,MAAM,GAAG,MAAM,GAAG,IAAI;6BAGrC,MAAM,OAAM,MAAM,GAAG,MAAM,GAAG,IAAI;4BAGpC,MAAM,GAAG,MAAM,GAAG,IAAI;yBAEzB,MAAM,GAAG,MAAM,GAAG,IAAI;;CAEzC,CAAC"}
@@ -5,3 +5,4 @@
5
5
  export { mcpMatchers } from './mcp-matchers';
6
6
  export type { McpMatchers } from './matcher-types';
7
7
  import './matcher-types';
8
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/matchers/index.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAC;AAG7C,YAAY,EAAE,WAAW,EAAE,MAAM,iBAAiB,CAAC;AAGnD,OAAO,iBAAiB,CAAC"}
package/matchers/index.js CHANGED
@@ -32,20 +32,16 @@ function getToolCallMetaPrefixes(platform) {
32
32
  switch (platform) {
33
33
  case "openai":
34
34
  return ["openai/"];
35
- case "ext-apps":
36
- return ["ui/"];
37
35
  default:
38
- return ["frontmcp/", "ui/"];
36
+ return ["ui/"];
39
37
  }
40
38
  }
41
39
  function getForbiddenMetaPrefixes(platform) {
42
40
  switch (platform) {
43
41
  case "openai":
44
42
  return ["ui/", "frontmcp/"];
45
- case "ext-apps":
46
- return ["openai/", "frontmcp/"];
47
43
  default:
48
- return ["openai/"];
44
+ return ["openai/", "frontmcp/"];
49
45
  }
50
46
  }
51
47
 
@@ -326,11 +322,8 @@ var toHavePlatformMimeType = function(received, platform) {
326
322
  case "openai":
327
323
  mimeTypeKey = "openai/mimeType";
328
324
  break;
329
- case "ext-apps":
330
- mimeTypeKey = "ui/mimeType";
331
- break;
332
325
  default:
333
- mimeTypeKey = "frontmcp/mimeType";
326
+ mimeTypeKey = "ui/mimeType";
334
327
  }
335
328
  const actualMimeType = meta[mimeTypeKey];
336
329
  const pass = actualMimeType === expectedMimeType;
@@ -352,11 +345,8 @@ var toHavePlatformHtml = function(received, platform) {
352
345
  case "openai":
353
346
  htmlKey = "openai/html";
354
347
  break;
355
- case "ext-apps":
356
- htmlKey = "ui/html";
357
- break;
358
348
  default:
359
- htmlKey = "frontmcp/html";
349
+ htmlKey = "ui/html";
360
350
  }
361
351
  const html = meta[htmlKey];
362
352
  const pass = typeof html === "string" && html.length > 0;
@@ -264,3 +264,4 @@ declare global {
264
264
  }
265
265
  }
266
266
  export {};
267
+ //# sourceMappingURL=matcher-types.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"matcher-types.d.ts","sourceRoot":"","sources":["../../src/matchers/matcher-types.ts"],"names":[],"mappings":"AAAA;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mBAAmB,CAAC,KAAK,EAAE,MAAM,GAAG,MAAM,GAAG,CAAC,CAAC;IAE/C;;;;;;;OAOG;IACH,WAAW,IAAI,CAAC,CAAC;IAEjB;;;;;;;OAOG;IACH,oBAAoB,IAAI,CAAC,CAAC;IAE1B;;;;;;;;OAQG;IACH,cAAc,CAAC,SAAS,EAAE,MAAM,GAAG,CAAC,CAAC;IAErC;;;;;;;;;OASG;IACH,sBAAsB,CAAC,OAAO,EAAE,MAAM,GAAG,CAAC,CAAC;IAE3C;;;;;;;OAOG;IACH,yBAAyB,IAAI,CAAC,CAAC;CAChC;AAQD,OAAO,CAAC,MAAM,CAAC;IACb,UAAU,IAAI,CAAC;QAEb,UAAU,QAAQ,CAAC,CAAC,CAAE,SAAQ,WAAW,CAAC,CAAC,CAAC;SAAG;QAG/C,UAAU,MAAO,SAAQ,WAAW,CAAC,IAAI,CAAC;SAAG;QAG7C,UAAU,yBAA0B,SAAQ,WAAW,CAAC,IAAI,CAAC;SAAG;KACjE;CACF;AAID,OAAO,EAAE,CAAC"}
@@ -52,3 +52,4 @@ export declare const mcpMatchers: {
52
52
  toHaveError: MatcherFunction<[]>;
53
53
  toHaveErrorCode: MatcherFunction<[code: number]>;
54
54
  };
55
+ //# sourceMappingURL=mcp-matchers.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"mcp-matchers.d.ts","sourceRoot":"","sources":["../../src/matchers/mcp-matchers.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;GAiBG;AAEH,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,QAAQ,CAAC;AA+a9C;;GAEG;AACH,eAAO,MAAM,WAAW;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CA0BvB,CAAC"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@frontmcp/testing",
3
- "version": "0.6.3",
3
+ "version": "0.7.1",
4
4
  "description": "E2E testing framework for FrontMCP servers - MCP client, auth mocks, Playwright integration",
5
5
  "author": "AgentFront <info@agentfront.dev>",
6
6
  "homepage": "https://docs.agentfront.dev",
@@ -87,8 +87,8 @@
87
87
  "./esm": null
88
88
  },
89
89
  "peerDependencies": {
90
- "@frontmcp/sdk": "0.6.3",
91
- "@frontmcp/ui": "0.6.3",
90
+ "@frontmcp/sdk": "0.7.1",
91
+ "@frontmcp/ui": "0.7.1",
92
92
  "@playwright/test": "^1.40.0",
93
93
  "jest": "^29.0.0",
94
94
  "@jest/globals": "^29.0.0"
@@ -23,6 +23,7 @@
23
23
  * ```
24
24
  */
25
25
  export type { TestPlatformType, PlatformMetaNamespace } from './platform-types';
26
- export { getPlatformMetaNamespace, getPlatformMimeType, isOpenAIPlatform, isExtAppsPlatform, isFrontmcpPlatform, getToolsListMetaPrefixes, getToolCallMetaPrefixes, getForbiddenMetaPrefixes, } from './platform-types';
26
+ export { getPlatformMetaNamespace, getPlatformMimeType, isOpenAIPlatform, isExtAppsPlatform, isUiPlatform, getToolsListMetaPrefixes, getToolCallMetaPrefixes, getForbiddenMetaPrefixes, } from './platform-types';
27
27
  export type { TestClientInfo, TestClientCapabilities, ExperimentalCapabilities, McpAppsExtension, } from './platform-client-info';
28
28
  export { getPlatformClientInfo, buildUserAgent, getPlatformUserAgent, PLATFORM_DETECTION_PATTERNS, MCP_APPS_EXTENSION_KEY, getPlatformCapabilities, requiresCapabilityDetection, } from './platform-client-info';
29
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/platform/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;GAuBG;AAGH,YAAY,EAAE,gBAAgB,EAAE,qBAAqB,EAAE,MAAM,kBAAkB,CAAC;AAGhF,OAAO,EACL,wBAAwB,EACxB,mBAAmB,EACnB,gBAAgB,EAChB,iBAAiB,EACjB,YAAY,EACZ,wBAAwB,EACxB,uBAAuB,EACvB,wBAAwB,GACzB,MAAM,kBAAkB,CAAC;AAG1B,YAAY,EACV,cAAc,EACd,sBAAsB,EACtB,wBAAwB,EACxB,gBAAgB,GACjB,MAAM,wBAAwB,CAAC;AAEhC,OAAO,EACL,qBAAqB,EACrB,cAAc,EACd,oBAAoB,EACpB,2BAA2B,EAE3B,sBAAsB,EACtB,uBAAuB,EACvB,2BAA2B,GAC5B,MAAM,wBAAwB,CAAC"}
@@ -95,3 +95,4 @@ export declare function getPlatformCapabilities(platform: TestPlatformType): Tes
95
95
  * Check if a platform requires capability-based detection (vs User-Agent).
96
96
  */
97
97
  export declare function requiresCapabilityDetection(platform: TestPlatformType): boolean;
98
+ //# sourceMappingURL=platform-client-info.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"platform-client-info.d.ts","sourceRoot":"","sources":["../../src/platform/platform-client-info.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;GAgBG;AAEH,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,kBAAkB,CAAC;AAEzD;;GAEG;AACH,eAAO,MAAM,sBAAsB,EAAG,4BAAqC,CAAC;AAE5E;;;GAGG;AACH,MAAM,WAAW,cAAc;IAC7B,+CAA+C;IAC/C,IAAI,EAAE,MAAM,CAAC;IACb,qBAAqB;IACrB,OAAO,EAAE,MAAM,CAAC;CACjB;AAED;;;;;;GAMG;AACH,wBAAgB,qBAAqB,CAAC,QAAQ,EAAE,gBAAgB,GAAG,cAAc,CAiDhF;AAED;;;;;;;;;GASG;AACH,wBAAgB,cAAc,CAAC,UAAU,EAAE,cAAc,GAAG,MAAM,CAEjE;AAED;;GAEG;AACH,wBAAgB,oBAAoB,CAAC,QAAQ,EAAE,gBAAgB,GAAG,MAAM,CAEvE;AAED;;;;;GAKG;AACH,eAAO,MAAM,2BAA2B,EAAE,MAAM,CAAC,gBAAgB,EAAE,MAAM,CAUxE,CAAC;AAMF;;GAEG;AACH,MAAM,WAAW,gBAAgB;IAC/B,2BAA2B;IAC3B,SAAS,CAAC,EAAE,MAAM,EAAE,CAAC;CACtB;AAED;;GAEG;AACH,MAAM,WAAW,wBAAwB;IACvC,CAAC,sBAAsB,CAAC,CAAC,EAAE,gBAAgB,CAAC;IAC5C,CAAC,GAAG,EAAE,MAAM,GAAG,OAAO,CAAC;CACxB;AAED;;GAEG;AACH,MAAM,WAAW,sBAAsB;IACrC,QAAQ,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;IACnC,YAAY,CAAC,EAAE,wBAAwB,CAAC;CACzC;AAED;;;;;;;;GAQG;AACH,wBAAgB,uBAAuB,CAAC,QAAQ,EAAE,gBAAgB,GAAG,sBAAsB,CAkB1F;AAED;;GAEG;AACH,wBAAgB,2BAA2B,CAAC,QAAQ,EAAE,gBAAgB,GAAG,OAAO,CAE/E"}
@@ -17,23 +17,22 @@
17
17
  *
18
18
  * - `openai`: OpenAI ChatGPT (uses openai/* meta keys)
19
19
  * - `ext-apps`: MCP Apps per SEP-1865 (uses ui/* meta keys)
20
- * - `claude`: Claude Desktop (uses frontmcp/* + ui/* keys)
21
- * - `cursor`: Cursor IDE (uses frontmcp/* + ui/* keys)
22
- * - `continue`: Continue Dev (uses frontmcp/* + ui/* keys)
23
- * - `cody`: Sourcegraph Cody (uses frontmcp/* + ui/* keys)
24
- * - `gemini`: Google Gemini (uses frontmcp/* + ui/* keys)
25
- * - `generic-mcp`: Generic MCP client (uses frontmcp/* + ui/* keys)
26
- * - `unknown`: Unknown platform (uses frontmcp/* + ui/* keys)
20
+ * - `claude`: Claude Desktop (uses ui/* keys only)
21
+ * - `cursor`: Cursor IDE (uses ui/* keys only)
22
+ * - `continue`: Continue Dev (uses ui/* keys only)
23
+ * - `cody`: Sourcegraph Cody (uses ui/* keys only)
24
+ * - `gemini`: Google Gemini (uses ui/* keys only)
25
+ * - `generic-mcp`: Generic MCP client (uses ui/* keys only)
26
+ * - `unknown`: Unknown platform (uses ui/* keys only)
27
27
  */
28
28
  export type TestPlatformType = 'openai' | 'ext-apps' | 'claude' | 'cursor' | 'continue' | 'cody' | 'gemini' | 'generic-mcp' | 'unknown';
29
29
  /**
30
30
  * Platform meta namespace used for tool responses.
31
31
  *
32
32
  * - `openai`: Uses `openai/*` keys only
33
- * - `ui`: Uses `ui/*` keys only (ext-apps per SEP-1865)
34
- * - `frontmcp`: Uses `frontmcp/*` + `ui/*` keys for compatibility
33
+ * - `ui`: Uses `ui/*` keys only (all non-OpenAI platforms)
35
34
  */
36
- export type PlatformMetaNamespace = 'openai' | 'ui' | 'frontmcp';
35
+ export type PlatformMetaNamespace = 'openai' | 'ui';
37
36
  /**
38
37
  * Get the meta namespace for a platform type.
39
38
  */
@@ -54,9 +53,9 @@ export declare function isOpenAIPlatform(platform: TestPlatformType): boolean;
54
53
  */
55
54
  export declare function isExtAppsPlatform(platform: TestPlatformType): boolean;
56
55
  /**
57
- * Check if a platform uses FrontMCP meta keys (non-OpenAI, non-ext-apps).
56
+ * Check if a platform uses ui/* meta keys (non-OpenAI).
58
57
  */
59
- export declare function isFrontmcpPlatform(platform: TestPlatformType): boolean;
58
+ export declare function isUiPlatform(platform: TestPlatformType): boolean;
60
59
  /**
61
60
  * Get all expected meta key prefixes for a platform's tools/list response.
62
61
  */
@@ -70,3 +69,4 @@ export declare function getToolCallMetaPrefixes(platform: TestPlatformType): str
70
69
  * These prefixes should NOT appear in responses for the given platform.
71
70
  */
72
71
  export declare function getForbiddenMetaPrefixes(platform: TestPlatformType): string[];
72
+ //# sourceMappingURL=platform-types.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"platform-types.d.ts","sourceRoot":"","sources":["../../src/platform/platform-types.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;GAaG;AAEH;;;;;;;;;;;;GAYG;AACH,MAAM,MAAM,gBAAgB,GACxB,QAAQ,GACR,UAAU,GACV,QAAQ,GACR,QAAQ,GACR,UAAU,GACV,MAAM,GACN,QAAQ,GACR,aAAa,GACb,SAAS,CAAC;AAEd;;;;;GAKG;AACH,MAAM,MAAM,qBAAqB,GAAG,QAAQ,GAAG,IAAI,CAAC;AAEpD;;GAEG;AACH,wBAAgB,wBAAwB,CAAC,QAAQ,EAAE,gBAAgB,GAAG,qBAAqB,CAQ1F;AAED;;;;;GAKG;AACH,wBAAgB,mBAAmB,CAAC,QAAQ,EAAE,gBAAgB,GAAG,MAAM,CAEtE;AAED;;GAEG;AACH,wBAAgB,gBAAgB,CAAC,QAAQ,EAAE,gBAAgB,GAAG,OAAO,CAEpE;AAED;;GAEG;AACH,wBAAgB,iBAAiB,CAAC,QAAQ,EAAE,gBAAgB,GAAG,OAAO,CAErE;AAED;;GAEG;AACH,wBAAgB,YAAY,CAAC,QAAQ,EAAE,gBAAgB,GAAG,OAAO,CAEhE;AAED;;GAEG;AACH,wBAAgB,wBAAwB,CAAC,QAAQ,EAAE,gBAAgB,GAAG,MAAM,EAAE,CAQ7E;AAED;;GAEG;AACH,wBAAgB,uBAAuB,CAAC,QAAQ,EAAE,gBAAgB,GAAG,MAAM,EAAE,CAQ5E;AAED;;;GAGG;AACH,wBAAgB,wBAAwB,CAAC,QAAQ,EAAE,gBAAgB,GAAG,MAAM,EAAE,CAS7E"}
@@ -35,3 +35,4 @@ export declare function test(_name: string, _fn: () => Promise<void>): void;
35
35
  export declare const expect: {
36
36
  notImplemented: boolean;
37
37
  };
38
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/playwright/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;GA2BG;AAGH,eAAO,MAAM,qBAAqB;;;;CAIjC,CAAC;AAGF,wBAAgB,IAAI,CAAC,KAAK,EAAE,MAAM,EAAE,GAAG,EAAE,MAAM,OAAO,CAAC,IAAI,CAAC,GAAG,IAAI,CAMlE;AAGD,eAAO,MAAM,MAAM;;CAElB,CAAC"}
package/server/index.d.ts CHANGED
@@ -4,3 +4,4 @@
4
4
  */
5
5
  export { TestServer } from './test-server';
6
6
  export type { TestServerOptions, TestServerInfo } from './test-server';
7
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/server/index.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,EAAE,UAAU,EAAE,MAAM,eAAe,CAAC;AAC3C,YAAY,EAAE,iBAAiB,EAAE,cAAc,EAAE,MAAM,eAAe,CAAC"}