testeranto 0.134.0 → 0.140.0
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/.aider.chat.history.md +14577 -0
- package/.aider.input.history +566 -0
- package/.aider.tags.cache.v3/{8d/fa/12860238755bcfab9af8a93c52ab.val → bd/91/b71f967fd074cf4b757081b429b7.val} +0 -0
- package/.aider.tags.cache.v3/cache.db +0 -0
- package/.aider.tags.cache.v3/{18/8b/7dfca822129dad10b5cacadf7728.val → fb/96/b0f91c7e75e08fc5a6907633cf99.val} +0 -0
- package/README.md +29 -423
- package/bundle.js +1 -1
- package/dist/common/src/CoreTypes.js +2 -0
- package/dist/common/src/Init.js +4 -1
- package/dist/common/src/Node.js +1 -1
- package/dist/common/src/PM/PM_WithEslintAndTsc.js +10 -8
- package/dist/common/src/PM/__tests__/nodeSidecar.testeranto.js +2 -2
- package/dist/common/src/PM/main.js +12 -7
- package/dist/common/src/PM/node.js +10 -3
- package/dist/common/src/Web.js +2 -2
- package/dist/common/src/build.js +7 -72
- package/dist/common/src/defaultConfig.js +0 -1
- package/dist/common/src/esbuildConfigs/eslint-formatter-testeranto.js +16 -1
- package/dist/common/src/esbuildConfigs/node.js +2 -16
- package/dist/common/src/esbuildConfigs/pure.js +2 -16
- package/dist/common/src/esbuildConfigs/rebuildPlugin.js +22 -0
- package/dist/common/src/esbuildConfigs/web.js +2 -16
- package/dist/common/src/lib/abstractBase.js +8 -1
- package/dist/common/src/lib/basebuilder.js +4 -0
- package/dist/common/src/lib/classBuilder.js +2 -3
- package/dist/common/src/lib/core.js +2 -0
- package/dist/common/src/run.js +1 -1
- package/dist/common/src/utils/buildTemplates.js +88 -0
- package/dist/common/tsconfig.common.tsbuildinfo +1 -1
- package/dist/module/src/Init.js +4 -1
- package/dist/module/src/Node.js +1 -1
- package/dist/module/src/PM/PM_WithEslintAndTsc.js +10 -8
- package/dist/module/src/PM/__tests__/nodeSidecar.testeranto.js +2 -2
- package/dist/module/src/PM/main.js +12 -7
- package/dist/module/src/PM/node.js +10 -3
- package/dist/module/src/Project.js +41 -47
- package/dist/module/src/TestReport.js +34 -31
- package/dist/module/src/Web.js +2 -2
- package/dist/module/src/build.js +7 -72
- package/dist/module/src/defaultConfig.js +0 -1
- package/dist/module/src/esbuildConfigs/eslint-formatter-testeranto.js +16 -1
- package/dist/module/src/esbuildConfigs/node.js +2 -16
- package/dist/module/src/esbuildConfigs/pure.js +2 -16
- package/dist/module/src/esbuildConfigs/rebuildPlugin.js +17 -0
- package/dist/module/src/esbuildConfigs/web.js +2 -16
- package/dist/module/src/lib/abstractBase.js +8 -1
- package/dist/module/src/lib/basebuilder.js +4 -0
- package/dist/module/src/lib/classBuilder.js +2 -3
- package/dist/module/src/lib/core.js +2 -0
- package/dist/module/src/run.js +1 -1
- package/dist/module/src/utils/buildTemplates.js +82 -0
- package/dist/module/tsconfig.module.tsbuildinfo +1 -1
- package/dist/prebuild/Project.js +77 -29
- package/dist/prebuild/TestReport.js +51 -32
- package/dist/prebuild/build.mjs +132 -131
- package/dist/prebuild/esbuildConfigs/eslint-formatter-testeranto.mjs +14 -1
- package/dist/prebuild/init-docs.mjs +0 -4
- package/dist/prebuild/run.mjs +50 -31
- package/dist/tsconfig.tsbuildinfo +1 -0
- package/dist/types/src/CoreTypes.d.ts +53 -0
- package/dist/types/src/Node.d.ts +3 -3
- package/dist/types/src/PM/__tests__/nodeSidecar.testeranto.d.ts +2 -4
- package/dist/types/src/PM/__tests__/pureSidecar.testeranto.d.ts +2 -4
- package/dist/types/src/PM/__tests__/webSidecar.testeranto.d.ts +2 -4
- package/dist/types/src/PM/index.d.ts +1 -1
- package/dist/types/src/PM/nodeSidecar.d.ts +2 -2
- package/dist/types/src/Pure.d.ts +3 -3
- package/dist/types/src/Types.d.ts +21 -61
- package/dist/types/src/Web.d.ts +3 -3
- package/dist/types/src/esbuildConfigs/rebuildPlugin.d.ts +6 -0
- package/dist/types/src/lib/abstractBase.d.ts +10 -16
- package/dist/types/src/lib/basebuilder.d.ts +3 -3
- package/dist/types/src/lib/classBuilder.d.ts +2 -2
- package/dist/types/src/lib/core.d.ts +2 -2
- package/dist/types/src/lib/index.d.ts +7 -6
- package/dist/types/src/lib/types.d.ts +8 -8
- package/dist/types/src/mothership/test.d.ts +2 -2
- package/dist/types/src/utils/buildTemplates.d.ts +3 -0
- package/dist/types/tsconfig.types.tsbuildinfo +1 -1
- package/docs/index.md +567 -0
- package/docs/style.md +116 -0
- package/docs.html +537 -0
- package/example.css +351 -0
- package/fonts/M_PLUS_Rounded_1c/MPLUSRounded1c-Black.ttf +0 -0
- package/fonts/M_PLUS_Rounded_1c/MPLUSRounded1c-Bold.ttf +0 -0
- package/fonts/M_PLUS_Rounded_1c/MPLUSRounded1c-ExtraBold.ttf +0 -0
- package/fonts/M_PLUS_Rounded_1c/MPLUSRounded1c-Light.ttf +0 -0
- package/fonts/M_PLUS_Rounded_1c/MPLUSRounded1c-Medium.ttf +0 -0
- package/fonts/M_PLUS_Rounded_1c/MPLUSRounded1c-Regular.ttf +0 -0
- package/fonts/M_PLUS_Rounded_1c/MPLUSRounded1c-Thin.ttf +0 -0
- package/fonts/M_PLUS_Rounded_1c/OFL.txt +91 -0
- package/index.html +245 -24
- package/logo.svg +72 -0
- package/package.json +11 -2
- package/scripts/compile-docs.js +89 -0
- package/src/CoreTypes.ts +152 -0
- package/src/Init.ts +4 -4
- package/src/Node.ts +13 -13
- package/src/PM/PM_WithEslintAndTsc.ts +46 -15
- package/src/PM/__tests__/nodeSidecar.testeranto.ts +13 -20
- package/src/PM/__tests__/pureSidecar.testeranto.ts +8 -15
- package/src/PM/__tests__/webSidecar.testeranto.ts +8 -15
- package/src/PM/index.ts +1 -1
- package/src/PM/main.ts +17 -16
- package/src/PM/node.ts +10 -10
- package/src/PM/nodeSidecar.ts +2 -2
- package/src/PM/pure.ts +0 -4
- package/src/Project.tsx +289 -292
- package/src/Pure.ts +13 -14
- package/src/PureSidecar.ts +1 -0
- package/src/TestReport.tsx +179 -165
- package/src/Types.ts +52 -151
- package/src/Web.ts +15 -14
- package/src/build.ts +22 -72
- package/src/defaultConfig.ts +2 -1
- package/src/esbuildConfigs/eslint-formatter-testeranto.ts +17 -1
- package/src/esbuildConfigs/node.ts +2 -18
- package/src/esbuildConfigs/pure.ts +2 -18
- package/src/esbuildConfigs/rebuildPlugin.ts +23 -0
- package/src/esbuildConfigs/web.ts +2 -18
- package/src/lib/BaseSuite.test.ts +457 -0
- package/src/lib/BaseSuite.ts +155 -0
- package/src/lib/abstractBase.ts +13 -163
- package/src/lib/basebuilder.ts +11 -11
- package/src/lib/classBuilder.ts +13 -7
- package/src/lib/core.ts +13 -17
- package/src/lib/index.ts +21 -24
- package/src/lib/types.ts +23 -9
- package/src/mothership/test.ts +13 -10
- package/src/run.ts +1 -1
- package/src/style.css +1 -1
- package/src/utils/buildTemplates.ts +88 -0
- package/style.css +496 -0
- package/testeranto/bundles/node/{mothership/chunk-V2EQEXU2.mjs → allTests/chunk-4PJCC2XT.mjs} +66 -59
- package/testeranto/bundles/node/allTests/metafile.json +4151 -0
- package/testeranto/bundles/node/allTests/src/PM/__tests__/nodeSidecar.testeranto.mjs +187 -0
- package/testeranto/bundles/node/{mothership → allTests}/src/PM/__tests__/pureSidecar.testeranto.mjs +1 -1
- package/testeranto/bundles/node/{mothership → allTests}/src/PM/__tests__/webSidecar.testeranto.mjs +1 -1
- package/testeranto/bundles/node/allTests/src/lib/BaseSuite.test.mjs +305 -0
- package/testeranto/bundles/node/{mothership → allTests}/src/mothership/test.mjs +1 -1
- package/testeranto/dev.html +29 -0
- package/testeranto/index.html +28 -27
- package/testeranto/reports/allTests/config.json +57 -0
- package/testeranto/reports/{mothership/index.html → allTests/dev.html} +2 -0
- package/testeranto/reports/allTests/index.html +26 -0
- package/testeranto/reports/{mothership/src/PM/__tests__/sidecar.testeranto/node/index.html → allTests/src/PM/__tests__/nodeSidecar.testeranto/node/dev.html} +4 -3
- package/testeranto/reports/allTests/src/PM/__tests__/nodeSidecar.testeranto/node/index.html +21 -0
- package/testeranto/reports/allTests/src/PM/__tests__/nodeSidecar.testeranto/node/lint_errors.json +80 -0
- package/testeranto/reports/allTests/src/PM/__tests__/nodeSidecar.testeranto/node/message +1 -0
- package/testeranto/reports/allTests/src/PM/__tests__/nodeSidecar.testeranto/node/prompt.txt +8 -0
- package/testeranto/reports/allTests/src/PM/__tests__/nodeSidecar.testeranto/node/type_errors.txt +28 -0
- package/testeranto/reports/{mothership/src/PM/__tests__/webSidecar.testeranto/node/index.html → allTests/src/PM/__tests__/pureSidecar.testeranto/node/dev.html} +4 -3
- package/testeranto/reports/allTests/src/PM/__tests__/pureSidecar.testeranto/node/index.html +21 -0
- package/testeranto/reports/{mothership → allTests}/src/PM/__tests__/pureSidecar.testeranto/node/lint_errors.json +12 -12
- package/testeranto/reports/allTests/src/PM/__tests__/pureSidecar.testeranto/node/message +1 -0
- package/testeranto/reports/allTests/src/PM/__tests__/pureSidecar.testeranto/node/prompt.txt +8 -0
- package/testeranto/reports/allTests/src/PM/__tests__/pureSidecar.testeranto/node/type_errors.txt +32 -0
- package/testeranto/reports/{mothership/src/PM/__tests__/nodeSidecar.testeranto/node/index.html → allTests/src/PM/__tests__/webSidecar.testeranto/node/dev.html} +4 -3
- package/testeranto/reports/allTests/src/PM/__tests__/webSidecar.testeranto/node/index.html +21 -0
- package/testeranto/reports/{mothership → allTests}/src/PM/__tests__/webSidecar.testeranto/node/lint_errors.json +12 -12
- package/testeranto/reports/allTests/src/PM/__tests__/webSidecar.testeranto/node/message +1 -0
- package/testeranto/reports/allTests/src/PM/__tests__/webSidecar.testeranto/node/prompt.txt +8 -0
- package/testeranto/reports/allTests/src/PM/__tests__/webSidecar.testeranto/node/type_errors.txt +32 -0
- package/testeranto/reports/allTests/src/lib/BaseSuite.test/node/console_log.txt +35 -0
- package/testeranto/reports/{mothership/src/PM/__tests__/pureSidecar.testeranto/node/index.html → allTests/src/lib/BaseSuite.test/node/dev.html} +4 -3
- package/testeranto/reports/allTests/src/lib/BaseSuite.test/node/index.html +21 -0
- package/testeranto/reports/allTests/src/lib/BaseSuite.test/node/lint_errors.json +608 -0
- package/testeranto/reports/allTests/src/lib/BaseSuite.test/node/message +1 -0
- package/testeranto/reports/allTests/src/lib/BaseSuite.test/node/prompt.txt +7 -0
- package/testeranto/reports/allTests/src/lib/BaseSuite.test/node/type_errors.txt +68 -0
- package/testeranto/reports/allTests/src/mothership/test/node/dev.html +21 -0
- package/testeranto/reports/allTests/src/mothership/test/node/index.html +21 -0
- package/testeranto/reports/allTests/src/mothership/test/node/message +1 -0
- package/testeranto/reports/allTests/src/mothership/test/node/prompt.txt +8 -0
- package/testeranto/reports/allTests/src/mothership/test/node/type_errors.txt +24 -0
- package/testeranto/reports/allTests/summary.json +37 -0
- package/testeranto.config.ts +16 -26
- package/tsc.log +66 -69
- package/.aider.tags.cache.v3/cache.db-shm +0 -0
- package/.aider.tags.cache.v3/cache.db-wal +0 -0
- package/dist/common/src/SP__Polygon.test.js +0 -10
- package/dist/module/src/ReportClient.js +0 -132
- package/dist/module/src/SP__Polygon.test.js +0 -8
- package/dist/prebuild/ReportClient.js +0 -3
- package/src/ReportClient.tsx +0 -164
- package/src/SP__Polygon.test.ts +0 -13
- package/testeranto/ReportClient.css +0 -11367
- package/testeranto/ReportClient.js +0 -24641
- package/testeranto/bundles/node/mothership/metafile.json +0 -389
- package/testeranto/bundles/node/mothership/src/PM/__tests__/nodeSidecar.testeranto.mjs +0 -1219
- package/testeranto/bundles/node/mothership/src/PM/__tests__/sidecar.testeranto.mjs +0 -1199
- package/testeranto/reports/mothership/config.json +0 -25
- package/testeranto/reports/mothership/src/PM/__tests__/nodeSidecar.testeranto/node/console_log.txt +0 -0
- package/testeranto/reports/mothership/src/PM/__tests__/nodeSidecar.testeranto/node/lint_errors.json +0 -1564
- package/testeranto/reports/mothership/src/PM/__tests__/nodeSidecar.testeranto/node/prompt.txt +0 -22
- package/testeranto/reports/mothership/src/PM/__tests__/nodeSidecar.testeranto/node/type_errors.txt +0 -35
- package/testeranto/reports/mothership/src/PM/__tests__/pureSidecar.testeranto/node/prompt.txt +0 -12
- package/testeranto/reports/mothership/src/PM/__tests__/pureSidecar.testeranto/node/type_errors.txt +0 -26
- package/testeranto/reports/mothership/src/PM/__tests__/sidecar.testeranto/node/bdd_errors.txt +0 -1
- package/testeranto/reports/mothership/src/PM/__tests__/sidecar.testeranto/node/console_log.txt +0 -0
- package/testeranto/reports/mothership/src/PM/__tests__/sidecar.testeranto/node/lint_errors.json +0 -1564
- package/testeranto/reports/mothership/src/PM/__tests__/sidecar.testeranto/node/log.txt +0 -0
- package/testeranto/reports/mothership/src/PM/__tests__/sidecar.testeranto/node/prompt.txt +0 -22
- package/testeranto/reports/mothership/src/PM/__tests__/sidecar.testeranto/node/tests.json +0 -56
- package/testeranto/reports/mothership/src/PM/__tests__/sidecar.testeranto/node/type_errors.txt +0 -29
- package/testeranto/reports/mothership/src/PM/__tests__/webSidecar.testeranto/node/prompt.txt +0 -12
- package/testeranto/reports/mothership/src/PM/__tests__/webSidecar.testeranto/node/type_errors.txt +0 -26
- package/testeranto/reports/mothership/src/mothership/test/node/bdd_errors.txt +0 -1
- package/testeranto/reports/mothership/src/mothership/test/node/console_log.txt +0 -4
- package/testeranto/reports/mothership/src/mothership/test/node/index.html +0 -20
- package/testeranto/reports/mothership/src/mothership/test/node/log.txt +0 -0
- package/testeranto/reports/mothership/src/mothership/test/node/prompt.txt +0 -12
- package/testeranto/reports/mothership/src/mothership/test/node/tests.json +0 -24
- package/testeranto/reports/mothership/src/mothership/test/node/type_errors.txt +0 -18
- package/testeranto/reports/mothership/summary.json +0 -9
- /package/dist/{types/src/SP__Polygon.test.d.ts → module/src/CoreTypes.js} +0 -0
- /package/testeranto/bundles/node/{mothership → allTests}/chunk-PG6KUKNP.mjs +0 -0
- /package/testeranto/bundles/pure/{mothership → allTests}/metafile.json +0 -0
- /package/testeranto/bundles/web/{mothership → allTests}/metafile.json +0 -0
- /package/testeranto/reports/{mothership/src/PM/__tests__/nodeSidecar.testeranto → allTests/src/lib/BaseSuite.test}/node/log.txt +0 -0
- /package/testeranto/reports/{mothership → allTests}/src/mothership/test/node/lint_errors.json +0 -0
package/dist/prebuild/build.mjs
CHANGED
|
@@ -9,7 +9,7 @@ var __require = /* @__PURE__ */ ((x) => typeof require !== "undefined" ? require
|
|
|
9
9
|
|
|
10
10
|
// src/build.ts
|
|
11
11
|
import ansiC from "ansi-colors";
|
|
12
|
-
import
|
|
12
|
+
import fs3 from "fs";
|
|
13
13
|
import path4 from "path";
|
|
14
14
|
import readline from "readline";
|
|
15
15
|
import esbuild from "esbuild";
|
|
@@ -96,6 +96,28 @@ var featuresPlugin_default = {
|
|
|
96
96
|
}
|
|
97
97
|
};
|
|
98
98
|
|
|
99
|
+
// src/esbuildConfigs/rebuildPlugin.ts
|
|
100
|
+
import fs2 from "fs";
|
|
101
|
+
var rebuildPlugin_default = (r) => {
|
|
102
|
+
return {
|
|
103
|
+
name: "rebuild-notify",
|
|
104
|
+
setup: (build) => {
|
|
105
|
+
build.onStart(() => {
|
|
106
|
+
console.log(`> web build starting...`);
|
|
107
|
+
});
|
|
108
|
+
build.onEnd((result) => {
|
|
109
|
+
console.log(`> web build ended with ${result.errors.length} errors`);
|
|
110
|
+
if (result.errors.length > 0) {
|
|
111
|
+
fs2.writeFileSync(
|
|
112
|
+
`./testeranto/reports${r}_build_errors`,
|
|
113
|
+
JSON.stringify(result, null, 2)
|
|
114
|
+
);
|
|
115
|
+
}
|
|
116
|
+
});
|
|
117
|
+
}
|
|
118
|
+
};
|
|
119
|
+
};
|
|
120
|
+
|
|
99
121
|
// src/esbuildConfigs/node.ts
|
|
100
122
|
var node_default = (config, entryPoints, testName2) => {
|
|
101
123
|
const { inputFilesPluginFactory, register: register2 } = inputFilesPlugin_default(
|
|
@@ -124,22 +146,7 @@ var node_default = (config, entryPoints, testName2) => {
|
|
|
124
146
|
plugins: [
|
|
125
147
|
featuresPlugin_default,
|
|
126
148
|
inputFilesPluginFactory,
|
|
127
|
-
|
|
128
|
-
name: "rebuild-notify",
|
|
129
|
-
setup: (build) => {
|
|
130
|
-
build.onStart(() => {
|
|
131
|
-
console.log(`> node build starting...`);
|
|
132
|
-
});
|
|
133
|
-
build.onEnd((result) => {
|
|
134
|
-
console.log(
|
|
135
|
-
`> node build ended with ${result.errors.length} errors`
|
|
136
|
-
);
|
|
137
|
-
if (result.errors.length > 0) {
|
|
138
|
-
console.log(result);
|
|
139
|
-
}
|
|
140
|
-
});
|
|
141
|
-
}
|
|
142
|
-
},
|
|
149
|
+
rebuildPlugin_default("node"),
|
|
143
150
|
...config.nodePlugins.map((p) => p(register2, entryPoints)) || []
|
|
144
151
|
]
|
|
145
152
|
};
|
|
@@ -193,22 +200,7 @@ var web_default = (config, entryPoints, testName2) => {
|
|
|
193
200
|
// 'fs': false,
|
|
194
201
|
// }
|
|
195
202
|
}),
|
|
196
|
-
|
|
197
|
-
name: "rebuild-notify",
|
|
198
|
-
setup: (build) => {
|
|
199
|
-
build.onStart(() => {
|
|
200
|
-
console.log(`> web build starting...`);
|
|
201
|
-
});
|
|
202
|
-
build.onEnd((result) => {
|
|
203
|
-
console.log(
|
|
204
|
-
`> web build ended with ${result.errors.length} errors`
|
|
205
|
-
);
|
|
206
|
-
if (result.errors.length > 0) {
|
|
207
|
-
console.log(result);
|
|
208
|
-
}
|
|
209
|
-
});
|
|
210
|
-
}
|
|
211
|
-
},
|
|
203
|
+
rebuildPlugin_default("web"),
|
|
212
204
|
...(config.webPlugins || []).map((p) => p(register2, entryPoints)) || []
|
|
213
205
|
]
|
|
214
206
|
};
|
|
@@ -286,22 +278,7 @@ var pure_default = (config, entryPoints, testName2) => {
|
|
|
286
278
|
});
|
|
287
279
|
}
|
|
288
280
|
},
|
|
289
|
-
|
|
290
|
-
name: "rebuild-notify",
|
|
291
|
-
setup: (build) => {
|
|
292
|
-
build.onStart(() => {
|
|
293
|
-
console.log(`> pure build starting...`);
|
|
294
|
-
});
|
|
295
|
-
build.onEnd((result) => {
|
|
296
|
-
console.log(
|
|
297
|
-
`> pure build ended with ${result.errors.length} errors`
|
|
298
|
-
);
|
|
299
|
-
if (result.errors.length > 0) {
|
|
300
|
-
console.log(result);
|
|
301
|
-
}
|
|
302
|
-
});
|
|
303
|
-
}
|
|
304
|
-
},
|
|
281
|
+
rebuildPlugin_default("pure"),
|
|
305
282
|
...(config.nodePlugins || []).map((p) => p(register2, entryPoints)) || []
|
|
306
283
|
]
|
|
307
284
|
};
|
|
@@ -372,6 +349,90 @@ var getRunnables = (tests, projectName, payload = {
|
|
|
372
349
|
}, payload);
|
|
373
350
|
};
|
|
374
351
|
|
|
352
|
+
// src/utils/buildTemplates.ts
|
|
353
|
+
var testReportPage = (packageName, domain) => {
|
|
354
|
+
return `
|
|
355
|
+
<!DOCTYPE html>
|
|
356
|
+
<html lang="en">
|
|
357
|
+
|
|
358
|
+
<head>
|
|
359
|
+
<meta name="description" content="Webpage description goes here" />
|
|
360
|
+
<meta charset="utf-8" />
|
|
361
|
+
<title>${packageName} - testeranto</title>
|
|
362
|
+
<meta name="viewport" content="width=device-width, initial-scale=1" />
|
|
363
|
+
<meta name="author" content="" />
|
|
364
|
+
|
|
365
|
+
<base href="${domain}" target="_blank">
|
|
366
|
+
|
|
367
|
+
<link rel="stylesheet" href="../ReportClient.css" />
|
|
368
|
+
<script type="module" src="../ReportClient.js"></script>
|
|
369
|
+
|
|
370
|
+
</head>
|
|
371
|
+
|
|
372
|
+
<body>
|
|
373
|
+
<div id="root">
|
|
374
|
+
react is loading
|
|
375
|
+
</div>
|
|
376
|
+
</body>
|
|
377
|
+
|
|
378
|
+
</html>
|
|
379
|
+
`;
|
|
380
|
+
};
|
|
381
|
+
var testsReportPage = (packageName, domain, projects) => {
|
|
382
|
+
return `
|
|
383
|
+
<!DOCTYPE html>
|
|
384
|
+
<html lang="en">
|
|
385
|
+
|
|
386
|
+
<head>
|
|
387
|
+
<meta name="description" content="Webpage description goes here" />
|
|
388
|
+
<meta charset="utf-8" />
|
|
389
|
+
<title>${packageName} - testeranto</title>
|
|
390
|
+
<meta name="viewport" content="width=device-width, initial-scale=1" />
|
|
391
|
+
<meta name="author" content="" />
|
|
392
|
+
<base href="${domain}" target="_blank">
|
|
393
|
+
|
|
394
|
+
<script type="application/json" id="bigConfig">
|
|
395
|
+
${JSON.stringify(Object.keys(projects))}
|
|
396
|
+
</script>
|
|
397
|
+
|
|
398
|
+
<link rel="stylesheet" href="./testeranto/Project.css" />
|
|
399
|
+
<script type="module" src="./testeranto/Project.js"></script>
|
|
400
|
+
|
|
401
|
+
</head>
|
|
402
|
+
|
|
403
|
+
<body>
|
|
404
|
+
<div id="root">
|
|
405
|
+
react is loading
|
|
406
|
+
</div>
|
|
407
|
+
</body>
|
|
408
|
+
|
|
409
|
+
</html>
|
|
410
|
+
`;
|
|
411
|
+
};
|
|
412
|
+
var idkPage = (testName2, domain) => {
|
|
413
|
+
return `
|
|
414
|
+
<!DOCTYPE html>
|
|
415
|
+
<html lang="en">
|
|
416
|
+
|
|
417
|
+
<head>
|
|
418
|
+
<meta name="description" content="Webpage description goes here" />
|
|
419
|
+
<base href="${domain}" target="_blank">
|
|
420
|
+
<meta charset="utf-8" />
|
|
421
|
+
<title>${testName2} - testeranto</title>
|
|
422
|
+
<meta name="viewport" content="width=device-width, initial-scale=1" />
|
|
423
|
+
<meta name="author" content="" />
|
|
424
|
+
|
|
425
|
+
<link rel="stylesheet" href="./testeranto/TestReport.css" />
|
|
426
|
+
<script src="./testeranto/TestReport.js"></script>
|
|
427
|
+
|
|
428
|
+
</head>
|
|
429
|
+
|
|
430
|
+
<body>
|
|
431
|
+
<div id="root"/>
|
|
432
|
+
</body>
|
|
433
|
+
`;
|
|
434
|
+
};
|
|
435
|
+
|
|
375
436
|
// src/build.ts
|
|
376
437
|
readline.emitKeypressEvents(process.stdin);
|
|
377
438
|
if (process.stdin.isTTY)
|
|
@@ -475,70 +536,28 @@ import(process.cwd() + "/testeranto.config.ts").then(async (module) => {
|
|
|
475
536
|
}
|
|
476
537
|
};
|
|
477
538
|
console.log(`testeranto/reports/${testName}`);
|
|
478
|
-
if (!
|
|
479
|
-
|
|
539
|
+
if (!fs3.existsSync(`testeranto/reports/${testName}`)) {
|
|
540
|
+
fs3.mkdirSync(`testeranto/reports/${testName}`);
|
|
480
541
|
}
|
|
481
|
-
|
|
542
|
+
fs3.writeFileSync(
|
|
482
543
|
`${process.cwd()}/testeranto/reports/${testName}/index.html`,
|
|
483
|
-
|
|
484
|
-
|
|
485
|
-
|
|
486
|
-
|
|
487
|
-
|
|
488
|
-
<meta name="description" content="Webpage description goes here" />
|
|
489
|
-
<meta charset="utf-8" />
|
|
490
|
-
<title>${pckge.name} - testeranto</title>
|
|
491
|
-
<meta name="viewport" content="width=device-width, initial-scale=1" />
|
|
492
|
-
<meta name="author" content="" />
|
|
493
|
-
|
|
494
|
-
<link rel="stylesheet" href="../ReportClient.css" />
|
|
495
|
-
<script type="module" src="../ReportClient.js"></script>
|
|
496
|
-
|
|
497
|
-
</head>
|
|
498
|
-
|
|
499
|
-
<body>
|
|
500
|
-
<div id="root">
|
|
501
|
-
react is loading
|
|
502
|
-
</div>
|
|
503
|
-
</body>
|
|
504
|
-
|
|
505
|
-
</html>
|
|
506
|
-
`
|
|
544
|
+
testReportPage(pckge.name, bigConfig.reportDomain)
|
|
545
|
+
);
|
|
546
|
+
fs3.writeFileSync(
|
|
547
|
+
`${process.cwd()}/testeranto/reports/${testName}/dev.html`,
|
|
548
|
+
testReportPage(pckge.name, "/")
|
|
507
549
|
);
|
|
508
|
-
|
|
550
|
+
fs3.writeFileSync(
|
|
509
551
|
`testeranto/reports/${testName}/config.json`,
|
|
510
552
|
JSON.stringify(config, null, 2)
|
|
511
553
|
);
|
|
512
|
-
|
|
554
|
+
fs3.writeFileSync(
|
|
513
555
|
`${process.cwd()}/testeranto/index.html`,
|
|
514
|
-
|
|
515
|
-
|
|
516
|
-
|
|
517
|
-
|
|
518
|
-
|
|
519
|
-
<meta name="description" content="Webpage description goes here" />
|
|
520
|
-
<meta charset="utf-8" />
|
|
521
|
-
<title>${pckge.name} - testeranto</title>
|
|
522
|
-
<meta name="viewport" content="width=device-width, initial-scale=1" />
|
|
523
|
-
<meta name="author" content="" />
|
|
524
|
-
|
|
525
|
-
<script type="application/json" id="bigConfig">
|
|
526
|
-
${JSON.stringify(Object.keys(bigConfig.projects))}
|
|
527
|
-
</script>
|
|
528
|
-
|
|
529
|
-
<link rel="stylesheet" href="Project.css" />
|
|
530
|
-
<script type="module" src="Project.js"></script>
|
|
531
|
-
|
|
532
|
-
</head>
|
|
533
|
-
|
|
534
|
-
<body>
|
|
535
|
-
<div id="root">
|
|
536
|
-
react is loading
|
|
537
|
-
</div>
|
|
538
|
-
</body>
|
|
539
|
-
|
|
540
|
-
</html>
|
|
541
|
-
`
|
|
556
|
+
testsReportPage(pckge.name, bigConfig.reportDomain, bigConfig.projects)
|
|
557
|
+
);
|
|
558
|
+
fs3.writeFileSync(
|
|
559
|
+
`${process.cwd()}/testeranto/dev.html`,
|
|
560
|
+
testsReportPage(pckge.name, "/", bigConfig.projects)
|
|
542
561
|
);
|
|
543
562
|
Promise.resolve(
|
|
544
563
|
Promise.all(
|
|
@@ -553,8 +572,8 @@ import(process.cwd() + "/testeranto.config.ts").then(async (module) => {
|
|
|
553
572
|
)}/${sourceFileNameMinusJs}.html`
|
|
554
573
|
);
|
|
555
574
|
const jsfilePath = `./${sourceFileNameMinusJs}.mjs`;
|
|
556
|
-
return
|
|
557
|
-
(x2) =>
|
|
575
|
+
return fs3.promises.mkdir(path4.dirname(htmlFilePath), { recursive: true }).then(
|
|
576
|
+
(x2) => fs3.writeFileSync(
|
|
558
577
|
htmlFilePath,
|
|
559
578
|
web_html_default(jsfilePath, htmlFilePath)
|
|
560
579
|
)
|
|
@@ -583,30 +602,12 @@ import(process.cwd() + "/testeranto.config.ts").then(async (module) => {
|
|
|
583
602
|
console.log(runtime, keys);
|
|
584
603
|
keys.forEach(async (k) => {
|
|
585
604
|
const folder = `testeranto/reports/${testName}/${k.split(".").slice(0, -1).join(".")}/${runtime}`;
|
|
586
|
-
await
|
|
587
|
-
|
|
605
|
+
await fs3.mkdirSync(folder, { recursive: true });
|
|
606
|
+
fs3.writeFileSync(
|
|
588
607
|
`${folder}/index.html`,
|
|
589
|
-
|
|
590
|
-
<!DOCTYPE html>
|
|
591
|
-
<html lang="en">
|
|
592
|
-
|
|
593
|
-
<head>
|
|
594
|
-
<meta name="description" content="Webpage description goes here" />
|
|
595
|
-
<meta charset="utf-8" />
|
|
596
|
-
<title>${testName} - testeranto</title>
|
|
597
|
-
<meta name="viewport" content="width=device-width, initial-scale=1" />
|
|
598
|
-
<meta name="author" content="" />
|
|
599
|
-
|
|
600
|
-
<link rel="stylesheet" href="../../../../../../TestReport.css" />
|
|
601
|
-
<script src="../../../../../../TestReport.js"></script>
|
|
602
|
-
|
|
603
|
-
</head>
|
|
604
|
-
|
|
605
|
-
<body>
|
|
606
|
-
<div id="root"/>
|
|
607
|
-
</body>
|
|
608
|
-
`
|
|
608
|
+
idkPage(testName, bigConfig.reportDomain)
|
|
609
609
|
);
|
|
610
|
+
fs3.writeFileSync(`${folder}/dev.html`, idkPage(testName, ""));
|
|
610
611
|
});
|
|
611
612
|
});
|
|
612
613
|
[
|
|
@@ -623,7 +624,7 @@ import(process.cwd() + "/testeranto.config.ts").then(async (module) => {
|
|
|
623
624
|
ep.split(".").slice(0, -1).join("."),
|
|
624
625
|
runtime
|
|
625
626
|
);
|
|
626
|
-
|
|
627
|
+
fs3.mkdirSync(fp, { recursive: true });
|
|
627
628
|
});
|
|
628
629
|
}
|
|
629
630
|
);
|
|
@@ -2,7 +2,20 @@ import { createRequire } from 'module';const require = createRequire(import.meta
|
|
|
2
2
|
|
|
3
3
|
// src/esbuildConfigs/eslint-formatter-testeranto.ts
|
|
4
4
|
function eslint_formatter_testeranto_default(results) {
|
|
5
|
-
return
|
|
5
|
+
return results.filter((r) => r.messages.length).map((r) => {
|
|
6
|
+
const path = r.filePath.replace(process.cwd() + "/", "");
|
|
7
|
+
return [
|
|
8
|
+
path,
|
|
9
|
+
...r.messages.map(
|
|
10
|
+
(m) => [
|
|
11
|
+
`${m.line}:${m.column} ${m.message} (${m.ruleId || ""})`,
|
|
12
|
+
...m.suggestions?.map(
|
|
13
|
+
(s) => `- ${s.message}${s.fix ? " (fix)" : ""}`
|
|
14
|
+
) || []
|
|
15
|
+
].join("\n")
|
|
16
|
+
)
|
|
17
|
+
].join("\n");
|
|
18
|
+
}).join("\n\n");
|
|
6
19
|
}
|
|
7
20
|
export {
|
|
8
21
|
eslint_formatter_testeranto_default as default
|
|
@@ -23,10 +23,6 @@ var Init_default = async () => {
|
|
|
23
23
|
`node_modules/testeranto/dist/prebuild/Project.js`,
|
|
24
24
|
`testeranto/Project.js`
|
|
25
25
|
);
|
|
26
|
-
fs.copyFileSync(
|
|
27
|
-
`node_modules/testeranto/dist/prebuild/ReportClient.js`,
|
|
28
|
-
`testeranto/ReportClient.js`
|
|
29
|
-
);
|
|
30
26
|
fs.copyFileSync(
|
|
31
27
|
`node_modules/testeranto/dist/prebuild/Project.css`,
|
|
32
28
|
`testeranto/Project.css`
|
package/dist/prebuild/run.mjs
CHANGED
|
@@ -464,8 +464,8 @@ var PM_WithEslintAndTsc = class extends PM_Base {
|
|
|
464
464
|
"testeranto",
|
|
465
465
|
"reports",
|
|
466
466
|
this.name,
|
|
467
|
-
platform,
|
|
468
467
|
entryPoint.split(".").slice(0, -1).join("."),
|
|
468
|
+
platform,
|
|
469
469
|
`tests.json`
|
|
470
470
|
);
|
|
471
471
|
const featuresPath = path3.join(
|
|
@@ -476,6 +476,38 @@ var PM_WithEslintAndTsc = class extends PM_Base {
|
|
|
476
476
|
entryPoint.split(".").slice(0, -1).join("."),
|
|
477
477
|
`featurePrompt.txt`
|
|
478
478
|
);
|
|
479
|
+
const logPath = path3.join(
|
|
480
|
+
"testeranto",
|
|
481
|
+
"reports",
|
|
482
|
+
this.name,
|
|
483
|
+
entryPoint.split(".").slice(0, -1).join("."),
|
|
484
|
+
platform,
|
|
485
|
+
`console_log.txt`
|
|
486
|
+
);
|
|
487
|
+
const lintPath = path3.join(
|
|
488
|
+
"testeranto",
|
|
489
|
+
"reports",
|
|
490
|
+
this.name,
|
|
491
|
+
entryPoint.split(".").slice(0, -1).join("."),
|
|
492
|
+
platform,
|
|
493
|
+
`lint_errors.json`
|
|
494
|
+
);
|
|
495
|
+
const typePath = path3.join(
|
|
496
|
+
"testeranto",
|
|
497
|
+
"reports",
|
|
498
|
+
this.name,
|
|
499
|
+
entryPoint.split(".").slice(0, -1).join("."),
|
|
500
|
+
platform,
|
|
501
|
+
`type_errors.txt`
|
|
502
|
+
);
|
|
503
|
+
const messagePath = path3.join(
|
|
504
|
+
"testeranto",
|
|
505
|
+
"reports",
|
|
506
|
+
this.name,
|
|
507
|
+
entryPoint.split(".").slice(0, -1).join("."),
|
|
508
|
+
platform,
|
|
509
|
+
`message`
|
|
510
|
+
);
|
|
479
511
|
fs2.writeFileSync(
|
|
480
512
|
promptPath,
|
|
481
513
|
`
|
|
@@ -483,22 +515,15 @@ ${addableFiles.map((x) => {
|
|
|
483
515
|
return `/add ${x}`;
|
|
484
516
|
}).join("\n")}
|
|
485
517
|
|
|
486
|
-
/read ${lintPather(entryPoint, platform, this.name)}
|
|
487
|
-
/read ${tscPather(entryPoint, platform, this.name)}
|
|
488
518
|
/read ${testPaths}
|
|
489
|
-
|
|
490
|
-
/
|
|
491
|
-
|
|
492
|
-
|
|
493
|
-
|
|
494
|
-
|
|
495
|
-
|
|
496
|
-
|
|
497
|
-
entryPoint,
|
|
498
|
-
platform,
|
|
499
|
-
this.name
|
|
500
|
-
)}"
|
|
501
|
-
`
|
|
519
|
+
/read ${logPath}
|
|
520
|
+
/read ${typePath}
|
|
521
|
+
/read ${lintPath}
|
|
522
|
+
`
|
|
523
|
+
);
|
|
524
|
+
fs2.writeFileSync(
|
|
525
|
+
messagePath,
|
|
526
|
+
`Fix the failing tests described in ${testPaths} and ${logPath}. DO NOT refactor beyond what is necessary. Always prefer minimal changes, focusing mostly on keeping the BDD tests passing`
|
|
502
527
|
);
|
|
503
528
|
this.summary[entryPoint].prompt = `aider --model deepseek/deepseek-chat --load testeranto/${this.name}/reports/${platform}/${entryPoint.split(".").slice(0, -1).join(".")}/prompt.txt`;
|
|
504
529
|
this.checkForShutdown();
|
|
@@ -829,9 +854,14 @@ var PM_Main = class extends PM_WithEslintAndTsc {
|
|
|
829
854
|
const builtfile = dest;
|
|
830
855
|
let haltReturns = false;
|
|
831
856
|
const ipcfile = "/tmp/tpipe_" + Math.random();
|
|
832
|
-
const child = spawn(
|
|
833
|
-
|
|
834
|
-
|
|
857
|
+
const child = spawn(
|
|
858
|
+
"node",
|
|
859
|
+
// "node --inspect-brk ",
|
|
860
|
+
[builtfile, testResources, ipcfile],
|
|
861
|
+
{
|
|
862
|
+
stdio: ["pipe", "pipe", "pipe", "ipc"]
|
|
863
|
+
}
|
|
864
|
+
);
|
|
835
865
|
let buffer = new Buffer("");
|
|
836
866
|
const server = net.createServer((socket) => {
|
|
837
867
|
const queue = new Queue();
|
|
@@ -882,7 +912,6 @@ var PM_Main = class extends PM_WithEslintAndTsc {
|
|
|
882
912
|
oStream.write(`stdout > ${data}`);
|
|
883
913
|
});
|
|
884
914
|
child.on("close", (code) => {
|
|
885
|
-
console.log("close");
|
|
886
915
|
oStream.close();
|
|
887
916
|
server.close();
|
|
888
917
|
if (code === null) {
|
|
@@ -898,14 +927,12 @@ var PM_Main = class extends PM_WithEslintAndTsc {
|
|
|
898
927
|
haltReturns = true;
|
|
899
928
|
});
|
|
900
929
|
child.on("exit", (code) => {
|
|
901
|
-
console.log("exit");
|
|
902
930
|
haltReturns = true;
|
|
903
931
|
for (let i = 0; i <= portsToUse.length; i++) {
|
|
904
932
|
if (portsToUse[i]) {
|
|
905
933
|
this.ports[portsToUse[i]] = true;
|
|
906
934
|
}
|
|
907
935
|
}
|
|
908
|
-
console.log("exitthis.ports", this.ports);
|
|
909
936
|
});
|
|
910
937
|
child.on("error", (e) => {
|
|
911
938
|
console.log("error");
|
|
@@ -940,10 +967,6 @@ var PM_Main = class extends PM_WithEslintAndTsc {
|
|
|
940
967
|
if (!files2[src]) {
|
|
941
968
|
files2[src] = /* @__PURE__ */ new Set();
|
|
942
969
|
}
|
|
943
|
-
fs3.writeFileSync(
|
|
944
|
-
destFolder + "/manifest.json",
|
|
945
|
-
JSON.stringify(Array.from(files2[src]))
|
|
946
|
-
);
|
|
947
970
|
delete files2[src];
|
|
948
971
|
Promise.all(screenshots2[src] || []).then(() => {
|
|
949
972
|
delete screenshots2[src];
|
|
@@ -1234,10 +1257,6 @@ var PM_Main = class extends PM_WithEslintAndTsc {
|
|
|
1234
1257
|
if (!files2[src]) {
|
|
1235
1258
|
files2[src] = /* @__PURE__ */ new Set();
|
|
1236
1259
|
}
|
|
1237
|
-
fs3.writeFileSync(
|
|
1238
|
-
destFolder + "/manifest.json",
|
|
1239
|
-
JSON.stringify(Array.from(files2[src]))
|
|
1240
|
-
);
|
|
1241
1260
|
delete files2[src];
|
|
1242
1261
|
Promise.all(screenshots2[src] || []).then(() => {
|
|
1243
1262
|
delete screenshots2[src];
|
|
@@ -1433,7 +1452,7 @@ var PM_Main = class extends PM_WithEslintAndTsc {
|
|
|
1433
1452
|
slowMo: 1,
|
|
1434
1453
|
waitForInitialPage: false,
|
|
1435
1454
|
executablePath,
|
|
1436
|
-
headless:
|
|
1455
|
+
headless: true,
|
|
1437
1456
|
dumpio: false,
|
|
1438
1457
|
devtools: false,
|
|
1439
1458
|
args: [
|