@autobe/compiler 0.10.6 → 0.11.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 (64) hide show
  1. package/lib/AutoBeCompiler.d.ts +4 -1
  2. package/lib/AutoBeCompiler.js +7 -4
  3. package/lib/AutoBeCompiler.js.map +1 -1
  4. package/lib/AutoBeTypeScriptCompiler.js +6 -1
  5. package/lib/AutoBeTypeScriptCompiler.js.map +1 -1
  6. package/lib/index.d.ts +3 -3
  7. package/lib/index.js +3 -3
  8. package/lib/index.js.map +1 -1
  9. package/lib/{AutoBeInterfaceCompiler.d.ts → interface/AutoBeInterfaceCompiler.d.ts} +2 -1
  10. package/lib/{AutoBeInterfaceCompiler.js → interface/AutoBeInterfaceCompiler.js} +11 -6
  11. package/lib/interface/AutoBeInterfaceCompiler.js.map +1 -0
  12. package/lib/prisma/AutoBePrismaCompiler.d.ts +6 -0
  13. package/lib/{AutoBePrismaCompiler.js → prisma/AutoBePrismaCompiler.js} +2 -27
  14. package/lib/prisma/AutoBePrismaCompiler.js.map +1 -0
  15. package/lib/prisma/writePrismaApplication.js +7 -4
  16. package/lib/prisma/writePrismaApplication.js.map +1 -1
  17. package/lib/raw/AutoBeCompilerInterfaceTemplate.d.ts +1 -0
  18. package/lib/raw/AutoBeCompilerInterfaceTemplate.js +8 -0
  19. package/lib/raw/AutoBeCompilerInterfaceTemplate.js.map +1 -0
  20. package/lib/raw/AutoBeCompilerRealizeTemplate.d.ts +1 -0
  21. package/lib/raw/AutoBeCompilerRealizeTemplate.js +17 -0
  22. package/lib/raw/AutoBeCompilerRealizeTemplate.js.map +1 -0
  23. package/lib/raw/AutoBeCompilerTestTemplate.d.ts +1 -0
  24. package/lib/raw/AutoBeCompilerTestTemplate.js +12 -0
  25. package/lib/raw/AutoBeCompilerTestTemplate.js.map +1 -0
  26. package/lib/raw/nestjs.json +10 -8
  27. package/lib/raw/test.json +2 -2
  28. package/lib/realize/AutoBeRealizeCompiler.d.ts +7 -0
  29. package/lib/realize/AutoBeRealizeCompiler.js +31 -0
  30. package/lib/realize/AutoBeRealizeCompiler.js.map +1 -0
  31. package/lib/realize/testRealizeProject.d.ts +2 -0
  32. package/lib/realize/testRealizeProject.js +80 -0
  33. package/lib/realize/testRealizeProject.js.map +1 -0
  34. package/lib/{AutoBeTestCompiler.d.ts → test/AutoBeTestCompiler.d.ts} +1 -0
  35. package/lib/{AutoBeTestCompiler.js → test/AutoBeTestCompiler.js} +16 -4
  36. package/lib/test/AutoBeTestCompiler.js.map +1 -0
  37. package/lib/utils/ProcessUtil.d.ts +4 -0
  38. package/lib/utils/ProcessUtil.js +30 -0
  39. package/lib/utils/ProcessUtil.js.map +1 -0
  40. package/package.json +8 -6
  41. package/src/AutoBeCompiler.ts +12 -3
  42. package/src/AutoBeTypeScriptCompiler.ts +7 -2
  43. package/src/index.ts +3 -3
  44. package/src/{AutoBeInterfaceCompiler.ts → interface/AutoBeInterfaceCompiler.ts} +10 -8
  45. package/src/prisma/AutoBePrismaCompiler.ts +36 -0
  46. package/src/prisma/writePrismaApplication.ts +10 -6
  47. package/src/raw/AutoBeCompilerInterfaceTemplate.ts +4 -0
  48. package/src/raw/AutoBeCompilerRealizeTemplate.ts +13 -0
  49. package/src/raw/AutoBeCompilerTestTemplate.ts +8 -0
  50. package/src/raw/nestjs.json +10 -8
  51. package/src/raw/test.json +2 -2
  52. package/src/realize/AutoBeRealizeCompiler.ts +40 -0
  53. package/src/realize/testRealizeProject.ts +78 -0
  54. package/src/{AutoBeTestCompiler.ts → test/AutoBeTestCompiler.ts} +19 -5
  55. package/src/utils/ProcessUtil.ts +14 -0
  56. package/lib/AutoBeInterfaceCompiler.js.map +0 -1
  57. package/lib/AutoBePrismaCompiler.d.ts +0 -31
  58. package/lib/AutoBePrismaCompiler.js.map +0 -1
  59. package/lib/AutoBeTestCompiler.js.map +0 -1
  60. package/lib/raw/AutoBeCompilerTemplate.d.ts +0 -1
  61. package/lib/raw/AutoBeCompilerTemplate.js +0 -12
  62. package/lib/raw/AutoBeCompilerTemplate.js.map +0 -1
  63. package/src/AutoBePrismaCompiler.ts +0 -61
  64. package/src/raw/AutoBeCompilerTemplate.ts +0 -8
@@ -1,4 +1,4 @@
1
- import { IAutoBeCompiler, IAutoBeInterfaceCompiler, IAutoBePrismaCompiler, IAutoBeTestCompiler, IAutoBeTypeScriptCompiler } from "@autobe/interface";
1
+ import { IAutoBeCompiler, IAutoBeCompilerListener, IAutoBeInterfaceCompiler, IAutoBePrismaCompiler, IAutoBeRealizeCompiler, IAutoBeTestCompiler, IAutoBeTypeScriptCompiler } from "@autobe/interface";
2
2
  /**
3
3
  * Comprehensive compilation infrastructure for the vibe coding pipeline.
4
4
  *
@@ -22,8 +22,11 @@ import { IAutoBeCompiler, IAutoBeInterfaceCompiler, IAutoBePrismaCompiler, IAuto
22
22
  * @author Samchon
23
23
  */
24
24
  export declare class AutoBeCompiler implements IAutoBeCompiler {
25
+ private readonly listener;
26
+ constructor(listener: IAutoBeCompilerListener);
25
27
  readonly prisma: IAutoBePrismaCompiler;
26
28
  readonly interface: IAutoBeInterfaceCompiler;
27
29
  readonly typescript: IAutoBeTypeScriptCompiler;
28
30
  readonly test: IAutoBeTestCompiler;
31
+ readonly realize: IAutoBeRealizeCompiler;
29
32
  }
@@ -1,10 +1,11 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.AutoBeCompiler = void 0;
4
- const AutoBeInterfaceCompiler_1 = require("./AutoBeInterfaceCompiler");
5
- const AutoBePrismaCompiler_1 = require("./AutoBePrismaCompiler");
6
- const AutoBeTestCompiler_1 = require("./AutoBeTestCompiler");
7
4
  const AutoBeTypeScriptCompiler_1 = require("./AutoBeTypeScriptCompiler");
5
+ const AutoBeInterfaceCompiler_1 = require("./interface/AutoBeInterfaceCompiler");
6
+ const AutoBePrismaCompiler_1 = require("./prisma/AutoBePrismaCompiler");
7
+ const AutoBeRealizeCompiler_1 = require("./realize/AutoBeRealizeCompiler");
8
+ const AutoBeTestCompiler_1 = require("./test/AutoBeTestCompiler");
8
9
  /**
9
10
  * Comprehensive compilation infrastructure for the vibe coding pipeline.
10
11
  *
@@ -28,11 +29,13 @@ const AutoBeTypeScriptCompiler_1 = require("./AutoBeTypeScriptCompiler");
28
29
  * @author Samchon
29
30
  */
30
31
  class AutoBeCompiler {
31
- constructor() {
32
+ constructor(listener) {
33
+ this.listener = listener;
32
34
  this.prisma = new AutoBePrismaCompiler_1.AutoBePrismaCompiler();
33
35
  this.interface = new AutoBeInterfaceCompiler_1.AutoBeInterfaceCompiler();
34
36
  this.typescript = new AutoBeTypeScriptCompiler_1.AutoBeTypeScriptCompiler();
35
37
  this.test = new AutoBeTestCompiler_1.AutoBeTestCompiler();
38
+ this.realize = new AutoBeRealizeCompiler_1.AutoBeRealizeCompiler(this.listener.realize);
36
39
  }
37
40
  }
38
41
  exports.AutoBeCompiler = AutoBeCompiler;
@@ -1 +1 @@
1
- {"version":3,"file":"AutoBeCompiler.js","sourceRoot":"","sources":["../src/AutoBeCompiler.ts"],"names":[],"mappings":";;;AAQA,uEAAoE;AACpE,iEAA8D;AAC9D,6DAA0D;AAC1D,yEAAsE;AAEtE;;;;;;;;;;;;;;;;;;;;;GAqBG;AACH,MAAa,cAAc;IAA3B;QACkB,WAAM,GAA0B,IAAI,2CAAoB,EAAE,CAAC;QAE3D,cAAS,GACvB,IAAI,iDAAuB,EAAE,CAAC;QAEhB,eAAU,GACxB,IAAI,mDAAwB,EAAE,CAAC;QAEjB,SAAI,GAAwB,IAAI,uCAAkB,EAAE,CAAC;IACvE,CAAC;CAAA;AAVD,wCAUC"}
1
+ {"version":3,"file":"AutoBeCompiler.js","sourceRoot":"","sources":["../src/AutoBeCompiler.ts"],"names":[],"mappings":";;;AAUA,yEAAsE;AACtE,iFAA8E;AAC9E,wEAAqE;AACrE,2EAAwE;AACxE,kEAA+D;AAE/D;;;;;;;;;;;;;;;;;;;;;GAqBG;AACH,MAAa,cAAc;IACzB,YAAoC,QAAiC;QAAjC,aAAQ,GAAR,QAAQ,CAAyB;QAErD,WAAM,GAA0B,IAAI,2CAAoB,EAAE,CAAC;QAE3D,cAAS,GACvB,IAAI,iDAAuB,EAAE,CAAC;QAEhB,eAAU,GACxB,IAAI,mDAAwB,EAAE,CAAC;QAEjB,SAAI,GAAwB,IAAI,uCAAkB,EAAE,CAAC;QAErD,YAAO,GAA2B,IAAI,6CAAqB,CACzE,IAAI,CAAC,QAAQ,CAAC,OAAO,CACtB,CAAC;IAdsE,CAAC;CAe1E;AAhBD,wCAgBC"}
@@ -77,7 +77,12 @@ class AutoBeTypeScriptCompiler {
77
77
  ],
78
78
  }),
