counterfact 0.15.0 → 0.15.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.
package/CHANGELOG.md CHANGED
@@ -1,5 +1,11 @@
1
1
  # counterfact
2
2
 
3
+ ## 0.15.1
4
+
5
+ ### Patch Changes
6
+
7
+ - b7509d9: fix an issue where importing from $.context.ts did not work
8
+
3
9
  ## 0.15.0
4
10
 
5
11
  ### Minor Changes
package/README.md CHANGED
@@ -77,7 +77,8 @@ export const POST = ({ context, response, body }) => {
77
77
  ```
78
78
 
79
79
  ```js
80
- // ./paths/$.context.js
80
+
81
+ // ./paths/$.context.ts
81
82
  class PetStore () {
82
83
  pets = {};
83
84
 
package/docs/usage.md CHANGED
@@ -139,7 +139,7 @@ export const POST: HTTP_POST = ($) => {
139
139
  };
140
140
  ```
141
141
 
142
- The `context` object is defined in `$.context.js` in the same directory as the file that uses it. It's up to you to define the API for a context object. For example, your `$.context.js` file might look like this.
142
+ The `context` object is defined in `$.context.ts` in the same directory as the file that uses it. It's up to you to define the API for a context object. For example, your `$.context.ts` file might look like this.
143
143
 
144
144
  ```ts
145
145
  class PetStore {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "counterfact",
3
- "version": "0.15.0",
3
+ "version": "0.15.1",
4
4
  "description": "a library for building a fake REST API for testing",
5
5
  "type": "module",
6
6
  "main": "./src/server/counterfact.js",
@@ -30,7 +30,7 @@
30
30
  "prepare": "husky install",
31
31
  "lint": "eslint . --plugin file-progress --rule 'file-progress/activate: 1'",
32
32
  "lint:quickfix": "eslint --fix . eslint --fix demo-ts --rule=\"import/namespace: 0,etc/no-deprecated:0,import/no-cycle:0,no-explicit-type-exports/no-explicit-type-exports:0,import/no-deprecated:0,import/no-self-import:0,import/default:0,import/no-named-as-default:0\"",
33
- "go:petstore": "yarn counterfact https://petstore3.swagger.io/api/v3/openapi.json out",
33
+ "go:petstore": "yarn counterfact https://petstore3.swagger.io/api/v3/openapi.json out",
34
34
  "go:petstore2": "yarn counterfact https://petstore.swagger.io/v2/swagger.json out",
35
35
  "go:example": "yarn counterfact ./openapi-example.yaml out --open",
36
36
  "counterfact": "./bin/counterfact.js"
@@ -41,7 +41,7 @@
41
41
  "@stryker-mutator/jest-runner": "6.3.0",
42
42
  "@types/koa": "2.13.5",
43
43
  "@types/koa-static": "^4.0.2",
44
- "eslint": "8.28.0",
44
+ "eslint": "8.29.0",
45
45
  "eslint-config-hardcore": "25.1.0",
46
46
  "eslint-formatter-github-annotations": "0.1.0",
47
47
  "eslint-import-resolver-typescript": "^3.2.5",
@@ -54,7 +54,7 @@
54
54
  "jest": "28.1.2",
55
55
  "nodemon": "2.0.20",
56
56
  "stryker-cli": "1.0.2",
57
- "supertest": "6.3.1"
57
+ "supertest": "6.3.2"
58
58
  },
59
59
  "dependencies": {
60
60
  "@hapi/accept": "^6.0.0",
@@ -62,7 +62,7 @@
62
62
  "chokidar": "^3.5.3",
63
63
  "commander": "^9.4.0",
64
64
  "fetch": "^1.1.0",
65
- "fs-extra": "^10.1.0",
65
+ "fs-extra": "^11.0.0",
66
66
  "handlebars": "^4.7.7",
67
67
  "js-yaml": "^4.1.0",
68
68
  "json-schema-faker": "^0.5.0-rcv.44",
@@ -1,7 +1,7 @@
1
1
  /* eslint-disable import/max-dependencies */
2
2
  import fs from "node:fs/promises";
3
3
  import nodePath from "node:path";
4
- import os from "node:os";
4
+ import { constants as fsConstants } from "node:fs";
5
5
 
6
6
  import $RefParser from "json-schema-ref-parser";
7
7
  import yaml from "js-yaml";
@@ -15,6 +15,14 @@ import { ModuleLoader } from "./module-loader.js";
15
15
  import { Transpiler } from "./transpiler.js";
16
16
  import { ContextRegistry } from "./context-registry.js";
17
17
 
18
+ async function ensureDirectoryExists(directory) {
19
+ try {
20
+ await fs.access(directory, fsConstants.W_OK);
21
+ } catch {
22
+ await fs.mkdir(directory, { recursive: true });
23
+ }
24
+ }
25
+
18
26
  async function loadOpenApiDocument(source) {
19
27
  try {
20
28
  return $RefParser.dereference(await yaml.load(await readFile(source)));
@@ -32,18 +40,23 @@ export async function counterfact(
32
40
 
33
41
  const registry = new Registry();
34
42
 
35
- const modulesPath = `${await fs.mkdtemp(
36
- nodePath.join(os.tmpdir(), "counterfact-")
37
- )}/`;
43
+ const modulesPath = `${nodePath.join(basePath, "js")}/`;
38
44
 
39
- try {
40
- await fs.writeFile(
41
- nodePath.join(modulesPath, "package.json"),
42
- '{"type": "module"}'
43
- );
44
- } catch {
45
- throw new Error("could not write package.json");
46
- }
45
+ await ensureDirectoryExists(modulesPath);
46
+
47
+ // try {
48
+ // await fs.writeFile(
49
+ // nodePath.join(modulesPath, "package.json"),
50
+ // '{"type": "module"}'
51
+ // );
52
+ // } catch {
53
+ // throw new Error(
54
+ // `could not write package.json to ${nodePath.join(
55
+ // modulesPath,
56
+ // "package.json"
57
+ // )}`
58
+ // );
59
+ // }
47
60
 
48
61
  const transpiler = new Transpiler(basePath, modulesPath);
49
62
 
@@ -26,7 +26,9 @@ export class Transpiler extends EventTarget {
26
26
  }
27
27
 
28
28
  async watch() {
29
- this.watcher = chokidar.watch(`${this.sourcePath}/**/*.{js,mjs,ts,mts}`);
29
+ this.watcher = chokidar.watch(`${this.sourcePath}/**/*.{ts,mts,js,mjs}`, {
30
+ ignored: `${this.sourcePath}/js`,
31
+ });
30
32
 
31
33
  const transpiles = [];
32
34
 
@@ -54,6 +56,7 @@ export class Transpiler extends EventTarget {
54
56
  }
55
57
  });
56
58
  await once(this.watcher, "ready");
59
+
57
60
  await Promise.all(transpiles);
58
61
  }
59
62
 
@@ -75,7 +78,7 @@ export class Transpiler extends EventTarget {
75
78
  nodePath.join(
76
79
  sourcePath
77
80
  .replace(this.sourcePath, this.destinationPath)
78
- .replace(".ts", ".js")
81
+ .replace(".ts", ".mjs")
79
82
  ),
80
83
  result
81
84
  );
@@ -43,7 +43,7 @@ class Context {
43
43
 
44
44
  script.repository.get(parentPath).exportDefault(this);
45
45
 
46
- return { raw: 'export { default } from "../$.context.js"' };
46
+ return { raw: 'export { default } from "../$.context.mjs"' };
47
47
  }
48
48
 
49
49
  modulePath() {
@@ -27,7 +27,7 @@ describe("a Transpiler", () => {
27
27
 
28
28
  await transpiler.watch();
29
29
 
30
- await expect(fs.readFile(path("dist/found.js"), "utf8")).resolves.toBe(
30
+ await expect(fs.readFile(path("dist/found.mjs"), "utf8")).resolves.toBe(
31
31
  JAVASCRIPT_SOURCE
32
32
  );
33
33
 
@@ -50,7 +50,7 @@ describe("a Transpiler", () => {
50
50
  await add("src/added.ts", TYPESCRIPT_SOURCE);
51
51
  await write;
52
52
 
53
- await expect(fs.readFile(path("dist/added.js"), "utf8")).resolves.toBe(
53
+ await expect(fs.readFile(path("dist/added.mjs"), "utf8")).resolves.toBe(
54
54
  JAVASCRIPT_SOURCE
55
55
  );
56
56
 
@@ -78,7 +78,7 @@ describe("a Transpiler", () => {
78
78
  await overwrite;
79
79
 
80
80
  await expect(
81
- fs.readFile(path("dist/update-me.js"), "utf8")
81
+ fs.readFile(path("dist/update-me.mjs"), "utf8")
82
82
  ).resolves.toBe(JAVASCRIPT_SOURCE);
83
83
 
84
84
  transpiler.stopWatching();
@@ -1061,7 +1061,7 @@ class Context {
1061
1061
  }
1062
1062
  ",
1063
1063
  "code": Object {
1064
- "raw": "export { default } from \\"../$.context.js\\"",
1064
+ "raw": "export { default } from \\"../$.context.mjs\\"",
1065
1065
  },
1066
1066
  "done": true,
1067
1067
  "id": "ContextCoder@petstore.yaml#/paths/~1pet~1findByStatus/get",
@@ -1276,7 +1276,7 @@ class Context {
1276
1276
  }
1277
1277
  ",
1278
1278
  "code": Object {
1279
- "raw": "export { default } from \\"../$.context.js\\"",
1279
+ "raw": "export { default } from \\"../$.context.mjs\\"",
1280
1280
  },
1281
1281
  "done": true,
1282
1282
  "id": "ContextCoder@petstore.yaml#/paths/~1pet~1findByStatus/get",
@@ -1508,7 +1508,7 @@ class Context {
1508
1508
  }
1509
1509
  ",
1510
1510
  "code": Object {
1511
- "raw": "export { default } from \\"../$.context.js\\"",
1511
+ "raw": "export { default } from \\"../$.context.mjs\\"",
1512
1512
  },
1513
1513
  "done": true,
1514
1514
  "id": "ContextCoder@petstore.yaml#/paths/~1pet~1findByStatus/get",
@@ -1723,7 +1723,7 @@ class Context {
1723
1723
  }
1724
1724
  ",
1725
1725
  "code": Object {
1726
- "raw": "export { default } from \\"../$.context.js\\"",
1726
+ "raw": "export { default } from \\"../$.context.mjs\\"",
1727
1727
  },
1728
1728
  "done": true,
1729
1729
  "id": "ContextCoder@petstore.yaml#/paths/~1pet~1findByStatus/get",
@@ -2027,7 +2027,7 @@ class Context {
2027
2027
  }
2028
2028
  ",
2029
2029
  "code": Object {
2030
- "raw": "export { default } from \\"../$.context.js\\"",
2030
+ "raw": "export { default } from \\"../$.context.mjs\\"",
2031
2031
  },
2032
2032
  "done": true,
2033
2033
  "id": "ContextCoder@petstore.yaml#/paths/~1pet~1findByStatus/get",
@@ -2169,7 +2169,7 @@ class Context {
2169
2169
  }
2170
2170
  ",
2171
2171
  "code": Object {
2172
- "raw": "export { default } from \\"../$.context.js\\"",
2172
+ "raw": "export { default } from \\"../$.context.mjs\\"",
2173
2173
  },
2174
2174
  "done": true,
2175
2175
  "id": "ContextCoder@petstore.yaml#/paths/~1pet~1findByStatus/get",
@@ -2215,7 +2215,7 @@ class Context {
2215
2215
  }
2216
2216
  ",
2217
2217
  "code": Object {
2218
- "raw": "export { default } from \\"../$.context.js\\"",
2218
+ "raw": "export { default } from \\"../$.context.mjs\\"",
2219
2219
  },
2220
2220
  "done": true,
2221
2221
  "id": "ContextCoder@petstore.yaml#/paths/~1pet~1findByStatus/get",
@@ -2376,7 +2376,7 @@ class Context {
2376
2376
  }
2377
2377
  ",
2378
2378
  "code": Object {
2379
- "raw": "export { default } from \\"../$.context.js\\"",
2379
+ "raw": "export { default } from \\"../$.context.mjs\\"",
2380
2380
  },
2381
2381
  "done": true,
2382
2382
  "id": "ContextCoder@petstore.yaml#/paths/~1pet~1findByStatus/get",
@@ -2518,7 +2518,7 @@ class Context {
2518
2518
  }
2519
2519
  ",
2520
2520
  "code": Object {
2521
- "raw": "export { default } from \\"../$.context.js\\"",
2521
+ "raw": "export { default } from \\"../$.context.mjs\\"",
2522
2522
  },
2523
2523
  "done": true,
2524
2524
  "id": "ContextCoder@petstore.yaml#/paths/~1pet~1findByStatus/get",
@@ -2564,7 +2564,7 @@ class Context {
2564
2564
  }
2565
2565
  ",
2566
2566
  "code": Object {
2567
- "raw": "export { default } from \\"../$.context.js\\"",
2567
+ "raw": "export { default } from \\"../$.context.mjs\\"",
2568
2568
  },
2569
2569
  "done": true,
2570
2570
  "id": "ContextCoder@petstore.yaml#/paths/~1pet~1findByStatus/get",
@@ -2725,7 +2725,7 @@ class Context {
2725
2725
  }
2726
2726
  ",
2727
2727
  "code": Object {
2728
- "raw": "export { default } from \\"../$.context.js\\"",
2728
+ "raw": "export { default } from \\"../$.context.mjs\\"",
2729
2729
  },
2730
2730
  "done": true,
2731
2731
  "id": "ContextCoder@petstore.yaml#/paths/~1pet~1findByStatus/get",
@@ -2867,7 +2867,7 @@ class Context {
2867
2867
  }
2868
2868
  ",
2869
2869
  "code": Object {
2870
- "raw": "export { default } from \\"../$.context.js\\"",
2870
+ "raw": "export { default } from \\"../$.context.mjs\\"",
2871
2871
  },
2872
2872
  "done": true,
2873
2873
  "id": "ContextCoder@petstore.yaml#/paths/~1pet~1findByStatus/get",
@@ -2913,7 +2913,7 @@ class Context {
2913
2913
  }
2914
2914
  ",
2915
2915
  "code": Object {
2916
- "raw": "export { default } from \\"../$.context.js\\"",
2916
+ "raw": "export { default } from \\"../$.context.mjs\\"",
2917
2917
  },
2918
2918
  "done": true,
2919
2919
  "id": "ContextCoder@petstore.yaml#/paths/~1pet~1findByStatus/get",
@@ -3078,7 +3078,7 @@ class Context {
3078
3078
  }
3079
3079
  ",
3080
3080
  "code": Object {
3081
- "raw": "export { default } from \\"../$.context.js\\"",
3081
+ "raw": "export { default } from \\"../$.context.mjs\\"",
3082
3082
  },
3083
3083
  "done": true,
3084
3084
  "id": "ContextCoder@petstore.yaml#/paths/~1pet~1findByStatus/get",
@@ -3220,7 +3220,7 @@ class Context {
3220
3220
  }
3221
3221
  ",
3222
3222
  "code": Object {
3223
- "raw": "export { default } from \\"../$.context.js\\"",
3223
+ "raw": "export { default } from \\"../$.context.mjs\\"",
3224
3224
  },
3225
3225
  "done": true,
3226
3226
  "id": "ContextCoder@petstore.yaml#/paths/~1pet~1findByStatus/get",
@@ -3266,7 +3266,7 @@ class Context {
3266
3266
  }
3267
3267
  ",
3268
3268
  "code": Object {
3269
- "raw": "export { default } from \\"../$.context.js\\"",
3269
+ "raw": "export { default } from \\"../$.context.mjs\\"",
3270
3270
  },
3271
3271
  "done": true,
3272
3272
  "id": "ContextCoder@petstore.yaml#/paths/~1pet~1findByStatus/get",
@@ -3389,7 +3389,7 @@ class Context {
3389
3389
  }
3390
3390
  ",
3391
3391
  "code": Object {
3392
- "raw": "export { default } from \\"../$.context.js\\"",
3392
+ "raw": "export { default } from \\"../$.context.mjs\\"",
3393
3393
  },
3394
3394
  "done": true,
3395
3395
  "id": "ContextCoder@petstore.yaml#/paths/~1pet~1{petId}~1uploadImage/post",
@@ -3526,7 +3526,7 @@ class Context {
3526
3526
  }
3527
3527
  ",
3528
3528
  "code": Object {
3529
- "raw": "export { default } from \\"../$.context.js\\"",
3529
+ "raw": "export { default } from \\"../$.context.mjs\\"",
3530
3530
  },
3531
3531
  "done": true,
3532
3532
  "id": "ContextCoder@petstore.yaml#/paths/~1pet~1{petId}~1uploadImage/post",
@@ -3679,7 +3679,7 @@ class Context {
3679
3679
  }
3680
3680
  ",
3681
3681
  "code": Object {
3682
- "raw": "export { default } from \\"../$.context.js\\"",
3682
+ "raw": "export { default } from \\"../$.context.mjs\\"",
3683
3683
  },
3684
3684
  "done": true,
3685
3685
  "id": "ContextCoder@petstore.yaml#/paths/~1store~1inventory/get",
@@ -3784,7 +3784,7 @@ class Context {
3784
3784
  }
3785
3785
  ",
3786
3786
  "code": Object {
3787
- "raw": "export { default } from \\"../$.context.js\\"",
3787
+ "raw": "export { default } from \\"../$.context.mjs\\"",
3788
3788
  },
3789
3789
  "done": true,
3790
3790
  "id": "ContextCoder@petstore.yaml#/paths/~1store~1inventory/get",
@@ -3913,7 +3913,7 @@ class Context {
3913
3913
  }
3914
3914
  ",
3915
3915
  "code": Object {
3916
- "raw": "export { default } from \\"../$.context.js\\"",
3916
+ "raw": "export { default } from \\"../$.context.mjs\\"",
3917
3917
  },
3918
3918
  "done": true,
3919
3919
  "id": "ContextCoder@petstore.yaml#/paths/~1store~1inventory/get",
@@ -4056,7 +4056,7 @@ class Context {
4056
4056
  }
4057
4057
  ",
4058
4058
  "code": Object {
4059
- "raw": "export { default } from \\"../$.context.js\\"",
4059
+ "raw": "export { default } from \\"../$.context.mjs\\"",
4060
4060
  },
4061
4061
  "done": true,
4062
4062
  "id": "ContextCoder@petstore.yaml#/paths/~1store~1inventory/get",
@@ -4268,7 +4268,7 @@ class Context {
4268
4268
  }
4269
4269
  ",
4270
4270
  "code": Object {
4271
- "raw": "export { default } from \\"../$.context.js\\"",
4271
+ "raw": "export { default } from \\"../$.context.mjs\\"",
4272
4272
  },
4273
4273
  "done": true,
4274
4274
  "id": "ContextCoder@petstore.yaml#/paths/~1store~1order~1{orderId}/get",
@@ -4345,7 +4345,7 @@ class Context {
4345
4345
  }
4346
4346
  ",
4347
4347
  "code": Object {
4348
- "raw": "export { default } from \\"../$.context.js\\"",
4348
+ "raw": "export { default } from \\"../$.context.mjs\\"",
4349
4349
  },
4350
4350
  "done": true,
4351
4351
  "id": "ContextCoder@petstore.yaml#/paths/~1store~1order~1{orderId}/get",
@@ -4492,7 +4492,7 @@ class Context {
4492
4492
  }
4493
4493
  ",
4494
4494
  "code": Object {
4495
- "raw": "export { default } from \\"../$.context.js\\"",
4495
+ "raw": "export { default } from \\"../$.context.mjs\\"",
4496
4496
  },
4497
4497
  "done": true,
4498
4498
  "id": "ContextCoder@petstore.yaml#/paths/~1store~1order~1{orderId}/get",
@@ -4569,7 +4569,7 @@ class Context {
4569
4569
  }
4570
4570
  ",
4571
4571
  "code": Object {
4572
- "raw": "export { default } from \\"../$.context.js\\"",
4572
+ "raw": "export { default } from \\"../$.context.mjs\\"",
4573
4573
  },
4574
4574
  "done": true,
4575
4575
  "id": "ContextCoder@petstore.yaml#/paths/~1store~1order~1{orderId}/get",
@@ -4720,7 +4720,7 @@ class Context {
4720
4720
  }
4721
4721
  ",
4722
4722
  "code": Object {
4723
- "raw": "export { default } from \\"../$.context.js\\"",
4723
+ "raw": "export { default } from \\"../$.context.mjs\\"",
4724
4724
  },
4725
4725
  "done": true,
4726
4726
  "id": "ContextCoder@petstore.yaml#/paths/~1store~1order~1{orderId}/get",
@@ -4797,7 +4797,7 @@ class Context {
4797
4797
  }
4798
4798
  ",
4799
4799
  "code": Object {
4800
- "raw": "export { default } from \\"../$.context.js\\"",
4800
+ "raw": "export { default } from \\"../$.context.mjs\\"",
4801
4801
  },
4802
4802
  "done": true,
4803
4803
  "id": "ContextCoder@petstore.yaml#/paths/~1store~1order~1{orderId}/get",
@@ -5234,7 +5234,7 @@ class Context {
5234
5234
  }
5235
5235
  ",
5236
5236
  "code": Object {
5237
- "raw": "export { default } from \\"../$.context.js\\"",
5237
+ "raw": "export { default } from \\"../$.context.mjs\\"",
5238
5238
  },
5239
5239
  "done": true,
5240
5240
  "id": "ContextCoder@petstore.yaml#/paths/~1user~1createWithList/post",
@@ -5384,7 +5384,7 @@ class Context {
5384
5384
  }
5385
5385
  ",
5386
5386
  "code": Object {
5387
- "raw": "export { default } from \\"../$.context.js\\"",
5387
+ "raw": "export { default } from \\"../$.context.mjs\\"",
5388
5388
  },
5389
5389
  "done": true,
5390
5390
  "id": "ContextCoder@petstore.yaml#/paths/~1user~1createWithList/post",
@@ -5553,7 +5553,7 @@ class Context {
5553
5553
  }
5554
5554
  ",
5555
5555
  "code": Object {
5556
- "raw": "export { default } from \\"../$.context.js\\"",
5556
+ "raw": "export { default } from \\"../$.context.mjs\\"",
5557
5557
  },
5558
5558
  "done": true,
5559
5559
  "id": "ContextCoder@petstore.yaml#/paths/~1user~1createWithList/post",
@@ -5674,7 +5674,7 @@ class Context {
5674
5674
  }
5675
5675
  ",
5676
5676
  "code": Object {
5677
- "raw": "export { default } from \\"../$.context.js\\"",
5677
+ "raw": "export { default } from \\"../$.context.mjs\\"",
5678
5678
  },
5679
5679
  "done": true,
5680
5680
  "id": "ContextCoder@petstore.yaml#/paths/~1user~1createWithList/post",
@@ -5788,7 +5788,7 @@ class Context {
5788
5788
  }
5789
5789
  ",
5790
5790
  "code": Object {
5791
- "raw": "export { default } from \\"../$.context.js\\"",
5791
+ "raw": "export { default } from \\"../$.context.mjs\\"",
5792
5792
  },
5793
5793
  "done": true,
5794
5794
  "id": "ContextCoder@petstore.yaml#/paths/~1user~1createWithList/post",
@@ -5887,7 +5887,7 @@ class Context {
5887
5887
  }
5888
5888
  ",
5889
5889
  "code": Object {
5890
- "raw": "export { default } from \\"../$.context.js\\"",
5890
+ "raw": "export { default } from \\"../$.context.mjs\\"",
5891
5891
  },
5892
5892
  "done": true,
5893
5893
  "id": "ContextCoder@petstore.yaml#/paths/~1user~1createWithList/post",
@@ -6101,7 +6101,7 @@ class Context {
6101
6101
  }
6102
6102
  ",
6103
6103
  "code": Object {
6104
- "raw": "export { default } from \\"../$.context.js\\"",
6104
+ "raw": "export { default } from \\"../$.context.mjs\\"",
6105
6105
  },
6106
6106
  "done": true,
6107
6107
  "id": "ContextCoder@petstore.yaml#/paths/~1user~1createWithList/post",
@@ -6178,7 +6178,7 @@ class Context {
6178
6178
  }
6179
6179
  ",
6180
6180
  "code": Object {
6181
- "raw": "export { default } from \\"../$.context.js\\"",
6181
+ "raw": "export { default } from \\"../$.context.mjs\\"",
6182
6182
  },
6183
6183
  "done": true,
6184
6184
  "id": "ContextCoder@petstore.yaml#/paths/~1user~1createWithList/post",
@@ -6224,7 +6224,7 @@ class Context {
6224
6224
  }
6225
6225
  ",
6226
6226
  "code": Object {
6227
- "raw": "export { default } from \\"../$.context.js\\"",
6227
+ "raw": "export { default } from \\"../$.context.mjs\\"",
6228
6228
  },
6229
6229
  "done": true,
6230
6230
  "id": "ContextCoder@petstore.yaml#/paths/~1user~1createWithList/post",
@@ -6391,7 +6391,7 @@ class Context {
6391
6391
  }
6392
6392
  ",
6393
6393
  "code": Object {
6394
- "raw": "export { default } from \\"../$.context.js\\"",
6394
+ "raw": "export { default } from \\"../$.context.mjs\\"",
6395
6395
  },
6396
6396
  "done": true,
6397
6397
  "id": "ContextCoder@petstore.yaml#/paths/~1user~1createWithList/post",
@@ -6468,7 +6468,7 @@ class Context {
6468
6468
  }
6469
6469
  ",
6470
6470
  "code": Object {
6471
- "raw": "export { default } from \\"../$.context.js\\"",
6471
+ "raw": "export { default } from \\"../$.context.mjs\\"",
6472
6472
  },
6473
6473
  "done": true,
6474
6474
  "id": "ContextCoder@petstore.yaml#/paths/~1user~1createWithList/post",
@@ -6514,7 +6514,7 @@ class Context {
6514
6514
  }
6515
6515
  ",
6516
6516
  "code": Object {
6517
- "raw": "export { default } from \\"../$.context.js\\"",
6517
+ "raw": "export { default } from \\"../$.context.mjs\\"",
6518
6518
  },
6519
6519
  "done": true,
6520
6520
  "id": "ContextCoder@petstore.yaml#/paths/~1user~1createWithList/post",
@@ -6681,7 +6681,7 @@ class Context {
6681
6681
  }
6682
6682
  ",
6683
6683
  "code": Object {
6684
- "raw": "export { default } from \\"../$.context.js\\"",
6684
+ "raw": "export { default } from \\"../$.context.mjs\\"",
6685
6685
  },
6686
6686
  "done": true,
6687
6687
  "id": "ContextCoder@petstore.yaml#/paths/~1user~1createWithList/post",
@@ -6758,7 +6758,7 @@ class Context {
6758
6758
  }
6759
6759
  ",
6760
6760
  "code": Object {
6761
- "raw": "export { default } from \\"../$.context.js\\"",
6761
+ "raw": "export { default } from \\"../$.context.mjs\\"",
6762
6762
  },
6763
6763
  "done": true,
6764
6764
  "id": "ContextCoder@petstore.yaml#/paths/~1user~1createWithList/post",
@@ -6804,7 +6804,7 @@ class Context {
6804
6804
  }
6805
6805
  ",
6806
6806
  "code": Object {
6807
- "raw": "export { default } from \\"../$.context.js\\"",
6807
+ "raw": "export { default } from \\"../$.context.mjs\\"",
6808
6808
  },
6809
6809
  "done": true,
6810
6810
  "id": "ContextCoder@petstore.yaml#/paths/~1user~1createWithList/post",
@@ -6975,7 +6975,7 @@ class Context {
6975
6975
  }
6976
6976
  ",
6977
6977
  "code": Object {
6978
- "raw": "export { default } from \\"../$.context.js\\"",
6978
+ "raw": "export { default } from \\"../$.context.mjs\\"",
6979
6979
  },
6980
6980
  "done": true,
6981
6981
  "id": "ContextCoder@petstore.yaml#/paths/~1user~1createWithList/post",
@@ -7052,7 +7052,7 @@ class Context {
7052
7052
  }
7053
7053
  ",
7054
7054
  "code": Object {
7055
- "raw": "export { default } from \\"../$.context.js\\"",
7055
+ "raw": "export { default } from \\"../$.context.mjs\\"",
7056
7056
  },
7057
7057
  "done": true,
7058
7058
  "id": "ContextCoder@petstore.yaml#/paths/~1user~1createWithList/post",
@@ -7098,7 +7098,7 @@ class Context {
7098
7098
  }
7099
7099
  ",
7100
7100
  "code": Object {
7101
- "raw": "export { default } from \\"../$.context.js\\"",
7101
+ "raw": "export { default } from \\"../$.context.mjs\\"",
7102
7102
  },
7103
7103
  "done": true,
7104
7104
  "id": "ContextCoder@petstore.yaml#/paths/~1user~1createWithList/post",
@@ -7278,7 +7278,7 @@ class Context {
7278
7278
  }
7279
7279
  ",
7280
7280
  "code": Object {
7281
- "raw": "export { default } from \\"../$.context.js\\"",
7281
+ "raw": "export { default } from \\"../$.context.mjs\\"",
7282
7282
  },
7283
7283
  "done": true,
7284
7284
  "id": "ContextCoder@petstore.yaml#/paths/~1pet~1findByStatus/get",
@@ -7319,7 +7319,7 @@ class Context {
7319
7319
  }
7320
7320
  ",
7321
7321
  "code": Object {
7322
- "raw": "export { default } from \\"../$.context.js\\"",
7322
+ "raw": "export { default } from \\"../$.context.mjs\\"",
7323
7323
  },
7324
7324
  "done": true,
7325
7325
  "id": "ContextCoder@petstore.yaml#/paths/~1pet~1{petId}~1uploadImage/post",
@@ -7386,7 +7386,7 @@ class Context {
7386
7386
  }
7387
7387
  ",
7388
7388
  "code": Object {
7389
- "raw": "export { default } from \\"../$.context.js\\"",
7389
+ "raw": "export { default } from \\"../$.context.mjs\\"",
7390
7390
  },
7391
7391
  "done": true,
7392
7392
  "id": "ContextCoder@petstore.yaml#/paths/~1store~1inventory/get",
@@ -7453,7 +7453,7 @@ class Context {
7453
7453
  }
7454
7454
  ",
7455
7455
  "code": Object {
7456
- "raw": "export { default } from \\"../$.context.js\\"",
7456
+ "raw": "export { default } from \\"../$.context.mjs\\"",
7457
7457
  },
7458
7458
  "done": true,
7459
7459
  "id": "ContextCoder@petstore.yaml#/paths/~1store~1order~1{orderId}/get",
@@ -7520,7 +7520,7 @@ class Context {
7520
7520
  }
7521
7521
  ",
7522
7522
  "code": Object {
7523
- "raw": "export { default } from \\"../$.context.js\\"",
7523
+ "raw": "export { default } from \\"../$.context.mjs\\"",
7524
7524
  },
7525
7525
  "done": true,
7526
7526
  "id": "ContextCoder@petstore.yaml#/paths/~1user~1createWithList/post",