testeranto 0.79.38 → 0.79.39

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/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "testeranto",
3
3
  "description": "teeny tiny tightly-typed typescript tests",
4
- "version": "0.79.38",
4
+ "version": "0.79.39",
5
5
  "engines": {
6
6
  "node": "18.18.0"
7
7
  },
@@ -141,6 +141,10 @@
141
141
  "import": "./dist/module/TaskManBackEnd.js",
142
142
  "require": "./dist/common/TaskManBackEnd.js"
143
143
  },
144
+ "./src/Init": {
145
+ "import": "./dist/module/Init.js",
146
+ "require": "./dist/common/Init.js"
147
+ },
144
148
  "./src/preload": {
145
149
  "import": "./dist/module/preload.js",
146
150
  "require": "./dist/common/preload.js"
@@ -249,4 +253,4 @@
249
253
  "uuid": "^10.0.0",
250
254
  "ws": "^8.16.0"
251
255
  }
252
- }
256
+ }
package/src/Init.ts ADDED
@@ -0,0 +1,54 @@
1
+ import readline from "readline";
2
+ import fs from "fs";
3
+ import path from "path";
4
+ import { jsonc } from "jsonc";
5
+ import { v4 as uuidv4 } from "uuid";
6
+
7
+ import { IBuiltConfig, IRunTime } from "./lib/types";
8
+
9
+ import { PM_Main } from "./PM/main.js";
10
+ import { destinationOfRuntime } from "./utils.js";
11
+
12
+ var mode: "DEV" | "PROD" = process.argv[2] === "-dev" ? "DEV" : "PROD";
13
+
14
+ const node2web: Record<string, string[]> = {};
15
+ const web2node: Record<string, string[]> = {};
16
+ const childProcesses: Record<string, "loaded" | "running" | "done"> = {};
17
+
18
+ readline.emitKeypressEvents(process.stdin);
19
+ if (process.stdin.isTTY) process.stdin.setRawMode(true);
20
+
21
+ console.log("\n Puppeteer is running. Press 'q' to quit\n");
22
+ process.stdin.on("keypress", (str, key) => {
23
+ if (key.name === "q") {
24
+ process.exit();
25
+ }
26
+ });
27
+
28
+ export default async (partialConfig) => {
29
+ const config = {
30
+ ...partialConfig,
31
+ buildDir: process.cwd() + "/" + partialConfig.outdir,
32
+ };
33
+
34
+ fs.writeFileSync(
35
+ `${config.outdir}/testeranto.json`,
36
+ JSON.stringify(
37
+ {
38
+ ...config,
39
+ buildDir: process.cwd() + "/" + config.outdir,
40
+ },
41
+ null,
42
+ 2
43
+ )
44
+ );
45
+
46
+ fs.copyFileSync(
47
+ "./node_modules/testeranto/dist/prebuild/TaskManFrontEnd.js",
48
+ "docs/TaskManFrontEnd.js"
49
+ );
50
+ fs.copyFileSync(
51
+ "./node_modules/testeranto/dist/prebuild/TaskManFrontEnd.css",
52
+ "docs/TaskManFrontEnd.css"
53
+ );
54
+ };
package/src/Project.ts CHANGED
@@ -111,27 +111,6 @@ export class ITProject {
111
111
  `this.getSecondaryEndpointsPoints("web")`,
112
112
  this.getSecondaryEndpointsPoints("web")
113
113
  );
114
- // console.log("nodeEntryPoints", nodeEntryPoints);
115
- // console.log("webEntryPoints", webEntryPoints);
116
-
117
- // nodeEntryPoints.forEach((nep) => {
118
- // const f = `${process.cwd()}/${nep}`;
119
- // console.log("nep", f);
120
- // import(f).then((module) => {
121
- // return module.default.then((defaultModule) => {
122
- // console.log("defaultModule", defaultModule);
123
- // // defaultModule
124
- // // .receiveTestResourceConfig(argz)
125
- // // .then((x) => {
126
- // // console.log("then", x);
127
- // // return x;
128
- // // })
129
- // // .catch((e) => {
130
- // // console.log("catch", e);
131
- // // });
132
- // });
133
- // });
134
- // });
135
114
 
136
115
  glob(`./${this.config.outdir}/chunk-*.mjs`, {
137
116
  ignore: "node_modules/**",