79
79
  });
80
- return compiler.compile(Object.assign(Object.assign({}, props.files), ((_b = props.prisma) !== null && _b !== void 0 ? _b : {})));
80
+ const result = yield compiler.compile(Object.assign(Object.assign({}, props.files), ((_b = props.prisma) !== null && _b !== void 0 ? _b : {})));
81
+ return result.type === "success"
82
+ ? { type: "success" }
83
+ : result.type === "failure"
84
+ ? { type: "failure", diagnostics: result.diagnostics }
85
+ : { type: "exception", error: result.error };
81
86
  });
82
87
  }
83
88
  getExternal(location) {
@@ -1 +1 @@
1
- {"version":3,"file":"AutoBeTypeScriptCompiler.js","sourceRoot":"","sources":["../src/AutoBeTypeScriptCompiler.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;AAKA,2EAA6D;AAC7D,uDAAmD;AACnD,4DAA4B;AAC5B,oEAAiD;AAEjD,oEAA+C;AAC/C,qDAAkD;AAElD;;;;;;;;;;;;;;;;;;;;;;;;GAwBG;AACH,MAAa,wBAAwB;IACtB,OAAO,CAClB,KAAoC;;;YAEpC,MAAM,KAAK,GAAW,MAAA,KAAK,CAAC,OAAO,mCAAI,2BAA2B,CAAC;YACnE,MAAM,QAAQ,GAAoB,IAAI,kCAAe,CAAC;gBACpD,QAAQ,EAAE,qBAAwC;gBAClD,eAAe,EAAE;oBACf,MAAM,EAAE,oBAAE,CAAC,YAA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CAAC;YACH,MAAM,MAAM,GAA2B,MAAM,QAAQ,CAAC,OAAO,iCACxD,KAAK,CAAC,KAAK,GACX,CAAC,MAAA,KAAK,CAAC,MAAM,mCAAI,EAAE,CAAC,EACvB,CAAC;YACH,OAAO,MAAM,CAAC,IAAI,KAAK,SAAS;gBAC9B,CAAC,CAAC,EAAE,IAAI,EAAE,SAAS,EAAE;gBACrB,CAAC,CAAC,MAAM,CAAC,IAAI,KAAK,SAAS;oBACzB,CAAC,CAAC,EAAE,IAAI,EAAE,SAAS,EAAE,WAAW,EAAE,MAAM,CAAC,WAAW,EAAE;oBACtD,CAAC,CAAC,EAAE,IAAI,EAAE,WAAW,EAAE,KAAK,EAAE,MAAM,CAAC,KAAK,EAAE,CAAC;QACnD,CAAC;KAAA;IAEY,WAAW,CAAC,QAAgB;;;YACvC,OAAO,MAAC,qBAAyC,CAAC,QAAQ,CAAC,mCAAI,SAAS,CAAC;QAC3E,CAAC;KAAA;IAEM,QAAQ,CAAC,MAAc;QAC5B,OAAO,yBAAW,CAAC,QAAQ,CAAC,MAAM,CAAC,CAAC;IACtC,CAAC;CACF;AA3DD,4DA2DC"}
package/lib/index.d.ts CHANGED
@@ -1,5 +1,5 @@
1
1
  export * from "./AutoBeCompiler";
2
- export * from "./AutoBePrismaCompiler";
3
- export * from "./AutoBeInterfaceCompiler";
4
- export * from "./AutoBeTestCompiler";
2
+ export * from "./prisma/AutoBePrismaCompiler";
3
+ export * from "./interface/AutoBeInterfaceCompiler";
4
+ export * from "./test/AutoBeTestCompiler";
5
5
  export * from "./AutoBeTypeScriptCompiler";
package/lib/index.js CHANGED
@@ -15,8 +15,8 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
15
15
  };
16
16
  Object.defineProperty(exports, "__esModule", { value: true });
17
17
  __exportStar(require("./AutoBeCompiler"), exports);
18
- __exportStar(require("./AutoBePrismaCompiler"), exports);
19
- __exportStar(require("./AutoBeInterfaceCompiler"), exports);
20
- __exportStar(require("./AutoBeTestCompiler"), exports);
18
+ __exportStar(require("./prisma/AutoBePrismaCompiler"), exports);
19
+ __exportStar(require("./interface/AutoBeInterfaceCompiler"), exports);
20
+ __exportStar(require("./test/AutoBeTestCompiler"), exports);
21
21
  __exportStar(require("./AutoBeTypeScriptCompiler"), exports);
22
22
  //# sourceMappingURL=index.js.map
package/lib/index.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,mDAAiC;AACjC,yDAAuC;AACvC,4DAA0C;AAC1C,uDAAqC;AACrC,6DAA2C"}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,mDAAiC;AACjC,gEAA8C;AAC9C,sEAAoD;AACpD,4DAA0C;AAC1C,6DAA2C"}
@@ -24,7 +24,8 @@ import { OpenApi } from "@samchon/openapi";
24
24
  * @author Samchon
25
25
  */
26
26
  export declare class AutoBeInterfaceCompiler implements IAutoBeInterfaceCompiler {
27
- compile(document: AutoBeOpenApi.IDocument): Promise<Record<string, string>>;
27
+ write(document: AutoBeOpenApi.IDocument): Promise<Record<string, string>>;
28
28
  transform(document: AutoBeOpenApi.IDocument): Promise<OpenApi.IDocument>;
29
29
  invert(document: OpenApi.IDocument): Promise<AutoBeOpenApi.IDocument>;
30
+ getTemplate(): Promise<Record<string, string>>;
30
31
  }
@@ -12,10 +12,10 @@ Object.defineProperty(exports, "__esModule", { value: true });
12
12
  exports.AutoBeInterfaceCompiler = void 0;
13
13
  const utils_1 = require("@autobe/utils");
14
14
  const migrate_1 = require("@nestia/migrate");
15
- const transformOpenApi_1 = require("./interface/transformOpenApi");
16
- const AutoBeCompilerTemplate_1 = require("./raw/AutoBeCompilerTemplate");
17
- const ArrayUtil_1 = require("./utils/ArrayUtil");
18
- const FilePrinter_1 = require("./utils/FilePrinter");
15
+ const AutoBeCompilerInterfaceTemplate_1 = require("../raw/AutoBeCompilerInterfaceTemplate");
16
+ const ArrayUtil_1 = require("../utils/ArrayUtil");
17
+ const FilePrinter_1 = require("../utils/FilePrinter");
18
+ const transformOpenApi_1 = require("./transformOpenApi");
19
19
  /**
20
20
  * Custom Interface compiler that handles API specification and NestJS
21
21
  * application generation.
@@ -40,7 +40,7 @@ const FilePrinter_1 = require("./utils/FilePrinter");
40
40
  * @author Samchon
41
41
  */
42
42
  class AutoBeInterfaceCompiler {
43
- compile(document) {
43
+ write(document) {
44
44
  return __awaiter(this, void 0, void 0, function* () {
45
45
  const swagger = (0, transformOpenApi_1.transformOpenApiDocument)(document);
46
46
  const migrate = new migrate_1.NestiaMigrateApplication(swagger);
@@ -63,7 +63,7 @@ class AutoBeInterfaceCompiler {
63
63
  ];
64
64
  }))),
65
65
  ["packages/api/swagger.json", JSON.stringify(swagger, null, 2)],
66
- ...Object.entries(AutoBeCompilerTemplate_1.AutoBeCompilerTemplate).filter(([key]) => key !== "src/MyGlobal.ts"),
66
+ ...Object.entries(AutoBeCompilerInterfaceTemplate_1.AutoBeCompilerInterfaceTemplate),
67
67
  ]);
68
68
  });
69
69
  }
@@ -77,6 +77,11 @@ class AutoBeInterfaceCompiler {
77
77
  return (0, utils_1.invertOpenApiDocument)(document);
78
78
  });
79
79
  }
80
+ getTemplate() {
81
+ return __awaiter(this, void 0, void 0, function* () {
82
+ return AutoBeCompilerInterfaceTemplate_1.AutoBeCompilerInterfaceTemplate;
83
+ });
84
+ }
80
85
  }
81
86
  exports.AutoBeInterfaceCompiler = AutoBeInterfaceCompiler;
82
87
  //# sourceMappingURL=AutoBeInterfaceCompiler.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"AutoBeInterfaceCompiler.js","sourceRoot":"","sources":["../../src/interface/AutoBeInterfaceCompiler.ts"],"names":[],"mappings":";;;;;;;;;;;;AACA,yCAAsD;AACtD,6CAA2D;AAG3D,4FAAyF;AACzF,kDAA+C;AAC/C,sDAAmD;AACnD,yDAA8D;AAE9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Y,WAAW;;YACtB,OAAO,iEAA+B,CAAC;QACzC,CAAC;KAAA;CACF;AA/CD,0DA+CC"}
@@ -0,0 +1,6 @@
1
+ import { AutoBePrisma, IAutoBePrismaCompileResult, IAutoBePrismaCompiler, IAutoBePrismaCompilerProps, IAutoBePrismaValidation } from "@autobe/interface";
2
+ export declare class AutoBePrismaCompiler implements IAutoBePrismaCompiler {
3
+ compile(props: IAutoBePrismaCompilerProps): Promise<IAutoBePrismaCompileResult>;
4
+ validate(application: AutoBePrisma.IApplication): Promise<IAutoBePrismaValidation>;
5
+ write(application: AutoBePrisma.IApplication, dbms?: "postgres" | "sqlite"): Promise<Record<string, string>>;
6
+ }
@@ -11,33 +11,8 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
11
11
  Object.defineProperty(exports, "__esModule", { value: true });
12
12
  exports.AutoBePrismaCompiler = void 0;
13
13
  const embed_prisma_1 = require("embed-prisma");
