testeranto 0.94.0 → 0.110.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/README.md +1 -0
- package/bundle.js +80 -33
- package/dist/common/{src/Init.js → Init.js} +28 -0
- package/dist/common/{src/PM → PM}/main.js +272 -111
- package/dist/common/{src/PM → PM}/node.js +20 -5
- package/dist/common/{src/PM → PM}/web.js +19 -4
- package/dist/common/ReportServer.js +22 -0
- package/dist/common/{src/SubPackages → SubPackages}/react/jsx/index.js +0 -12
- package/dist/common/{src/SubPackages → SubPackages}/react/jsx/node.js +1 -6
- package/dist/common/{src/SubPackages → SubPackages}/react-dom/component/node.js +3 -16
- package/dist/common/{src/SubPackages → SubPackages}/react-dom/component/web.js +3 -3
- package/dist/common/{src/SubPackages → SubPackages}/react-dom/jsx/node.js +1 -1
- package/dist/common/{src/SubPackages → SubPackages}/react-dom/jsx/web.js +41 -30
- package/dist/common/{src/SubPackages → SubPackages}/react-test-renderer/MemoExoticComponent/node.js +17 -7
- package/dist/common/{src/SubPackages → SubPackages}/react-test-renderer/component/interface.js +17 -7
- package/dist/common/{src/SubPackages → SubPackages}/react-test-renderer/fc/node.js +17 -7
- package/dist/common/{src/SubPackages → SubPackages}/react-test-renderer/fc/web.js +17 -7
- package/dist/common/{src/SubPackages → SubPackages}/react-test-renderer/jsx/index.js +18 -14
- package/dist/common/{src/SubPackages → SubPackages}/react-test-renderer/jsx-promised/index.js +17 -7
- package/dist/common/build.js +222 -0
- package/dist/common/{src/defaultConfig.js → defaultConfig.js} +1 -0
- package/dist/common/esbuildConfigs/eslint-formatter-testeranto.js +6 -0
- package/dist/common/esbuildConfigs/inputFilesPlugin.js +27 -0
- package/dist/common/{src/esbuildConfigs → esbuildConfigs}/node.js +3 -14
- package/dist/common/{src/esbuildConfigs → esbuildConfigs}/web.js +3 -14
- package/dist/common/{src/init-docs.js → init-docs.js} +20 -10
- package/dist/common/{src/lib → lib}/abstractBase.js +20 -92
- package/dist/common/{src/lib → lib}/basebuilder.js +23 -10
- package/dist/common/{src/lib → lib}/classBuilder.js +1 -3
- package/dist/common/{src/lib → lib}/core.js +26 -10
- package/dist/common/{src/lib → lib}/index.js +0 -1
- package/dist/common/run.js +297 -0
- package/dist/common/tsconfig.common.tsbuildinfo +1 -1
- package/dist/common/utils.js +43 -0
- package/dist/module/Footer.js +4 -0
- package/dist/module/Init.js +63 -0
- package/dist/module/{src/PM → PM}/main.js +253 -102
- package/dist/module/{src/PM → PM}/node.js +20 -5
- package/dist/module/{src/PM → PM}/web.js +19 -4
- package/dist/module/ReportClient.js +97 -0
- package/dist/module/ReportServer.js +17 -0
- package/dist/module/SubPackages/react/jsx/index.js +15 -0
- package/dist/module/{src/SubPackages → SubPackages}/react/jsx/node.js +1 -6
- package/dist/module/{src/SubPackages → SubPackages}/react-dom/component/node.js +3 -16
- package/dist/module/{src/SubPackages → SubPackages}/react-dom/component/web.js +3 -3
- package/dist/module/{src/SubPackages → SubPackages}/react-dom/jsx/node.js +3 -3
- package/dist/module/{src/SubPackages → SubPackages}/react-dom/jsx/web.js +24 -23
- package/dist/module/{src/SubPackages → SubPackages}/react-test-renderer/jsx/index.js +1 -7
- package/dist/module/TestReport.js +91 -0
- package/dist/module/build.js +184 -0
- package/dist/module/{src/defaultConfig.js → defaultConfig.js} +1 -0
- package/dist/module/esbuildConfigs/eslint-formatter-testeranto.js +3 -0
- package/dist/module/esbuildConfigs/inputFilesPlugin.js +22 -0
- package/dist/module/{src/esbuildConfigs → esbuildConfigs}/node.js +3 -14
- package/dist/module/{src/esbuildConfigs → esbuildConfigs}/web.js +3 -14
- package/dist/module/{src/init-docs.js → init-docs.js} +1 -1
- package/dist/module/{src/lib → lib}/abstractBase.js +20 -92
- package/dist/module/{src/lib → lib}/basebuilder.js +23 -10
- package/dist/module/{src/lib → lib}/classBuilder.js +1 -3
- package/dist/module/{src/lib → lib}/core.js +26 -10
- package/dist/module/{src/lib → lib}/index.js +0 -1
- package/dist/module/run.js +259 -0
- package/dist/module/tsconfig.module.tsbuildinfo +1 -1
- package/dist/module/utils.js +29 -0
- package/dist/prebuild/ReportClient.css +11367 -0
- package/dist/prebuild/ReportClient.js +23641 -0
- package/dist/prebuild/ReportServer.mjs +16 -0
- package/dist/prebuild/TestReport.css +11367 -0
- package/dist/prebuild/TestReport.js +27484 -0
- package/dist/prebuild/build.mjs +376 -0
- package/dist/prebuild/esbuildConfigs/eslint-formatter-testeranto.mjs +9 -0
- package/dist/prebuild/init-docs.mjs +64 -8
- package/dist/prebuild/{run-tests.mjs → run.mjs} +501 -182
- package/dist/tsconfig.tsbuildinfo +1 -0
- package/dist/types/Node.d.ts +12 -0
- package/dist/types/{src/PM → PM}/index.d.ts +11 -3
- package/dist/types/{src/PM → PM}/main.d.ts +24 -15
- package/dist/types/{src/PM → PM}/node.d.ts +11 -6
- package/dist/types/{src/PM → PM}/web.d.ts +11 -7
- package/dist/types/SubPackages/react/component/node.d.ts +7 -0
- package/dist/types/SubPackages/react/component/web.d.ts +7 -0
- package/dist/types/SubPackages/react/jsx/index.d.ts +12 -0
- package/dist/types/SubPackages/react/jsx/node.d.ts +4 -0
- package/dist/types/SubPackages/react/jsx/web.d.ts +4 -0
- package/dist/types/SubPackages/react-dom/component/node.d.ts +11 -0
- package/dist/types/SubPackages/react-dom/component/web.d.ts +20 -0
- package/dist/types/SubPackages/react-dom/jsx/index.d.ts +6 -0
- package/dist/types/SubPackages/react-dom/jsx/node.d.ts +7 -0
- package/dist/types/SubPackages/react-dom/jsx/web.d.ts +5 -0
- package/dist/types/SubPackages/react-test-renderer/MemoExoticComponent/node.d.ts +6 -0
- package/dist/types/SubPackages/react-test-renderer/component/index.d.ts +13 -0
- package/dist/types/SubPackages/react-test-renderer/component/node.d.ts +4 -0
- package/dist/types/SubPackages/react-test-renderer/component/web.d.ts +4 -0
- package/dist/types/SubPackages/react-test-renderer/fc/node.d.ts +8 -0
- package/dist/types/SubPackages/react-test-renderer/fc/web.d.ts +9 -0
- package/dist/types/SubPackages/react-test-renderer/jsx/index.d.ts +16 -0
- package/dist/types/SubPackages/react-test-renderer/jsx/node.d.ts +9 -0
- package/dist/types/SubPackages/react-test-renderer/jsx/web.d.ts +9 -0
- package/dist/types/SubPackages/react-test-renderer/jsx-promised/index.d.ts +15 -0
- package/dist/types/SubPackages/react-test-renderer/jsx-promised/node.d.ts +5 -0
- package/dist/types/SubPackages/react-test-renderer/jsx-promised/web.d.ts +5 -0
- package/dist/types/Types.d.ts +61 -0
- package/dist/types/Web.d.ts +9 -0
- package/dist/types/defaultConfig.d.ts +3 -0
- package/dist/types/esbuildConfigs/eslint-formatter-testeranto.d.ts +2 -0
- package/dist/types/{src/esbuildConfigs → esbuildConfigs}/index.d.ts +1 -1
- package/dist/types/{src/esbuildConfigs → esbuildConfigs}/inputFilesPlugin.d.ts +0 -1
- package/dist/types/{src/esbuildConfigs → esbuildConfigs}/node.d.ts +1 -1
- package/dist/types/{src/esbuildConfigs → esbuildConfigs}/web.d.ts +1 -1
- package/dist/types/lib/abstractBase.d.ts +110 -0
- package/dist/types/lib/basebuilder.d.ts +27 -0
- package/dist/types/lib/classBuilder.d.ts +7 -0
- package/dist/types/lib/core.d.ts +7 -0
- package/dist/types/lib/index.d.ts +83 -0
- package/dist/types/lib/types.d.ts +14 -0
- package/dist/types/run.d.ts +1 -0
- package/dist/types/tsconfig.types.tsbuildinfo +1 -1
- package/dist/types/utils.d.ts +9 -0
- package/package.json +50 -39
- package/src/Footer.tsx +4 -0
- package/src/Init.ts +48 -0
- package/src/Node.ts +23 -17
- package/src/PM/index.ts +13 -9
- package/src/PM/main.ts +337 -139
- package/src/PM/node.ts +43 -8
- package/src/PM/web.ts +34 -6
- package/src/ReportClient.tsx +155 -0
- package/src/ReportServer.ts +21 -0
- package/src/SubPackages/react/component/node.ts +68 -24
- package/src/SubPackages/react/component/web.ts +68 -25
- package/src/SubPackages/react/jsx/index.ts +39 -18
- package/src/SubPackages/react/jsx/node.ts +23 -10
- package/src/SubPackages/react/jsx/web.ts +27 -14
- package/src/SubPackages/react-dom/component/node.ts +42 -50
- package/src/SubPackages/react-dom/component/web.ts +28 -10
- package/src/SubPackages/react-dom/jsx/node.ts +54 -56
- package/src/SubPackages/react-dom/jsx/web.ts +55 -42
- package/src/SubPackages/react-test-renderer/MemoExoticComponent/node.ts +23 -7
- package/src/SubPackages/react-test-renderer/component/index.ts +38 -5
- package/src/SubPackages/react-test-renderer/component/node.ts +24 -5
- package/src/SubPackages/react-test-renderer/component/web.ts +22 -5
- package/src/SubPackages/react-test-renderer/fc/node.ts +41 -7
- package/src/SubPackages/react-test-renderer/fc/web.ts +43 -11
- package/src/SubPackages/react-test-renderer/jsx/index.ts +39 -16
- package/src/SubPackages/react-test-renderer/jsx/node.ts +22 -5
- package/src/SubPackages/react-test-renderer/jsx/web.ts +22 -5
- package/src/SubPackages/react-test-renderer/jsx-promised/index.ts +39 -6
- package/src/SubPackages/react-test-renderer/jsx-promised/node.ts +27 -10
- package/src/SubPackages/react-test-renderer/jsx-promised/web.ts +26 -12
- package/src/TestReport.tsx +176 -0
- package/src/Types.ts +131 -129
- package/src/Web.ts +24 -18
- package/src/build.ts +240 -0
- package/src/defaultConfig.ts +2 -1
- package/src/esbuildConfigs/eslint-formatter-testeranto.ts +5 -0
- package/src/esbuildConfigs/featuresPlugin.ts +0 -1
- package/src/esbuildConfigs/index.ts +1 -1
- package/src/esbuildConfigs/inputFilesPlugin.ts +2 -114
- package/src/esbuildConfigs/node.ts +7 -19
- package/src/esbuildConfigs/web.ts +6 -21
- package/src/init-docs.ts +2 -1
- package/src/lib/abstractBase.ts +140 -195
- package/src/lib/basebuilder.ts +57 -45
- package/src/lib/classBuilder.ts +15 -15
- package/src/lib/core.ts +44 -35
- package/src/lib/index.ts +47 -98
- package/src/lib/readme.md +12 -0
- package/src/lib/types.ts +40 -231
- package/src/run.ts +398 -0
- package/src/style.css +8 -0
- package/src/utils.ts +74 -2
- package/tsc.log +106 -0
- package/Bundle.Dockerfile +0 -52
- package/bin/init-docs.js +0 -24
- package/dist/common/dist/module/src/Init.js +0 -40
- package/dist/common/src/Aider.js +0 -143
- package/dist/common/src/Project.js +0 -227
- package/dist/common/src/Puppeteer.js +0 -111
- package/dist/common/src/SubPackages/puppeteer.js +0 -21
- package/dist/common/src/build-tests.js +0 -39
- package/dist/common/src/esbuildConfigs/features.js +0 -14
- package/dist/common/src/esbuildConfigs/inputFilesPlugin.js +0 -87
- package/dist/common/src/esbuildConfigs/report.js +0 -14
- package/dist/common/src/esbuildConfigs/tests.js +0 -13
- package/dist/common/src/run-tests.js +0 -39
- package/dist/common/src/utils.js +0 -16
- package/dist/common/testeranto.js +0 -15
- package/dist/module/src/Aider.js +0 -136
- package/dist/module/src/Init.js +0 -35
- package/dist/module/src/Project.js +0 -220
- package/dist/module/src/Puppeteer.js +0 -106
- package/dist/module/src/SubPackages/puppeteer.js +0 -16
- package/dist/module/src/SubPackages/react/jsx/index.js +0 -27
- package/dist/module/src/build-tests.js +0 -11
- package/dist/module/src/esbuildConfigs/features.js +0 -12
- package/dist/module/src/esbuildConfigs/inputFilesPlugin.js +0 -82
- package/dist/module/src/esbuildConfigs/report.js +0 -14
- package/dist/module/src/esbuildConfigs/tests.js +0 -11
- package/dist/module/src/run-tests.js +0 -11
- package/dist/module/src/utils.js +0 -9
- package/dist/module/testeranto.js +0 -13
- package/dist/prebuild/build-tests.mjs +0 -553
- package/dist/types/dist/module/src/Init.d.ts +0 -2
- package/dist/types/src/Aider.d.ts +0 -1
- package/dist/types/src/Node.d.ts +0 -13
- package/dist/types/src/Project.d.ts +0 -12
- package/dist/types/src/Puppeteer.d.ts +0 -2
- package/dist/types/src/SubPackages/puppeteer.d.ts +0 -6
- package/dist/types/src/SubPackages/react/component/node.d.ts +0 -7
- package/dist/types/src/SubPackages/react/component/web.d.ts +0 -7
- package/dist/types/src/SubPackages/react/jsx/index.d.ts +0 -12
- package/dist/types/src/SubPackages/react/jsx/node.d.ts +0 -4
- package/dist/types/src/SubPackages/react/jsx/web.d.ts +0 -4
- package/dist/types/src/SubPackages/react-dom/component/node.d.ts +0 -12
- package/dist/types/src/SubPackages/react-dom/component/web.d.ts +0 -11
- package/dist/types/src/SubPackages/react-dom/jsx/index.d.ts +0 -7
- package/dist/types/src/SubPackages/react-dom/jsx/node.d.ts +0 -6
- package/dist/types/src/SubPackages/react-dom/jsx/web.d.ts +0 -5
- package/dist/types/src/SubPackages/react-test-renderer/MemoExoticComponent/node.d.ts +0 -5
- package/dist/types/src/SubPackages/react-test-renderer/component/index.d.ts +0 -13
- package/dist/types/src/SubPackages/react-test-renderer/component/node.d.ts +0 -8
- package/dist/types/src/SubPackages/react-test-renderer/component/web.d.ts +0 -3
- package/dist/types/src/SubPackages/react-test-renderer/fc/node.d.ts +0 -8
- package/dist/types/src/SubPackages/react-test-renderer/fc/web.d.ts +0 -8
- package/dist/types/src/SubPackages/react-test-renderer/jsx/index.d.ts +0 -17
- package/dist/types/src/SubPackages/react-test-renderer/jsx/node.d.ts +0 -8
- package/dist/types/src/SubPackages/react-test-renderer/jsx/web.d.ts +0 -8
- package/dist/types/src/SubPackages/react-test-renderer/jsx-promised/index.d.ts +0 -16
- package/dist/types/src/SubPackages/react-test-renderer/jsx-promised/node.d.ts +0 -4
- package/dist/types/src/SubPackages/react-test-renderer/jsx-promised/web.d.ts +0 -4
- package/dist/types/src/Types.d.ts +0 -51
- package/dist/types/src/Web.d.ts +0 -10
- package/dist/types/src/defaultConfig.d.ts +0 -3
- package/dist/types/src/esbuildConfigs/features.d.ts +0 -4
- package/dist/types/src/esbuildConfigs/report.d.ts +0 -0
- package/dist/types/src/esbuildConfigs/tests.d.ts +0 -4
- package/dist/types/src/lib/abstractBase.d.ts +0 -110
- package/dist/types/src/lib/basebuilder.d.ts +0 -27
- package/dist/types/src/lib/classBuilder.d.ts +0 -7
- package/dist/types/src/lib/core.d.ts +0 -8
- package/dist/types/src/lib/index.d.ts +0 -60
- package/dist/types/src/lib/types.d.ts +0 -68
- package/dist/types/src/utils.d.ts +0 -2
- package/dist/types/testeranto.d.ts +0 -16
- package/docker-compose.yml +0 -37
- package/src/Aider.ts +0 -168
- package/src/Project.ts +0 -292
- package/src/Puppeteer.ts +0 -143
- package/src/SubPackages/puppeteer.ts +0 -51
- package/src/build-tests.ts +0 -12
- package/src/esbuildConfigs/features.ts +0 -17
- package/src/esbuildConfigs/report.ts +0 -15
- package/src/esbuildConfigs/tests.ts +0 -14
- package/src/run-tests.ts +0 -12
- package/testeranto.ts +0 -13
- package/dist/common/{src/Node.js → Node.js} +0 -0
- package/dist/common/{src/PM → PM}/index.js +0 -0
- package/dist/common/{src/SubPackages → SubPackages}/react/component/node.js +0 -0
- package/dist/common/{src/SubPackages → SubPackages}/react/component/web.js +0 -0
- package/dist/common/{src/SubPackages → SubPackages}/react/jsx/web.js +0 -0
- package/dist/common/{src/SubPackages → SubPackages}/react-dom/jsx/index.js +0 -0
- package/dist/common/{src/SubPackages → SubPackages}/react-test-renderer/component/index.js +0 -0
- package/dist/common/{src/SubPackages → SubPackages}/react-test-renderer/component/node.js +0 -0
- package/dist/common/{src/SubPackages → SubPackages}/react-test-renderer/component/web.js +0 -0
- package/dist/common/{src/SubPackages → SubPackages}/react-test-renderer/jsx/node.js +0 -0
- package/dist/common/{src/SubPackages → SubPackages}/react-test-renderer/jsx/web.js +0 -0
- package/dist/common/{src/SubPackages → SubPackages}/react-test-renderer/jsx-promised/node.js +1 -1
- package/dist/common/{src/SubPackages → SubPackages}/react-test-renderer/jsx-promised/web.js +0 -0
- package/dist/common/{src/Types.js → Types.js} +0 -0
- package/dist/common/{src/Web.js → Web.js} +0 -0
- package/dist/common/{src/esbuildConfigs → esbuildConfigs}/featuresPlugin.js +0 -0
- package/dist/common/{src/esbuildConfigs → esbuildConfigs}/index.js +0 -0
- package/dist/common/{src/lib → lib}/types.js +0 -0
- package/dist/common/{src/puppeteerConfiger.js → puppeteerConfiger.js} +0 -0
- package/dist/common/{src/web.html.js → web.html.js} +0 -0
- package/dist/module/{src/Node.js → Node.js} +0 -0
- package/dist/module/{src/PM → PM}/index.js +0 -0
- package/dist/module/{src/SubPackages → SubPackages}/react/component/node.js +0 -0
- package/dist/module/{src/SubPackages → SubPackages}/react/component/web.js +0 -0
- package/dist/module/{src/SubPackages → SubPackages}/react/jsx/web.js +0 -0
- package/dist/module/{src/SubPackages → SubPackages}/react-dom/jsx/index.js +0 -0
- package/dist/module/{src/SubPackages → SubPackages}/react-test-renderer/MemoExoticComponent/node.js +0 -0
- package/dist/module/{src/SubPackages → SubPackages}/react-test-renderer/component/index.js +0 -0
- package/dist/module/{src/SubPackages → SubPackages}/react-test-renderer/component/interface.js +0 -0
- package/dist/module/{src/SubPackages → SubPackages}/react-test-renderer/component/node.js +0 -0
- package/dist/module/{src/SubPackages → SubPackages}/react-test-renderer/component/web.js +0 -0
- package/dist/module/{src/SubPackages → SubPackages}/react-test-renderer/fc/node.js +0 -0
- package/dist/module/{src/SubPackages → SubPackages}/react-test-renderer/fc/web.js +0 -0
- package/dist/module/{src/SubPackages → SubPackages}/react-test-renderer/jsx/node.js +0 -0
- package/dist/module/{src/SubPackages → SubPackages}/react-test-renderer/jsx/web.js +0 -0
- package/dist/module/{src/SubPackages → SubPackages}/react-test-renderer/jsx-promised/index.js +0 -0
- package/dist/module/{src/SubPackages → SubPackages}/react-test-renderer/jsx-promised/node.js +1 -1
- /package/dist/module/{src/SubPackages → SubPackages}/react-test-renderer/jsx-promised/web.js +0 -0
- /package/dist/module/{src/Types.js → Types.js} +0 -0
- /package/dist/module/{src/Web.js → Web.js} +0 -0
- /package/dist/module/{src/esbuildConfigs → esbuildConfigs}/featuresPlugin.js +0 -0
- /package/dist/module/{src/esbuildConfigs → esbuildConfigs}/index.js +0 -0
- /package/dist/module/{src/lib → lib}/types.js +0 -0
- /package/dist/module/{src/puppeteerConfiger.js → puppeteerConfiger.js} +0 -0
- /package/dist/module/{src/web.html.js → web.html.js} +0 -0
- /package/dist/types/{src/Init.d.ts → Init.d.ts} +0 -0
- /package/dist/types/{src/build-tests.d.ts → ReportServer.d.ts} +0 -0
- /package/dist/types/{src/SubPackages → SubPackages}/react-test-renderer/component/interface.d.ts +0 -0
- /package/dist/types/{src/init-docs.d.ts → build.d.ts} +0 -0
- /package/dist/types/{src/esbuildConfigs → esbuildConfigs}/featuresPlugin.d.ts +0 -0
- /package/dist/types/{src/run-tests.d.ts → init-docs.d.ts} +0 -0
- /package/dist/types/{src/puppeteerConfiger.d.ts → puppeteerConfiger.d.ts} +0 -0
- /package/dist/types/{src/web.html.d.ts → web.html.d.ts} +0 -0
|
@@ -1,106 +0,0 @@
|
|
|
1
|
-
import readline from "readline";
|
|
2
|
-
import fs from "fs";
|
|
3
|
-
import watch from "recursive-watch";
|
|
4
|
-
import { PM_Main } from "./PM/main.js";
|
|
5
|
-
import { destinationOfRuntime } from "./utils.js";
|
|
6
|
-
readline.emitKeypressEvents(process.stdin);
|
|
7
|
-
if (process.stdin.isTTY)
|
|
8
|
-
process.stdin.setRawMode(true);
|
|
9
|
-
export default async (partialConfig) => {
|
|
10
|
-
const config = Object.assign(Object.assign({}, partialConfig), { buildDir: process.cwd() + "/" + partialConfig.outdir });
|
|
11
|
-
fs.writeFileSync(`${config.outdir}/testeranto.json`, JSON.stringify(Object.assign(Object.assign({}, config), { buildDir: process.cwd() + "/" + config.outdir }), null, 2));
|
|
12
|
-
const pm = new PM_Main(config);
|
|
13
|
-
await pm.startPuppeteer({
|
|
14
|
-
// timeout: 1,
|
|
15
|
-
waitForInitialPage: false,
|
|
16
|
-
executablePath:
|
|
17
|
-
// process.env.CHROMIUM_PATH || "/opt/homebrew/bin/chromium",
|
|
18
|
-
"/opt/homebrew/bin/chromium",
|
|
19
|
-
headless: true,
|
|
20
|
-
dumpio: true,
|
|
21
|
-
// timeout: 0,
|
|
22
|
-
devtools: true,
|
|
23
|
-
args: [
|
|
24
|
-
"--auto-open-devtools-for-tabs",
|
|
25
|
-
`--remote-debugging-port=3234`,
|
|
26
|
-
// "--disable-features=IsolateOrigins,site-per-process",
|
|
27
|
-
"--disable-site-isolation-trials",
|
|
28
|
-
"--allow-insecure-localhost",
|
|
29
|
-
"--allow-file-access-from-files",
|
|
30
|
-
"--allow-running-insecure-content",
|
|
31
|
-
"--disable-dev-shm-usage",
|
|
32
|
-
"--disable-extensions",
|
|
33
|
-
"--disable-gpu",
|
|
34
|
-
"--disable-setuid-sandbox",
|
|
35
|
-
"--disable-site-isolation-trials",
|
|
36
|
-
"--disable-web-security",
|
|
37
|
-
"--no-first-run",
|
|
38
|
-
"--no-sandbox",
|
|
39
|
-
"--no-startup-window",
|
|
40
|
-
// "--no-zygote",
|
|
41
|
-
"--reduce-security-for-testing",
|
|
42
|
-
"--remote-allow-origins=*",
|
|
43
|
-
"--unsafely-treat-insecure-origin-as-secure=*",
|
|
44
|
-
// "--disable-features=IsolateOrigins",
|
|
45
|
-
// "--remote-allow-origins=ws://localhost:3234",
|
|
46
|
-
// "--single-process",
|
|
47
|
-
// "--unsafely-treat-insecure-origin-as-secure",
|
|
48
|
-
// "--unsafely-treat-insecure-origin-as-secure=ws://192.168.0.101:3234",
|
|
49
|
-
// "--disk-cache-dir=/dev/null",
|
|
50
|
-
// "--disk-cache-size=1",
|
|
51
|
-
// "--start-maximized",
|
|
52
|
-
],
|
|
53
|
-
}, ".");
|
|
54
|
-
console.log("\n Puppeteer is running. Press 'q' to shutdown softly. Press 'x' to shutdown forcefully.\n");
|
|
55
|
-
process.stdin.on("keypress", (str, key) => {
|
|
56
|
-
if (key.name === "q") {
|
|
57
|
-
pm.shutDown();
|
|
58
|
-
}
|
|
59
|
-
if (key.name === "x") {
|
|
60
|
-
process.exit(-1);
|
|
61
|
-
}
|
|
62
|
-
});
|
|
63
|
-
config.tests.forEach(([test, runtime, tr, sidecars]) => {
|
|
64
|
-
if (runtime === "node") {
|
|
65
|
-
pm.launchNode(test, destinationOfRuntime(test, "node", config));
|
|
66
|
-
}
|
|
67
|
-
else if (runtime === "web") {
|
|
68
|
-
pm.launchWeb(test, destinationOfRuntime(test, "web", config), sidecars);
|
|
69
|
-
}
|
|
70
|
-
else {
|
|
71
|
-
console.error("runtime makes no sense", runtime);
|
|
72
|
-
}
|
|
73
|
-
});
|
|
74
|
-
if (config.devMode) {
|
|
75
|
-
console.log("ready and watching for changes...", config.buildDir);
|
|
76
|
-
watch(config.buildDir, (eventType, changedFile) => {
|
|
77
|
-
if (changedFile) {
|
|
78
|
-
config.tests.forEach(([test, runtime, tr, sidecars]) => {
|
|
79
|
-
if (eventType === "change" || eventType === "rename") {
|
|
80
|
-
if (changedFile ===
|
|
81
|
-
test
|
|
82
|
-
.replace("./", "node/")
|
|
83
|
-
.split(".")
|
|
84
|
-
.slice(0, -1)
|
|
85
|
-
.concat("mjs")
|
|
86
|
-
.join(".")) {
|
|
87
|
-
pm.launchNode(test, destinationOfRuntime(test, "node", config));
|
|
88
|
-
}
|
|
89
|
-
if (changedFile ===
|
|
90
|
-
test
|
|
91
|
-
.replace("./", "web/")
|
|
92
|
-
.split(".")
|
|
93
|
-
.slice(0, -1)
|
|
94
|
-
.concat("mjs")
|
|
95
|
-
.join(".")) {
|
|
96
|
-
pm.launchWeb(test, destinationOfRuntime(test, "web", config), sidecars);
|
|
97
|
-
}
|
|
98
|
-
}
|
|
99
|
-
});
|
|
100
|
-
}
|
|
101
|
-
});
|
|
102
|
-
}
|
|
103
|
-
else {
|
|
104
|
-
pm.shutDown();
|
|
105
|
-
}
|
|
106
|
-
};
|
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
import React from "react";
|
|
2
|
-
import Testeranto from "../Node.js";
|
|
3
|
-
export default (testInput, testSpecifications, testImplementations, testInterface) => {
|
|
4
|
-
return Testeranto(testInput, testSpecifications, testImplementations, Object.assign({ beforeAll: (x) => {
|
|
5
|
-
// process.parentPort.postMessage(
|
|
6
|
-
// `/docs/web/src/ClassicalComponent/test.html`
|
|
7
|
-
// );
|
|
8
|
-
return x;
|
|
9
|
-
}, beforeEach: async () => {
|
|
10
|
-
return new Promise((resolve, rej) => {
|
|
11
|
-
resolve(React.createElement(testInput, {}, []));
|
|
12
|
-
});
|
|
13
|
-
}, andWhen: function (s, whenCB) {
|
|
14
|
-
return whenCB()(s);
|
|
15
|
-
} }, testInterface));
|
|
16
|
-
};
|
|
@@ -1,27 +0,0 @@
|
|
|
1
|
-
import React from "react";
|
|
2
|
-
export const testInterface = {
|
|
3
|
-
// beforeAll: async (proto, testResource, artificer, pm): Promise<IStore> => {
|
|
4
|
-
// return React.createElement(proto);
|
|
5
|
-
// // return new Promise((resolve, rej) => {
|
|
6
|
-
// // resolve(x());
|
|
7
|
-
// // });
|
|
8
|
-
// },
|
|
9
|
-
// beforeEach: async (subject, initializer, artificer): Promise<IStore> => {
|
|
10
|
-
// return new Promise((resolve, rej) => {
|
|
11
|
-
// resolve(React.createElement(subject));
|
|
12
|
-
// });
|
|
13
|
-
// },
|
|
14
|
-
andWhen: async (s, whenCB) => {
|
|
15
|
-
await whenCB(s());
|
|
16
|
-
return new Promise((resolve, rej) => {
|
|
17
|
-
resolve(React.createElement(s));
|
|
18
|
-
});
|
|
19
|
-
// return whenCB(s);
|
|
20
|
-
},
|
|
21
|
-
butThen: async (subject, thenCB) => {
|
|
22
|
-
await thenCB(subject());
|
|
23
|
-
return new Promise((resolve, rej) => {
|
|
24
|
-
resolve(React.createElement(subject));
|
|
25
|
-
});
|
|
26
|
-
},
|
|
27
|
-
};
|
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
import process from "process";
|
|
2
|
-
import { ITProject } from "./Project";
|
|
3
|
-
if (!process.argv[2]) {
|
|
4
|
-
console.log("You didn't pass a config file");
|
|
5
|
-
process.exit(-1);
|
|
6
|
-
}
|
|
7
|
-
else {
|
|
8
|
-
import(process.cwd() + "/" + process.argv[2]).then((module) => {
|
|
9
|
-
new ITProject(module.default);
|
|
10
|
-
});
|
|
11
|
-
}
|
|
@@ -1,12 +0,0 @@
|
|
|
1
|
-
export default (config) => {
|
|
2
|
-
return {
|
|
3
|
-
bundle: true,
|
|
4
|
-
entryPoints: [config.features],
|
|
5
|
-
minify: config.minify === true,
|
|
6
|
-
outbase: config.outbase,
|
|
7
|
-
write: true,
|
|
8
|
-
outfile: `${config.outdir}/features.test.js`,
|
|
9
|
-
// external: ["graphology"],
|
|
10
|
-
format: "esm",
|
|
11
|
-
};
|
|
12
|
-
};
|
|
@@ -1,82 +0,0 @@
|
|
|
1
|
-
import fs from "fs";
|
|
2
|
-
import path from "path";
|
|
3
|
-
const otherInputs = {};
|
|
4
|
-
const register = (entrypoint, sources) => {
|
|
5
|
-
if (!otherInputs[entrypoint]) {
|
|
6
|
-
otherInputs[entrypoint] = new Set();
|
|
7
|
-
}
|
|
8
|
-
sources.forEach((s) => otherInputs[entrypoint].add(s));
|
|
9
|
-
};
|
|
10
|
-
function tree(meta, key) {
|
|
11
|
-
const outputKey = Object.keys(meta.outputs).find((k) => {
|
|
12
|
-
return meta.outputs[k].entryPoint === key;
|
|
13
|
-
});
|
|
14
|
-
if (!outputKey) {
|
|
15
|
-
console.error("No outputkey found");
|
|
16
|
-
process.exit(-1);
|
|
17
|
-
}
|
|
18
|
-
return Object.keys(meta.outputs[outputKey].inputs).filter((k) => k.startsWith("src"));
|
|
19
|
-
}
|
|
20
|
-
export default (platform, entryPoints) => {
|
|
21
|
-
return {
|
|
22
|
-
register,
|
|
23
|
-
inputFilesPluginFactory: {
|
|
24
|
-
name: "metafileWriter",
|
|
25
|
-
setup(build) {
|
|
26
|
-
build.onEnd((result) => {
|
|
27
|
-
fs.writeFileSync(`docs/${platform}/metafile.json`, JSON.stringify(result, null, 2));
|
|
28
|
-
if (result.errors.length === 0) {
|
|
29
|
-
entryPoints.forEach((entryPoint) => {
|
|
30
|
-
const filePath = path.join("./docs/", platform, entryPoint.split(".").slice(0, -1).join("."), `inputFiles.json`);
|
|
31
|
-
const dirName = path.dirname(filePath);
|
|
32
|
-
if (!fs.existsSync(dirName)) {
|
|
33
|
-
fs.mkdirSync(dirName, { recursive: true });
|
|
34
|
-
}
|
|
35
|
-
const promptPath = path.join("./docs/", platform, entryPoint.split(".").slice(0, -1).join("."), `prompt.txt`);
|
|
36
|
-
const testPaths = path.join("./docs/", platform, entryPoint.split(".").slice(0, -1).join("."), `tests.json`);
|
|
37
|
-
const featuresPath = path.join("./docs/", platform, entryPoint.split(".").slice(0, -1).join("."), `featurePrompt.txt`);
|
|
38
|
-
const stderrPath = path.join("./docs/", platform, entryPoint.split(".").slice(0, -1).join("."), `stderr.log`);
|
|
39
|
-
const stdoutPath = path.join("./docs/", platform, entryPoint.split(".").slice(0, -1).join("."), `stdout.log`);
|
|
40
|
-
if (result.metafile) {
|
|
41
|
-
const addableFiles = tree(result.metafile, entryPoint.split("/").slice(1).join("/"))
|
|
42
|
-
.map((y) => {
|
|
43
|
-
if (otherInputs[y]) {
|
|
44
|
-
return Array.from(otherInputs[y]);
|
|
45
|
-
}
|
|
46
|
-
return y;
|
|
47
|
-
})
|
|
48
|
-
.flat();
|
|
49
|
-
const typeErrorFiles = addableFiles.map((t) => `docs/types/${t}.type_errors.txt`);
|
|
50
|
-
fs.writeFileSync(promptPath, `
|
|
51
|
-
${addableFiles
|
|
52
|
-
.map((x) => {
|
|
53
|
-
return `/add ${x}`;
|
|
54
|
-
})
|
|
55
|
-
.join("\n")}
|
|
56
|
-
|
|
57
|
-
${typeErrorFiles
|
|
58
|
-
.map((x) => {
|
|
59
|
-
// const f = `docs/types/${x}.type_errors.txt`;
|
|
60
|
-
return `/read ${x}`;
|
|
61
|
-
// if (fs.existsSync(f)) {
|
|
62
|
-
// return `/read ${f}`;
|
|
63
|
-
// }
|
|
64
|
-
})
|
|
65
|
-
.join("\n")}
|
|
66
|
-
|
|
67
|
-
/read ${testPaths}
|
|
68
|
-
/read ${stdoutPath}
|
|
69
|
-
/read ${stderrPath}
|
|
70
|
-
|
|
71
|
-
/load ${featuresPath}
|
|
72
|
-
|
|
73
|
-
/code Fix the failing tests described in ${testPaths}. Correct any type signature errors described in the files [${typeErrorFiles.join(", ")}]. Implement any method which throws "Function not implemented."
|
|
74
|
-
`);
|
|
75
|
-
}
|
|
76
|
-
});
|
|
77
|
-
}
|
|
78
|
-
});
|
|
79
|
-
},
|
|
80
|
-
},
|
|
81
|
-
};
|
|
82
|
-
};
|
|
@@ -1,14 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
// import { BuildOptions } from "esbuild";
|
|
3
|
-
// import { IBaseConfig } from "../lib/types";
|
|
4
|
-
// export default (config: IBaseConfig): BuildOptions => {
|
|
5
|
-
// return {
|
|
6
|
-
// bundle: true,
|
|
7
|
-
// entryPoints: ["./node_modules/testeranto/dist/module/report.js"],
|
|
8
|
-
// minify: config.minify === true,
|
|
9
|
-
// outbase: config.outbase,
|
|
10
|
-
// write: true,
|
|
11
|
-
// outfile: `${config.outdir}/report.js`,
|
|
12
|
-
// external: ["tests.json", "features.test.js"],
|
|
13
|
-
// };
|
|
14
|
-
// };
|
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
import Puppeteer from "./Puppeteer.js";
|
|
2
|
-
import process from "process";
|
|
3
|
-
if (!process.argv[2]) {
|
|
4
|
-
console.log("You didn't pass a config file");
|
|
5
|
-
process.exit(-1);
|
|
6
|
-
}
|
|
7
|
-
else {
|
|
8
|
-
import(process.cwd() + "/" + process.argv[2]).then((module) => {
|
|
9
|
-
Puppeteer(module.default);
|
|
10
|
-
});
|
|
11
|
-
}
|
package/dist/module/src/utils.js
DELETED
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
export default {
|
|
2
|
-
botEmail: "adamwong246@gmail.com",
|
|
3
|
-
taskman: "adamwong246/kokomobay-taskman",
|
|
4
|
-
outdir: "docs",
|
|
5
|
-
tests: [["./src/LoginButton.test.tsx", "web", { ports: 0 }, []]],
|
|
6
|
-
debugger: true,
|
|
7
|
-
clearScreen: false,
|
|
8
|
-
devMode: true,
|
|
9
|
-
minify: false,
|
|
10
|
-
outbase: ".",
|
|
11
|
-
ports: [],
|
|
12
|
-
externals: [],
|
|
13
|
-
};
|