14
- const validatePrismaApplication_1 = require("./prisma/validatePrismaApplication");
15
- const writePrismaApplication_1 = require("./prisma/writePrismaApplication");
16
- /**
17
- * Custom Prisma compiler that handles database schema validation and
18
- * generation.
19
- *
20
- * This compiler provides the foundational compilation layer that transforms
21
- * business requirements into validated database architectures through
22
- * sophisticated AST manipulation. The AutoBePrismaCompiler operates exclusively
23
- * on {@link AutoBePrisma.IApplication} structures, eliminating error-prone
24
- * text-based schema authoring while ensuring perfect consistency between
25
- * business logic and data storage design.
26
- *
27
- * The implementation leverages EmbedPrisma for robust schema compilation,
28
- * custom validation logic for comprehensive AST analysis, and specialized
29
- * writing utilities for deterministic code generation. The compiler ensures
30
- * 100% syntactic correctness and semantic integrity through multi-layered
31
- * validation including relationship graph analysis, business logic validation,
32
- * and performance optimization.
33
- *
34
- * The compilation process produces comprehensive documentation, optimal
35
- * indexes, proper constraints, and ERD diagrams ready for production deployment
36
- * while maintaining perfect alignment with business requirements throughout the
37
- * automated development pipeline.
38
- *
39
- * @author Samchon
40
- */
14
+ const validatePrismaApplication_1 = require("./validatePrismaApplication");
15
+ const writePrismaApplication_1 = require("./writePrismaApplication");
41
16
  class AutoBePrismaCompiler {
42
17
  compile(props) {
43
18
  return __awaiter(this, void 0, void 0, function* () {
@@ -0,0 +1 @@
1
+ {"version":3,"file":"AutoBePrismaCompiler.js","sourceRoot":"","sources":["../../src/prisma/AutoBePrismaCompiler.ts"],"names":[],"mappings":";;;;;;;;;;;;AAOA,+CAA2C;AAE3C,2EAAwE;AACxE,qEAAkE;AAElE,MAAa,oBAAoB;IAClB,OAAO,CAClB,KAAiC;;YAEjC,MAAM,QAAQ,GAAgB,IAAI,0BAAW,EAAE,CAAC;YAChD,OAAO,QAAQ,CAAC,OAAO,CAAC,KAAK,CAAC,KAAK,CAAC,CAAC;QACvC,CAAC;KAAA;IAEY,QAAQ,CACnB,WAAsC;;YAEtC,OAAO,IAAA,qDAAyB,EAAC,WAAW,CAAC,CAAC;QAChD,CAAC;KAAA;IAEY,KAAK;6DAChB,WAAsC,EACtC,OAA8B,UAAU;YAExC,OAAO,IAAA,+CAAsB,EAAC;gBAC5B,WAAW;gBACX,IAAI;aACL,CAAC,CAAC;QACL,CAAC;KAAA;CACF;AAvBD,oDAuBC"}
@@ -112,9 +112,12 @@ function writeRelations(props) {
112
112
  mappingName: otherForeign.relation.mappingName,
113
113
  }))))
114
114
  .flat(2);
115
- const foreignIndexes = props.model.foreignFields.filter((f) => props.model.uniqueIndexes.every((u) => u.fieldNames[0] !== f.name) &&
116
- (f.unique === true ||
117
- props.model.plainIndexes.every((p) => p.fieldNames[0] !== f.name)));
115
+ const foreignIndexes = props.model.foreignFields.filter((f) => {
116
+ if (f.unique === true)
117
+ return props.model.uniqueIndexes.every((u) => u.fieldNames.length !== 1 || u.fieldNames[0] !== f.name);
118
+ return (props.model.uniqueIndexes.every((u) => u.fieldNames[0] !== f.name) &&
119
+ props.model.plainIndexes.every((p) => p.fieldNames[0] !== f.name));
120
+ });
118
121
  const contents = [
119
122
  props.model.foreignFields.map(writeConstraint),
120
123
  hasRelationships.map((r) => {
@@ -230,7 +233,7 @@ const SQLITE_MAIN_FILE = utils_1.StringUtil.trim `
230
233
  }
231
234
  datasource db {
232
235
  provider = "sqlite"
233
- url = "file:./prisma.db"
236
+ url = "file:../../data.db"
234
237
  }
235
238
  generator markdown {
236
239
  provider = "prisma-markdown"
@@ -1 +1 @@
1
- {"version":3,"file":"writePrismaApplication.js","sourceRoot":"","sources":["../../src/prisma/writePrismaApplication.ts"],"names":[],"mappings":";;AAMA,wDAqBC;AA1BD,yCAA2C;AAE3C,kDAA+C;AAC/C,8CAA2C;AAE3C,SAAgB,sBAAsB,CAAC,KAGtC;IACC,KAAK,MAAM,IAAI,IAAI,KAAK,CAAC,WAAW,CAAC,KAAK;QACxC,KAAK,MAAM,KAAK,IAAI,IAAI,CAAC,MAAM;YAAE,eAAe,CAAC,KAAK,CAAC,CAAC;IAC1D,uCACK,MAAM,CAAC,WAAW,CACnB,KAAK,CAAC,WAAW,CAAC,KAAK;SACpB,MAAM,CAAC,CAAC,IAAI,EAAE,EAAE,CAAC,IAAI,CAAC,QAAQ,KAAK,aAAa,CAAC;SACjD,GAAG,CAAC,CAAC,IAAI,EAAE,EAAE,CAAC;QACb,IAAI,CAAC,QAAQ;QACb,SAAS,iCACJ,KAAK,KACR,IAAI,IACJ;KACH,CAAC,CACL,KACD,aAAa,EACX,KAAK,CAAC,IAAI,KAAK,UAAU,CAAC,CAAC,CAAC,kBAAkB,CAAC,CAAC,CAAC,gBAAgB,IACnE;AACJ,CAAC;AAED,SAAS,SAAS,CAAC,KAIlB;IACC,OAAO,KAAK,CAAC,IAAI,CAAC,MAAM;SACrB,GAAG,CAAC,CAAC,KAAK,EAAE,EAAE,CACb,UAAU,iCACL,KAAK,KACR,KAAK,IACL,CACH;SACA,IAAI,CAAC,MAAM,CAAC,CAAC;AAClB,CAAC;AAED,SAAS,UAAU,CAAC,KAKnB;IACC,OAAO;QACL,YAAY,CACV;YACE,KAAK,CAAC,KAAK,CAAC,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,SAAS,YAAY,CAAC,OAAe;IACnC,OAAO,OAAO;SACX,KAAK,CAAC,MAAM,CAAC;SACb,IAAI,CAAC,IAAI,CAAC;SACV,KAAK,CAAC,IAAI,CAAC;SACX,GAAG,CAAC,CAAC,GAAG,EAAE,EAAE,CAAC,MAAM,GAAG,CAAC,MAAM,CAAC,CAAC,CAAC,IAAI,GAAG,EAAE,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC;SACjD,IAAI,CAAC,IAAI,CAAC;SACV,IAAI,EAAE,CAAC;AACZ,CAAC;AAED,SAAS,MAAM,CAAC,OAAe;IAC7B,OAAO,OAAO;SACX,KAAK,CAAC,MAAM,CAAC;SACb,IAAI,CAAC,IAAI,CAAC;SACV,KAAK,CAAC,IAAI,CAAC;SACX,GAAG,CAAC,CAAC,GAAG,EAAE,EAAE,CAAC,KAAK,GAAG,EAAE,CAAC;SACxB,IAAI,CAAC,IAAI,CAAC,CAAC;AAChB,CAAC;AAED,MAAM,aAAa,GAAG;IACpB,eAAe;IACf,OAAO,EAAE,SAAS;IAClB,GAAG,EAAE,KAAK;IACV,MAAM,EAAE,OAAO;IACf,MAAM,EAAE,QAAQ;IAChB,UAAU;IACV,QAAQ,EAAE,UAAU;IACpB,IAAI,EAAE,QAAQ;IACd,GAAG,EAAE,QAAQ;CACd,CAAC;AACF,MAAM,uBAAuB,GAAG;IAC9B,GAAG,EAAE,aAAa;IAClB,MAAM,EAAE,qBAAqB;IAC7B,IAAI,EAAE,UAAU;IAChB,QAAQ,EAAE,iBAAiB;IAC3B,GAAG,EAAE,oBAAoB;CAC1B,CAAC;AAEF,MAAM,kBAAkB,GAAG,kBAAU,CAAC,IAAI,CAAA;;;;;;;;;;;;;;;CAezC,CAAC;AACF,MAAM,gBAAgB,GAAG,kBAAU,CAAC,IAAI,CAAA;;;;;;;;;;;;CAYvC,CAAC"}
1
+ {"version":3,"file":"writePrismaApplication.js","sourceRoot":"","sources":["../../src/prisma/writePrismaApplication.ts"],"names":[],"mappings":";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,CAAC;SACb,IAAI,CAAC,IAAI,CAAC;SACV,KAAK,CAAC,IAAI,CAAC;SACX,GAAG,CAAC,CAAC,GAAG,EAAE,EAAE,CAAC,MAAM,GAAG,CAAC,MAAM,CAAC,CAAC,CAAC,IAAI,GAAG,EAAE,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC;SACjD,IAAI,CAAC,IAAI,CAAC;SACV,IAAI,EAAE,CAAC;AACZ,CAAC;AAED,SAAS,MAAM,CAAC,OAAe;IAC7B,OAAO,OAAO;SACX,KAAK,CAAC,MAAM,CAAC;SACb,IAAI,CAAC,IAAI,CAAC;SACV,KAAK,CAAC,IAAI,CAAC;SACX,GAAG,CAAC,CAAC,GAAG,EAAE,EAAE,CAAC,KAAK,GAAG,EAAE,CAAC;SACxB,IAAI,CAAC,IAAI,CAAC,CAAC;AAChB,CAAC;AAED,MAAM,aAAa,GAAG;IACpB,eAAe;IACf,OAAO,EAAE,SAAS;IAClB,GAAG,EAAE,KAAK;IACV,MAAM,EAAE,OAAO;IACf,MAAM,EAAE,QAAQ;IAChB,UAAU;IACV,QAAQ,EAAE,UAAU;IACpB,IAAI,EAAE,QAAQ;IACd,GAAG,EAAE,QAAQ;CACd,CAAC;AACF,MAAM,uBAAuB,GAAG;IAC9B,GAAG,EAAE,aAAa;IAClB,MAAM,EAAE,qBAAqB;IAC7B,IAAI,EAAE,UAAU;IAChB,QAAQ,EAAE,iBAAiB;IAC3B,GAAG,EAAE,oBAAoB;CAC1B,CAAC;AAEF,MAAM,kBAAkB,GAAG,kBAAU,CAAC,IAAI,CAAA;;;;;;;;;;;;;;;CAezC,CAAC;AACF,MAAM,gBAAgB,GAAG,kBAAU,CAAC,IAAI,CAAA;;;;;;;;;;;;CAYvC,CAAC"}
@@ -0,0 +1 @@
1
+ export declare const AutoBeCompilerInterfaceTemplate: Record<string, string>;
@@ -0,0 +1,8 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.AutoBeCompilerInterfaceTemplate = void 0;
4
+ exports.AutoBeCompilerInterfaceTemplate = {
5
+ "README.md": "# AutoBE Generated Backend Server\n\n![AutoBE Logo](https://github.com/user-attachments/assets/a90d14be-fd50-4dc7-ae9d-ca66c2124f31)\n\nA backend repository generated by [`@autobe`](https://github.com/wrtnlabs/autobe).\n\nThis backend program was automatically generated using [`@autobe`](https://github.com/wrtnlabs/autobe), the AI vibe coding agent for backend servers of below stack.\n\n- TypeScript\n- NestJS / Nestia\n- Prisma\n- Postgres\n\n## Project Structure\n\nThis template project has categorized directories like below.\n\nAs you can see from the below, all of the Backend source files are placed into the [src](src/) directory. When you build the TypeScript source files, compiled files would be placed into the `lib` directory following the [tsconfig.json](tsconfig.json) configuration. Otherwise you build client [SDK](#32-sdk) library for npm publishing and their compiled files would be placed into the [packages](packages) directory.\n\n - [packages/api/](packages/api): SDK module built by `npm run build:api`\n - [src/](src): Backend source directory\n - [src/api/](src/api/): Client SDK that would be published to the `@ORGANIZATION/PROJECT-api`\n - [**src/api/functional/**](src/api/functional/): API functions generated by the [`nestia`](https://github.com/samchon/nestia)\n - [**src/api/structures/**](src/api/structures/): DTO structures\n - [src/controllers/](src/controllers/): Controller classes of the Main Program\n - [**test/**](test): Test Automation Program\n - [test/features](test/features): List of test functions\n - [nestia.config.ts](nestia.config.ts): Configuration file of [`nestia`](https://github.com/samchon/nestia)\n - [package.json](package.json): NPM configuration\n - [tsconfig.json](tsconfig.json): TypeScript configuration for the main program\n\n## NPM Run Commands\n\nList of the run commands defined in the [package.json](package.json) are like below:\n\n - Test\n - **`test`**: Run test automation program\n - `benchmark`: Run performance benchmark program\n - Build\n - `build`: Build everything\n - `build:main`: Build main program (`src` directory)\n - `build:test` Build test automation program (`test` directory)\n - `build:sdk`: Build SDK into main program only\n - `build:swagger`: Build Swagger Documents\n - **`dev`**: Incremental build for development (test program)\n - Deploy\n - `package:api`: Build and deploy the SDK library to the NPM\n - `start`: Start the backend server\n - `start:dev`: Start the backend server with incremental build and reload\n - Webpack\n - `webpack`: Run webpack bundler\n - `webpack:start`: Start the backend server built by webpack\n - `webpack:test`: Run test program to the webpack built\n\n## Specialization\n\nTransform this template project to be yours.\n\nWhen you've created a new backend project through this template project, you can specialize it to be suitable for you by changing some words. Replace below words through IDE specific function like `Edit > Replace in Files` (*Ctrl + Shift + H*), who've been supported by the VSCode.\n\n| Before | After\n|--------------|----------------------------------------\n| ORGANIZATION | Your account or corporation name\n| PROJECT | Your own project name\n| AUTHOR | Author name\n| https://github.com/samchon/nestia-start | Your repository URL",
6
+ "test/tsconfig.json": "{\n \"extends\": \"../tsconfig.json\",\n \"compilerOptions\": {\n \"outDir\": \"../bin\",\n \"noUnusedLocals\": false,\n \"noUnusedParameters\": false,\n },\n \"include\": [\".\", \"../src\"]\n}"
7
+ };
8
+ //# sourceMappingURL=AutoBeCompilerInterfaceTemplate.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"AutoBeCompilerInterfaceTemplate.js","sourceRoot":"","sources":["../../src/raw/AutoBeCompilerInterfaceTemplate.ts"],"names":[],"mappings":";;;AAAa,QAAA,+BAA+B,GAA2B;IACrE,WAAW,EAAE,wzGAAwzG;IACr0G,oBAAoB,EAAE,iNAAiN;CACxO,CAAC"}
@@ -0,0 +1 @@
1
+ export declare const AutoBeCompilerRealizeTemplate: Record<string, string>;
@@ -0,0 +1,17 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.AutoBeCompilerRealizeTemplate = void 0;
4
+ exports.AutoBeCompilerRealizeTemplate = {
5
+ ".gitignore": "bin/\ndist/\nlib/\nnode_modules/\n\nprisma/migrations\nprisma/schema/migrations\nprisma/bbs.db\n\n*.DS_Store\npackage-lock.json\npnpm-lock.yaml\n.npmrc",
6
+ "package.json": "{\n \"private\": true,\n \"name\": \"@ORGANIZATION/PROJECT\",\n \"version\": \"0.1.0\",\n \"description\": \"Starter kit of Nestia\",\n \"main\": \"lib/index.js\",\n \"scripts\": {\n \"benchmark\": \"node bin/test/benchmark\",\n \"test\": \"node bin/test\",\n \"test:webpack\": \"npm run webpack && node bin/test/webpack.js\",\n \"------------------------BUILDS------------------------\": \"\",\n \"build\": \"npm run build:prisma && npm run build:sdk && npm run build:main && npm run build:test\",\n \"build:api\": \"rimraf packages/api/lib && nestia all && rimraf packages/api/lib && tsc -p packages/api/tsconfig.json && rollup -c packages/api/rollup.config.js\",\n \"build:env\": \"ts-node build/env.ts\",\n \"build:main\": \"rimraf lib && tsc\",\n \"build:sdk\": \"rimraf src/api/functional && nestia sdk\",\n \"build:prisma\": \"prisma generate --schema prisma/schema\",\n \"build:swagger\": \"nestia swagger\",\n \"build:test\": \"rimraf bin && tsc -p test/tsconfig.json\",\n \"dev\": \"npm run build:test -- --watch\",\n \"eslint\": \"eslint src && eslint test\",\n \"eslint:fix\": \"eslint --fix src && eslint --fix test\",\n \"prepare\": \"ts-patch install && npm run build:env && npm run build:prisma\",\n \"prettier\": \"prettier src --write && prettier test --write\",\n \"------------------------WEBPACK------------------------\": \"\",\n \"webpack\": \"rimraf dist && webpack\",\n \"webpack:start\": \"cd dist && node dist/server\",\n \"webpack:test\": \"npm run webpack && node bin/test/webpack.js\",\n \"------------------------DEPLOYS------------------------\": \"\",\n \"package:api\": \"npm run build:api && cd packages/api && npm publish\",\n \"start\": \"node lib/executable/server\",\n \"start:dev\": \"nest start --watch\",\n \"start:swagger\": \"ts-node src/executable/swagger.ts\"\n },\n \"repository\": {\n \"type\": \"git\",\n \"url\": \"https://github.com/samchon/nestia-start\"\n },\n \"keywords\": [\n \"nestia\",\n \"template\",\n \"boilerplate\"\n ],\n \"author\": \"AUTHOR\",\n \"license\": \"MIT\",\n \"bugs\": {\n \"url\": \"https://github.com/samchon/nestia-start/issues\"\n },\n \"homepage\": \"https://github.com/samchon/nestia-start#readme\",\n \"devDependencies\": {\n \"@autobe/interface\": \"^0.10.6\",\n \"@nestia/benchmark\": \"^7.1.1\",\n \"@nestia/e2e\": \"^7.1.1\",\n \"@nestia/sdk\": \"^7.1.1\",\n \"@nestjs/cli\": \"^11.0.7\",\n \"@rollup/plugin-terser\": \"^0.4.4\",\n \"@rollup/plugin-typescript\": \"^11.1.6\",\n \"@trivago/prettier-plugin-sort-imports\": \"^4.3.0\",\n \"@types/bcryptjs\": \"^3.0.0\",\n \"@types/cli\": \"^0.11.21\",\n \"@types/cli-progress\": \"^3.11.5\",\n \"@types/express\": \"^4.17.21\",\n \"@types/inquirer\": \"^8.2.5\",\n \"@types/jsonwebtoken\": \"^9.0.5\",\n \"@types/node\": \"^18.11.0\",\n \"@types/uuid\": \"^8.3.4\",\n \"@typescript-eslint/eslint-plugin\": \"^8.1.0\",\n \"@typescript-eslint/parser\": \"^8.1.0\",\n \"chalk\": \"^4.1.2\",\n \"cli\": \"^1.0.1\",\n \"cli-progress\": \"^3.12.0\",\n \"copy-webpack-plugin\": \"^11.0.0\",\n \"eslint-plugin-deprecation\": \"^3.0.0\",\n \"express\": \"^4.18.2\",\n \"fastify\": \"^5.4.0\",\n \"nestia\": \"^7.1.1\",\n \"prettier\": \"^3.2.4\",\n \"prettier-plugin-prisma\": \"^5.0.0\",\n \"prisma-markdown\": \"^3.0.1\",\n \"rimraf\": \"^3.0.2\",\n \"rollup\": \"^4.18.0\",\n \"source-map-support\": \"^0.5.21\",\n \"swagger-ui-express\": \"^5.0.0\",\n \"ts-loader\": \"^9.5.1\",\n \"ts-node\": \"^10.9.1\",\n \"ts-patch\": \"^3.3.0\",\n \"typescript\": \"~5.8.3\",\n \"typescript-transform-paths\": \"^3.5.5\",\n \"webpack\": \"^5.89.0\",\n \"webpack-cli\": \"^5.1.4\",\n \"write-file-webpack-plugin\": \"^4.5.1\"\n },\n \"dependencies\": {\n \"@nestia/core\": \"^7.1.1\",\n \"@nestia/fetcher\": \"^7.1.1\",\n \"@nestjs/common\": \"^11.1.3\",\n \"@nestjs/core\": \"^11.1.3\",\n \"@nestjs/platform-express\": \"^11.1.3\",\n \"@nestjs/platform-fastify\": \"^11.1.3\",\n \"@prisma/client\": \"^6.11.1\",\n \"bcryptjs\": \"^3.0.2\",\n \"commander\": \"10.0.0\",\n \"dotenv\": \"^16.3.1\",\n \"dotenv-expand\": \"^10.0.0\",\n \"inquirer\": \"8.2.5\",\n \"jsonwebtoken\": \"^9.0.2\",\n \"prisma\": \"^6.11.1\",\n \"serialize-error\": \"^4.1.0\",\n \"tgrid\": \"^1.1.0\",\n \"tstl\": \"^3.0.0\",\n \"typia\": \"^9.5.0\",\n \"uuid\": \"^9.0.0\"\n },\n \"stackblitz\": {\n \"startCommand\": \"npm run prepare && npm run build:test && npm run test -- --simultaneous 1\"\n }\n}\n",
7
+ "src/MyGlobal.ts": "import { PrismaClient } from \"@prisma/client\";\nimport dotenv from \"dotenv\";\nimport dotenvExpand from \"dotenv-expand\";\nimport { Singleton } from \"tstl\";\nimport typia from \"typia\";\n\n/* eslint-disable */\nexport class MyGlobal {\n public static readonly prisma: PrismaClient = new PrismaClient();\n public static testing: boolean = false;\n public static get env(): MyGlobal.IEnvironments {\n return environments.get();\n }\n}\nexport namespace MyGlobal {\n export interface IEnvironments {\n API_PORT: `${number}`;\n }\n}\nconst environments = new Singleton(() => {\n const env = dotenv.config();\n dotenvExpand.expand(env);\n return typia.assert<MyGlobal.IEnvironments>(process.env);\n});\n",
8
+ "src/providers/jwtDecode.ts": "export function jwtDecode(token: string): { id: string; type: string } {\n try {\n const base64Url = token.split(\".\")[1];\n if (!base64Url) throw new Error(\"Invalid token format\");\n\n const base64 = base64Url.replace(/-/g, \"+\").replace(/_/g, \"/\");\n const jsonPayload = decodeURIComponent(\n atob(base64)\n .split(\"\")\n .map((c) => `%${c.charCodeAt(0).toString(16).padStart(2, \"0\")}`)\n .join(\"\"),\n );\n\n const decoded = JSON.parse(jsonPayload) as unknown;\n\n if (\n typeof decoded === \"object\" &&\n decoded !== null &&\n typeof (decoded as any).id === \"string\" &&\n typeof (decoded as any).type === \"string\"\n ) {\n return {\n id: (decoded as { id: string }).id,\n type: (decoded as { type: string }).type,\n };\n }\n\n throw new Error(\"Invalid token payload\");\n } catch {\n throw new Error(\"Failed to decode JWT token\");\n }\n}\n",
9
+ "src/setup/MySetupWizard.ts": "import cp from \"child_process\";\n\nimport { MyConfiguration } from \"../MyConfiguration\";\nimport { MyGlobal } from \"../MyGlobal\";\n\nexport namespace MySetupWizard {\n export async function schema(): Promise<void> {\n if (MyGlobal.testing === false)\n throw new Error(\n \"Error on SetupWizard.schema(): unable to reset database in non-test mode.\",\n );\n const execute = (type: string) => (argv: string) =>\n cp.execSync(`npx prisma migrate ${type} --schema=prisma/schema ${argv}`, {\n stdio: \"ignore\",\n cwd: MyConfiguration.ROOT,\n });\n execute(\"reset\")(\"--force\");\n execute(\"dev\")(\"--name init\");\n }\n\n export async function seed(): Promise<void> {}\n}\n",
10
+ "test/servant.ts": "import { DynamicExecutor } from \"@nestia/e2e\";\nimport { Driver, WorkerServer } from \"tgrid\";\n\nimport { MyBackend } from \"../src/MyBackend\";\nimport { MyGlobal } from \"../src/MyGlobal\";\nimport { IAutoBeRealizeTestConfig } from \"./autobe/compiler/IAutoBeRealizeTestConfig\";\nimport { IAutoBeRealizeTestListener } from \"./autobe/compiler/IAutoBeRealizeTestListener\";\nimport { IAutoBeRealizeTestOperation } from \"./autobe/compiler/IAutoBeRealizeTestOperation\";\nimport { IAutoBeRealizeTestResult } from \"./autobe/compiler/IAutoBeRealizeTestResult\";\nimport { IAutoBeRealizeTestService } from \"./autobe/compiler/IAutoBeRealizeTestService\";\nimport { TestAutomation } from \"./helpers/TestAutomation\";\n\nclass AutoBeRealizeTestService implements IAutoBeRealizeTestService {\n public constructor(\n private readonly listener: Driver<IAutoBeRealizeTestListener>,\n ) {}\n\n public async execute(\n config: IAutoBeRealizeTestConfig,\n ): Promise<IAutoBeRealizeTestResult> {\n const start: Date = new Date();\n const operations: IAutoBeRealizeTestOperation[] = [];\n await TestAutomation.execute({\n open: async (): Promise<MyBackend> => {\n const backend: MyBackend = new MyBackend();\n await backend.open();\n return backend;\n },\n close: (backend: MyBackend): Promise<void> => backend.close(),\n options: {\n reset: config.reset ?? true,\n simultaneous: config.simultaneous ?? 1,\n },\n onComplete: (exec: DynamicExecutor.IExecution): void => {\n const op: IAutoBeRealizeTestOperation = {\n name: exec.name,\n location: exec.location,\n value: exec.value,\n error: exec.error,\n started_at: exec.started_at,\n completed_at: exec.completed_at,\n };\n this.listener.onOperation(op).catch(() => {});\n operations.push(op);\n },\n onReset: (): void => {\n this.listener.onReset().catch(() => {});\n },\n });\n return {\n reset: config.reset ?? true,\n simultaneous: config.simultaneous ?? 1,\n operations,\n started_at: start.toISOString(),\n completed_at: new Date().toISOString(),\n };\n }\n}\n\nconst main = async (): Promise<void> => {\n const worker: WorkerServer<\n null,\n IAutoBeRealizeTestService,\n IAutoBeRealizeTestListener\n > = new WorkerServer();\n const listener: Driver<IAutoBeRealizeTestListener> = worker.getDriver();\n const service: AutoBeRealizeTestService = new AutoBeRealizeTestService(\n listener,\n );\n\n MyGlobal.testing = true;\n await worker.open(service);\n};\nmain().catch((error) => {\n console.log(error);\n process.exit(-1);\n});\n",
11
+ "test/autobe/compiler/IAutoBeRealizeTestOperation.ts": "//---------------------------------------------------\n// Cloned from @autobe/interface\n//---------------------------------------------------\nimport { tags } from \"typia\";\n\n/**\n * Detailed result interface representing the execution outcome of an individual\n * E2E test function during comprehensive backend implementation validation.\n *\n * This interface captures comprehensive information about a single test\n * operation execution, including identification details, execution results,\n * error conditions, and precise timing data. Each operation represents the\n * validation of a specific API endpoint or business scenario through Test\n * agent-generated E2E test functions executed against the fully implemented\n * backend application.\n *\n * The operation result provides granular visibility into test execution\n * outcomes, enabling detailed analysis of implementation quality, business\n * logic compliance, and performance characteristics at the individual test\n * level. This detailed tracking supports comprehensive validation reporting and\n * precise identification of implementation issues when they occur.\n *\n * @author Samchon\n */\nexport interface IAutoBeRealizeTestOperation {\n /**\n * Unique identifier name of the executed E2E test function.\n *\n * Specifies the function name that was executed during this test operation,\n * typically corresponding to the Test agent-generated test function\n * identifier. This name provides direct traceability between test results and\n * the specific business scenarios, API endpoints, or validation logic being\n * tested.\n *\n * The test function name serves as the primary identifier for correlating\n * execution results with the original test scenarios, enabling stakeholders\n * to understand which specific functionality was validated and whether the\n * implementation correctly fulfills the intended business requirements and\n * API contracts.\n */\n name: string;\n\n /**\n * File system path location of the executed test function source code.\n *\n * Specifies the relative or absolute path to the test file that contains the\n * executed function within the project structure. This location information\n * enables direct navigation to the test source code for detailed analysis,\n * debugging, result interpretation, or modification purposes.\n *\n * The file location provides essential context for understanding test\n * organization, enables developers to quickly locate and examine the specific\n * test implementation, and supports comprehensive test suite maintenance and\n * documentation activities.\n */\n location: string;\n\n /**\n * Return value or result data produced by the test function execution.\n *\n * Contains the actual value returned by the test function upon completion,\n * regardless of whether execution succeeded or failed. This could include API\n * response objects, validation results, test data, computed values, or any\n * other output that the test function produces as part of its business logic\n * validation or endpoint testing.\n *\n * For successful test executions, this value represents the expected result\n * that demonstrates correct implementation behavior. The return value\n * provides insight into the test execution flow and can be analyzed to verify\n * that API responses match expected formats, business logic produces correct\n * outcomes, and data transformations operate as intended.\n */\n value: unknown;\n\n /**\n * Error information captured during test function execution, if any occurred.\n *\n * Contains detailed error information when the test function encounters\n * exceptions, assertion failures, timeout conditions, or other error states\n * during execution. When null, it indicates that the test completed\n * successfully without encountering any error conditions. When present, the\n * error provides comprehensive diagnostic information for understanding\n * implementation issues or test failures.\n *\n * Error information is crucial for identifying implementation defects, API\n * contract violations, business logic errors, integration failures, or\n * performance issues that prevent the backend application from meeting its\n * requirements. The error details enable developers to pinpoint specific\n * problems and implement necessary corrections to achieve full compliance\n * with validation scenarios.\n */\n error: null | unknown;\n\n /**\n * Precise timestamp when this specific test operation began execution.\n *\n * Records the exact moment when this individual test function started\n * execution, providing the reference point for measuring test duration and\n * understanding the temporal sequence of test operations within the overall\n * validation process. This timestamp enables detailed performance analysis\n * and execution timeline reconstruction.\n *\n * The start timestamp is essential for identifying execution patterns,\n * analyzing test concurrency behavior, measuring individual test performance,\n * and understanding the temporal distribution of test execution within the\n * comprehensive validation suite.\n */\n started_at: string & tags.Format<\"date-time\">;\n\n /**\n * Precise timestamp when this specific test operation finished execution.\n *\n * Records the exact moment when this individual test function completed\n * execution, regardless of whether it succeeded or failed. Combined with the\n * start timestamp, this enables precise calculation of test execution\n * duration and provides completion reference for the overall test timeline.\n *\n * The completion timestamp is valuable for performance analysis of individual\n * test operations, identifying slow-performing test scenarios, understanding\n * test execution efficiency, and maintaining comprehensive audit trails of\n * the validation process. It supports optimization efforts and helps identify\n * potential bottlenecks in either the test implementation or the backend\n * application being validated.\n */\n completed_at: string & tags.Format<\"date-time\">;\n}\n",
12
+ "test/autobe/compiler/IAutoBeRealizeTestConfig.ts": "//---------------------------------------------------\n// Cloned from @autobe/interface\n//---------------------------------------------------\n/**\n * Configuration interface defining the essential execution parameters required\n * for comprehensive E2E test suite validation against fully implemented backend\n * applications.\n *\n * This interface encapsulates the core execution settings and control\n * parameters necessary to orchestrate the final validation phase of the AutoBE\n * development pipeline. It provides streamlined configuration options that\n * control test execution behavior, database management, and performance\n * characteristics without requiring direct access to implementation files or\n * database schemas.\n *\n * The configuration assumes that the test execution environment has been\n * pre-configured with all necessary resources including generated\n * implementation files, database schemas, and package dependencies. This\n * interface focuses solely on runtime execution parameters that control how the\n * test suite operates within the prepared environment.\n *\n * This lightweight configuration approach enables flexible test execution\n * across different environments while maintaining clear separation between\n * resource provisioning and execution control, supporting both development and\n * production validation scenarios.\n *\n * @author Samchon\n */\nexport interface IAutoBeRealizeTestConfig {\n /**\n * Optional flag indicating whether to perform a complete database reset\n * before test execution.\n *\n * When true, specifies that the test execution should begin with a\n * comprehensive database reset, purging all existing data and reconstructing\n * tables to their initial schema-defined state. When false, test execution\n * proceeds with the current database state, which may contain residual data\n * from previous operations.\n *\n * Database reset is crucial for ensuring test isolation, reproducibility, and\n * deterministic results. Clean state testing eliminates interference from\n * residual data and guarantees that each test execution cycle operates under\n * identical baseline conditions, enabling accurate validation of backend\n * implementation behavior.\n *\n * @default true\n */\n reset?: boolean;\n\n /**\n * Optional specification of the maximum number of test functions to execute\n * concurrently during the test suite run.\n *\n * Defines the concurrent execution limit for E2E test functions to optimize\n * testing performance while maintaining system stability and resource\n * management. This value balances test execution speed with resource\n * consumption and helps prevent system overload during comprehensive\n * validation.\n *\n * Concurrent execution significantly reduces total testing time for large\n * test suites while validating the backend application's ability to handle\n * parallel requests correctly. The simultaneous limit ensures controlled load\n * conditions that provide meaningful performance insights while maintaining\n * test reliability and result accuracy.\n *\n * @default 1\n */\n simultaneous?: number;\n}\n",
13
+ "test/autobe/compiler/IAutoBeRealizeTestResult.ts": "//---------------------------------------------------\n// Cloned from @autobe/interface\n//---------------------------------------------------\nimport { tags } from \"typia\";\n\nimport { IAutoBeRealizeTestOperation } from \"./IAutoBeRealizeTestOperation\";\n\n/**\n * Comprehensive result interface containing complete information about E2E test\n * suite execution for backend implementation validation.\n *\n * This interface represents the final consolidated results of executing the\n * entire Test agent-generated E2E test suite against the fully implemented\n * backend application. It encapsulates all aspects of the test execution\n * process including configuration parameters, individual operation results, and\n * timing information that collectively determine the validation outcome of the\n * generated backend implementation.\n *\n * The result structure provides stakeholders with comprehensive visibility into\n * the validation process, enabling detailed analysis of backend implementation\n * quality, compliance with requirements, and production readiness assessment\n * based on exhaustive functional testing.\n *\n * @author Samchon\n */\nexport interface IAutoBeRealizeTestResult {\n /**\n * Whether the test execution included a clean database reset before testing.\n *\n * Indicates if the test suite execution began with a complete database reset\n * to ensure clean testing conditions. When true, all existing data was purged\n * and database tables were reconstructed to their initial state before test\n * execution commenced, guaranteeing test isolation and reproducibility.\n *\n * Database reset is essential for ensuring that test results are\n * deterministic and accurately reflect the application's behavior under\n * controlled conditions, free from interference by residual data from\n * previous executions or development activities. This flag helps stakeholders\n * understand the testing conditions and trust the reliability of results.\n */\n reset: boolean;\n\n /**\n * Number of test functions that were executed simultaneously during the test\n * suite run.\n *\n * Specifies the concurrent execution limit that was applied during E2E test\n * function execution to optimize testing performance while maintaining system\n * stability. This value represents the balance between test execution speed\n * and resource consumption that was used to validate the backend\n * implementation's ability to handle concurrent requests.\n *\n * The simultaneous execution count provides insight into the load conditions\n * under which the backend application was validated, helping stakeholders\n * understand the concurrency testing coverage and the application's\n * performance characteristics under parallel request scenarios.\n */\n simultaneous: number;\n\n /**\n * Complete collection of individual test operation results with detailed\n * execution information.\n *\n * Contains the comprehensive array of {@link IAutoBeRealizeTestOperation}\n * results representing every E2E test function that was executed during the\n * validation process. Each operation result includes detailed information\n * about test execution outcomes, return values, error conditions, timing\n * data, and validation status for specific API endpoints or business\n * scenarios.\n *\n * This complete result set enables stakeholders to perform detailed analysis\n * of which functionality passed validation, which tests failed, what specific\n * issues were encountered, and how the backend implementation performs under\n * various test scenarios. The operation results serve as the authoritative\n * record of implementation quality and compliance with established\n * requirements.\n */\n operations: IAutoBeRealizeTestOperation[];\n\n /**\n * Timestamp when the comprehensive test suite execution was initiated.\n *\n * Records the exact moment when the E2E test suite execution began, marking\n * the start of the final validation phase in the AutoBE development pipeline.\n * This timestamp provides the reference point for understanding the complete\n * test execution timeline and measuring the duration of comprehensive backend\n * validation.\n *\n * The start timestamp is essential for performance analysis of the entire\n * validation process, enabling stakeholders to understand test execution\n * efficiency and identify potential optimization opportunities in the testing\n * infrastructure or backend implementation.\n */\n started_at: string & tags.Format<\"date-time\">;\n\n /**\n * Timestamp when the entire test suite execution was finalized.\n *\n * Records the exact moment when all planned E2E test operations finished\n * execution, marking the completion of the comprehensive validation process.\n * This timestamp represents the definitive end point of the AutoBE\n * development pipeline validation phase and provides the completion reference\n * for calculating total validation duration.\n *\n * The completion timestamp serves as the official validation completion\n * marker for stakeholders tracking project delivery milestones and provides\n * essential audit trail information for the complete development and\n * validation cycle. Combined with the start timestamp, it enables precise\n * measurement of the total time required for comprehensive backend\n * validation.\n */\n completed_at: string & tags.Format<\"date-time\">;\n}\n",
14
+ "test/autobe/compiler/IAutoBeRealizeTestListener.ts": "//---------------------------------------------------\n// Cloned from @autobe/interface\n//---------------------------------------------------\nimport { IAutoBeRealizeTestOperation } from \"../compiler/IAutoBeRealizeTestOperation\";\n\n/**\n * Interface for Worker RPC event listener provided by client processes to\n * receive real-time E2E test execution events from worker processes.\n *\n * This interface defines the event handling contract for client processes that\n * delegate E2E test execution to dedicated worker processes. Client processes\n * provide an implementation of this interface to receive real-time\n * notifications about test operation progress, individual test completion\n * events, and database reset activities throughout the comprehensive test\n * execution pipeline.\n *\n * In TGrid's RPC paradigm, this listener acts as the Acceptor that client\n * processes expose to worker processes, enabling bidirectional communication\n * where workers can notify clients about test execution progress while\n * maintaining process isolation. The listener functions enable client processes\n * to provide interactive user experiences, display progress indicators, and\n * respond to the dynamic nature of test execution workflows.\n *\n * The listener interface focuses on critical test execution events that require\n * immediate client notification, ensuring optimal performance by transmitting\n * only essential progress information from worker to client processes without\n * overwhelming the communication channel.\n *\n * @author Samchon\n */\nexport interface IAutoBeRealizeTestListener {\n /**\n * Handles individual E2E test operation completion events from worker\n * processes.\n *\n * Called when each individual E2E test function completes execution in the\n * worker process, providing comprehensive details about the test operation\n * outcome including execution results, timing information, error conditions,\n * and progress tracking data. This enables client processes to display\n * real-time test execution progress and provide immediate feedback about test\n * validation outcomes.\n *\n * The operation events provide granular visibility into the test execution\n * pipeline, allowing client processes to:\n *\n * - Display individual test completion status and results\n * - Track overall test suite execution progress with completion counters\n * - Show specific test function names and execution locations for context\n * - Present detailed error information when test failures occur\n * - Calculate and display test execution performance metrics and timing data\n * - Provide real-time feedback about backend implementation quality assessment\n *\n * This event stream enables responsive user interfaces that keep stakeholders\n * informed about comprehensive validation progress while the actual test\n * execution occurs in isolated worker processes for optimal system\n * performance.\n *\n * @param event Complete test operation result containing execution details,\n * timing information, success/failure status, return values, error\n * conditions, and progress tracking data from the individual test function\n * execution in the worker process\n * @returns Promise that resolves when the client process has completed\n * handling the test operation event, enabling proper flow control and\n * ensuring client readiness for subsequent operation notifications\n */\n onOperation(event: IAutoBeRealizeTestOperation): Promise<void>;\n\n /**\n * Handles database reset completion events from worker processes.\n *\n * Called when the worker process completes database reset operations before\n * test execution begins, indicating that the test environment has been\n * prepared with clean initial conditions. This event enables client processes\n * to display test preparation status and confirm that subsequent test\n * operations will execute under controlled, predictable database states.\n *\n * The reset event provides important timing information for client processes\n * to:\n *\n * - Display test preparation progress and database initialization status\n * - Confirm that clean testing conditions have been established\n * - Indicate the transition from setup phase to actual test execution\n * - Track the overall test execution timeline including preparation overhead\n * - Provide user feedback about test environment readiness and validation scope\n *\n * Database reset represents a critical preparation step that ensures test\n * isolation and reproducibility by eliminating interference from residual\n * data, making this event essential for client understanding of test\n * execution reliability and deterministic result conditions.\n *\n * @returns Promise that resolves when the client process has completed\n * handling the database reset notification, ensuring proper synchronization\n * between worker database preparation activities and client progress\n * display updates\n */\n onReset(): Promise<void>;\n}\n",
15
+ "test/autobe/compiler/IAutoBeRealizeTestService.ts": "//---------------------------------------------------\n// Cloned from @autobe/interface\n//---------------------------------------------------\nimport { IAutoBeRealizeTestResult } from \"../compiler/IAutoBeRealizeTestResult\";\nimport { IAutoBeRealizeTestConfig } from \"./IAutoBeRealizeTestConfig\";\n\n/**\n * Interface representing the Worker RPC service for executing comprehensive E2E\n * test validation against fully implemented backend applications.\n *\n * This interface defines the remote procedure call functions that can be\n * invoked on dedicated worker processes to execute complete E2E test suites\n * against generated backend implementations. The service enables comprehensive\n * validation of backend application quality and production readiness through\n * automated test execution workflows in isolated worker environments.\n *\n * In TGrid's RPC paradigm, this service acts as the Provider that worker\n * processes expose for test execution operations. The main process obtains a\n * `Driver<IAutoBeRealizeTestService>` instance to delegate intensive test\n * execution tasks to worker processes, ensuring optimal performance and\n * resource isolation while maintaining system responsiveness during\n * comprehensive test validation workflows.\n *\n * The service orchestrates the complete test execution pipeline including\n * environment setup, database initialization, concurrent test function\n * execution, and comprehensive result collection to provide definitive\n * assessment of backend implementation quality and production deployment\n * readiness within dedicated worker process boundaries.\n *\n * @author Samchon\n */\nexport interface IAutoBeRealizeTestService {\n /**\n * Executes comprehensive E2E test suite against the fully implemented backend\n * application to validate production readiness.\n *\n * Performs complete test execution pipeline from environment setup through\n * test suite execution to result compilation, validating that the generated\n * backend implementation correctly fulfills all business requirements, API\n * contracts, and database integration specifications under realistic\n * operational conditions.\n *\n * The execution process encompasses:\n *\n * **Environment Preparation**:\n *\n * - Configuration of test environment with pre-loaded implementation files and\n * database schemas from the worker context\n * - Optional database reset for clean testing conditions that eliminate\n * interference from residual data\n * - Package dependency resolution and testing infrastructure setup\n * - Validation of all necessary resources for comprehensive test execution\n *\n * **Test Suite Execution**:\n *\n * - Systematic execution of Test agent-generated E2E test functions with\n * controlled concurrency for optimal performance\n * - Real-time monitoring of individual test operations with detailed progress\n * tracking and result collection\n * - Comprehensive error handling and result aggregation for both successful\n * validations and failure scenarios\n * - Integration testing of API endpoints, business logic, and database\n * operations under realistic load conditions\n *\n * **Quality Assessment**:\n *\n * - Validation of API contract compliance and response schema correctness\n * - Business logic verification through comprehensive scenario coverage\n * - Database integration testing with proper transaction handling\n * - Error condition testing to ensure robust error handling and recovery\n * - Performance validation under controlled concurrent request scenarios\n *\n * **Result Compilation**:\n *\n * - Detailed collection of individual test operation outcomes with timing and\n * performance data\n * - Comprehensive analysis of success rates, failure patterns, and\n * implementation quality metrics\n * - Production readiness assessment based on comprehensive validation results\n * - Detailed diagnostic information for any identified issues or failures\n *\n * The test execution provides the definitive assessment of whether the\n * generated backend application meets all specified requirements and is ready\n * for production deployment without manual debugging or modification. The\n * worker-based execution ensures optimal system performance by isolating\n * intensive test operations from the main process while maintaining\n * comprehensive validation accuracy.\n *\n * @param config Basic test execution configuration including database reset\n * and concurrency control settings. The worker process is expected to have\n * access to pre-loaded implementation files, database schemas, and package\n * configuration through its initialization context, requiring only\n * execution parameters for the test suite run.\n * @returns Promise resolving to comprehensive test execution results\n * including configuration details, individual operation outcomes, timing\n * information, success/failure analysis, and definitive production\n * readiness assessment from the isolated worker execution context\n */\n execute(config: IAutoBeRealizeTestConfig): Promise<IAutoBeRealizeTestResult>;\n}\n"
16
+ };
17
+ //# sourceMappingURL=AutoBeCompilerRealizeTemplate.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"AutoBeCompilerRealizeTemplate.js","sourceRoot":"","sources":["../../src/raw/AutoBeCompilerRealizeTemplate.ts"],"names":[],"mappings":";;;AAAa,QAAA,6BAA6B,GAA2B;IACnE,YAAY,EAAE,yJAAyJ;IACvK,cAAc,EAAE,6lJAA6lJ;IAC7mJ,iBAAiB,EAAE,ktBAAktB;IACruB,4BAA4B,EAAE,w8BAAw8B;IACt+B,4BAA4B,EAAE,iuBAAiuB;IAC/vB,iBAAiB,EAAE,uqFAAuqF;IAC1rF,qDAAqD,EAAE,wlMAAwlM;IAC/oM,kDAAkD,EAAE,uoGAAuoG;IAC3rG,kDAAkD,EAAE,w6KAAw6K;IAC59K,oDAAoD,EAAE,wgKAAwgK;IAC9jK,mDAAmD,EAAE,gpKAAgpK;CACtsK,CAAC"}
@@ -0,0 +1 @@
1
+ export declare const AutoBeCompilerTestTemplate: Record<string, string>;
@@ -0,0 +1,12 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.AutoBeCompilerTestTemplate = void 0;
4
+ exports.AutoBeCompilerTestTemplate = {
5
+ "package.json": "{\n \"private\": true,\n \"name\": \"@ORGANIZATION/PROJECT\",\n \"version\": \"0.1.0\",\n \"description\": \"Starter kit of Nestia\",\n \"main\": \"lib/index.js\",\n \"scripts\": {\n \"benchmark\": \"node bin/test/benchmark\",\n \"test\": \"node bin/test\",\n \"test:webpack\": \"npm run webpack && node bin/test/webpack.js\",\n \"------------------------BUILDS------------------------\": \"\",\n \"build\": \"npm run build:sdk && npm run build:main && npm run build:test\",\n \"build:api\": \"rimraf packages/api/lib && nestia all && rimraf packages/api/lib && tsc -p packages/api/tsconfig.json && rollup -c packages/api/rollup.config.js\",\n \"build:main\": \"rimraf lib && tsc\",\n \"build:sdk\": \"rimraf src/api/functional && nestia sdk\",\n \"build:swagger\": \"npx nestia swagger\",\n \"build:test\": \"rimraf bin && tsc -p test/tsconfig.json\",\n \"dev\": \"npm run build:test -- --watch\",\n \"eslint\": \"eslint src && eslint test\",\n \"eslint:fix\": \"eslint --fix src && eslint --fix test\",\n \"prepare\": \"ts-patch install && ts-node build/env.ts\",\n \"prettier\": \"prettier src --write && prettier test --write\",\n \"------------------------WEBPACK------------------------\": \"\",\n \"webpack\": \"rimraf dist && webpack\",\n \"webpack:start\": \"cd dist && node dist/server\",\n \"webpack:test\": \"npm run webpack && node bin/test/webpack.js\",\n \"------------------------DEPLOYS------------------------\": \"\",\n \"package:api\": \"npm run build:api && cd packages/api && npm publish\",\n \"start\": \"node lib/executable/server\",\n \"start:dev\": \"nest start --watch\",\n \"start:swagger\": \"ts-node src/executable/swagger.ts\"\n },\n \"repository\": {\n \"type\": \"git\",\n \"url\": \"https://github.com/samchon/nestia-start\"\n },\n \"keywords\": [\n \"nestia\",\n \"template\",\n \"boilerplate\"\n ],\n \"author\": \"AUTHOR\",\n \"license\": \"MIT\",\n \"bugs\": {\n \"url\": \"https://github.com/samchon/nestia-start/issues\"\n },\n \"homepage\": \"https://github.com/samchon/nestia-start#readme\",\n \"devDependencies\": {\n \"@nestia/benchmark\": \"^7.1.1\",\n \"@nestia/e2e\": \"^7.1.1\",\n \"@nestia/sdk\": \"^7.1.1\",\n \"@nestjs/cli\": \"^11.0.7\",\n \"@rollup/plugin-terser\": \"^0.4.4\",\n \"@rollup/plugin-typescript\": \"^11.1.6\",\n \"@trivago/prettier-plugin-sort-imports\": \"^4.3.0\",\n \"@types/cli\": \"^0.11.21\",\n \"@types/cli-progress\": \"^3.11.5\",\n \"@types/express\": \"^4.17.21\",\n \"@types/inquirer\": \"^8.2.5\",\n \"@types/node\": \"^18.11.0\",\n \"@types/uuid\": \"^8.3.4\",\n \"@typescript-eslint/eslint-plugin\": \"^8.1.0\",\n \"@typescript-eslint/parser\": \"^8.1.0\",\n \"chalk\": \"^4.1.2\",\n \"cli\": \"^1.0.1\",\n \"cli-progress\": \"^3.12.0\",\n \"copy-webpack-plugin\": \"^11.0.0\",\n \"eslint-plugin-deprecation\": \"^3.0.0\",\n \"express\": \"^4.18.2\",\n \"nestia\": \"^7.1.1\",\n \"prettier\": \"^3.2.4\",\n \"prettier-plugin-prisma\": \"^5.0.0\",\n \"prisma-markdown\": \"^3.0.1\",\n \"rimraf\": \"^3.0.2\",\n \"rollup\": \"^4.18.0\",\n \"source-map-support\": \"^0.5.21\",\n \"swagger-ui-express\": \"^5.0.0\",\n \"ts-loader\": \"^9.5.1\",\n \"ts-node\": \"^10.9.1\",\n \"ts-patch\": \"^3.3.0\",\n \"typescript\": \"~5.8.3\",\n \"typescript-transform-paths\": \"^3.5.5\",\n \"webpack\": \"^5.89.0\",\n \"webpack-cli\": \"^5.1.4\",\n \"write-file-webpack-plugin\": \"^4.5.1\"\n },\n \"dependencies\": {\n \"@nestia/core\": \"^7.1.1\",\n \"@nestia/fetcher\": \"^7.1.1\",\n \"@nestjs/common\": \"^11.1.3\",\n \"@nestjs/core\": \"^11.1.3\",\n \"@nestjs/platform-express\": \"^11.1.3\",\n \"@prisma/client\": \"^6.11.1\",\n \"commander\": \"10.0.0\",\n \"dotenv\": \"^16.3.1\",\n \"dotenv-expand\": \"^10.0.0\",\n \"inquirer\": \"8.2.5\",\n \"prisma\": \"^6.11.1\",\n \"serialize-error\": \"^4.1.0\",\n \"tgrid\": \"^1.1.0\",\n \"tstl\": \"^3.0.0\",\n \"typia\": \"^9.5.0\",\n \"uuid\": \"^9.0.0\"\n },\n \"stackblitz\": {\n \"startCommand\": \"npm run prepare && npm run build:test && npm run test -- --simultaneous 1\"\n }\n}\n",
6
+ "src/setup/MySetupWizard.ts": "export namespace MySetupWizard {\n export async function schema(): Promise<void> {\n console.log(\"Realize agent has not generated main program yet.\");\n }\n\n export async function seed(): Promise<void> {}\n}\n",
7
+ "test/helpers/TestAutomation.ts": "import api from \"@ORGANIZATION/PROJECT-api\";\nimport { DynamicExecutor } from \"@nestia/e2e\";\nimport { sleep_for } from \"tstl\";\n\nimport { MyConfiguration } from \"../../src/MyConfiguration\";\nimport { MySetupWizard } from \"../../src/setup/MySetupWizard\";\n\nexport namespace TestAutomation {\n export interface IProps<T> {\n open(options: IOptions): Promise<T>;\n close(backend: T): Promise<void>;\n onComplete(exec: DynamicExecutor.IExecution): void;\n onReset(): void;\n options: IOptions;\n }\n\n export interface IOptions {\n reset: boolean;\n simultaneous: number;\n include?: string[];\n exclude?: string[];\n }\n\n export const execute = async <T>(\n props: IProps<T>,\n ): Promise<DynamicExecutor.IReport> => {\n // RESET\n if (props.options.reset === true) {\n await MySetupWizard.schema();\n await MySetupWizard.seed();\n await props.onReset();\n }\n\n // OPEN BACKEND\n const backend: T = await props.open(props.options);\n const connection: api.IConnection = {\n host: `http://127.0.0.1:${MyConfiguration.API_PORT()}`,\n };\n\n // DO TEST\n const report: DynamicExecutor.IReport = await DynamicExecutor.validate({\n prefix: \"test\",\n location: __dirname + \"/../features\",\n parameters: () => [\n {\n host: connection.host,\n } satisfies api.IConnection,\n ],\n filter: (func) =>\n (!props.options.include?.length ||\n (props.options.include ?? []).some((str) => func.includes(str))) &&\n (!props.options.exclude?.length ||\n (props.options.exclude ?? []).every((str) => !func.includes(str))),\n onComplete: props.onComplete,\n simultaneous: props.options.simultaneous,\n extension: __filename.split(\".\").pop()!,\n });\n\n // TERMINATE\n await sleep_for(2500);\n await props.close(backend);\n return report;\n };\n}\n",
8
+ "test/helpers/TestAutomationStdio.ts": "import { DynamicExecutor } from \"@nestia/e2e\";\nimport chalk from \"chalk\";\n\nimport { ArgumentParser } from \"./ArgumentParser\";\nimport { TestAutomation } from \"./TestAutomation\";\n\nexport namespace TestAutomationStdio {\n export const getOptions = () =>\n ArgumentParser.parse<TestAutomation.IOptions>(\n async (command, prompt, action) => {\n command.option(\"--reset <true|false>\", \"reset local DB or not\");\n command.option(\n \"--simultaneous <number>\",\n \"number of simultaneous requests\",\n );\n command.option(\"--include <string...>\", \"include feature files\");\n command.option(\"--exclude <string...>\", \"exclude feature files\");\n\n return action(async (options) => {\n // reset\n if (typeof options.reset === \"string\")\n options.reset = options.reset === \"true\";\n options.reset ??= await prompt.boolean(\"reset\")(\"Reset local DB\");\n\n // simultaneous\n options.simultaneous = Number(\n options.simultaneous ??\n (await prompt.number(\"simultaneous\")(\n \"Number of simultaneous requests to make\",\n )),\n );\n if (isNaN(options.simultaneous) || options.simultaneous <= 0)\n options.simultaneous = 1;\n return options as TestAutomation.IOptions;\n });\n },\n );\n\n export const onComplete = (exec: DynamicExecutor.IExecution): void => {\n const trace = (str: string) =>\n console.log(` - ${chalk.green(exec.name)}: ${str}`);\n if (exec.error === null) {\n const elapsed: number =\n new Date(exec.completed_at).getTime() -\n new Date(exec.started_at).getTime();\n trace(`${chalk.yellow(elapsed.toLocaleString())} ms`);\n } else trace(chalk.red(exec.error.name));\n };\n\n export const onReset = (start: Date) => (): void => {\n const now: Date = new Date();\n console.log(\n ` - Reset DB: ${(now.getDate() - start.getDate()).toLocaleString()} ms`,\n );\n };\n\n export const report = (report: DynamicExecutor.IReport): void => {\n const exceptions: Error[] = report.executions\n .filter((exec) => exec.error !== null)\n .map((exec) => exec.error!);\n if (exceptions.length === 0) {\n console.log(\"Success\");\n console.log(\"Elapsed time\", report.time.toLocaleString(), `ms`);\n } else {\n for (const exp of exceptions) console.log(exp);\n console.log(\"Failed\");\n console.log(\"Elapsed time\", report.time.toLocaleString(), `ms`);\n process.exit(-1);\n }\n };\n}\n",
9
+ "test/index.ts": "import { MyBackend } from \"../src/MyBackend\";\nimport { MyGlobal } from \"../src/MyGlobal\";\nimport { TestAutomation } from \"./helpers/TestAutomation\";\nimport { TestAutomationStdio } from \"./helpers/TestAutomationStdio\";\n\nconst main = async (): Promise<void> => {\n MyGlobal.testing = true;\n await TestAutomation.execute({\n open: async () => {\n const backend: MyBackend = new MyBackend();\n await backend.open();\n return backend;\n },\n close: (backend) => backend.close(),\n options: await TestAutomationStdio.getOptions(),\n onComplete: TestAutomationStdio.onComplete,\n onReset: TestAutomationStdio.onReset(new Date()),\n });\n};\nmain().catch((exp) => {\n console.log(exp);\n process.exit(-1);\n});\n",
10
+ "test/webpack.ts": "import cp from \"child_process\";\nimport { sleep_for } from \"tstl\";\n\nimport { MyConfiguration } from \"../src/MyConfiguration\";\nimport { MyGlobal } from \"../src/MyGlobal\";\nimport { TestAutomation } from \"./helpers/TestAutomation\";\nimport { TestAutomationStdio } from \"./helpers/TestAutomationStdio\";\n\nconst wait = async (): Promise<void> => {\n while (true)\n try {\n await fetch(`http://localhost:${MyConfiguration.API_PORT()}/dsafdsafsd`);\n return;\n } catch (exp) {\n await sleep_for(100);\n }\n};\n\nconst main = async (): Promise<void> => {\n MyGlobal.testing = true;\n await TestAutomation.execute({\n open: async () => {\n const backend: cp.ChildProcess = cp.fork(\n `${MyConfiguration.ROOT}/dist/server.js`,\n {\n cwd: `${MyConfiguration.ROOT}/dist`,\n },\n );\n await wait();\n return backend;\n },\n close: async (backend) => {\n backend.kill();\n },\n options: await TestAutomationStdio.getOptions(),\n onComplete: TestAutomationStdio.onComplete,\n onReset: TestAutomationStdio.onReset(new Date()),\n });\n};\nmain().catch((exp) => {\n console.log(exp);\n process.exit(-1);\n});\n"
11
+ };
12
+ //# sourceMappingURL=AutoBeCompilerTestTemplate.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"AutoBeCompilerTestTemplate.js","sourceRoot":"","sources":["../../src/raw/AutoBeCompilerTestTemplate.ts"],"names":[],"mappings":";;;AAAa,QAAA,0BAA0B,GAA2B;IAChE,cAAc,EAAE,0rIAA0rI;IAC1sI,4BAA4B,EAAE,4NAA4N;IAC1P,gCAAgC,EAAE,q5DAAq5D;IACv7D,qCAAqC,EAAE,gmFAAgmF;IACvoF,eAAe,EAAE,svBAAsvB;IACvwB,iBAAiB,EAAE,isCAAisC;CACrtC,CAAC"}