testeranto 0.114.1 → 0.125.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 +97001 -0
- package/.aider.conf.yml +5 -0
- package/.aider.input.history +9 -0
- package/.aider.tags.cache.v3/b7/e6/5be87b62aeaf2bc244ff41c1b61a.val +0 -0
- package/.aider.tags.cache.v3/cache.db +0 -0
- package/.aider.tags.cache.v3/e3/e6/3501625caf5d5eb171f0d248462e.val +0 -0
- package/.aider.tags.cache.v3/ec/c0/161c249c35be853cc40cf11f9267.val +0 -0
- package/README.md +15 -1
- package/bundle.js +1 -1
- package/dist/common/src/Init.js +31 -0
- package/dist/common/src/Node.js +49 -0
- package/dist/common/src/PM/base.js +230 -0
- package/dist/common/src/PM/main.js +1026 -0
- package/dist/common/src/PM/node.js +161 -0
- package/dist/common/{PM/node.js → src/PM/pure.js} +27 -18
- package/dist/common/{PM → src/PM}/web.js +14 -47
- package/dist/common/{Node.js → src/Pure.js} +11 -9
- package/dist/common/{SubPackages/react/component/web.js → src/SubPackages/react/component/index.js} +5 -4
- package/dist/common/src/SubPackages/react/component/node.js +10 -0
- package/dist/common/src/SubPackages/react/component/pure.js +10 -0
- package/dist/common/{SubPackages/react/jsx → src/SubPackages/react/component}/web.js +2 -2
- package/dist/common/src/SubPackages/react/jsx/index.js +64 -0
- package/dist/common/src/SubPackages/react/jsx/pure.js +10 -0
- package/dist/common/src/SubPackages/react/jsx/web.js +10 -0
- package/dist/common/{SubPackages/react-dom/component/web.js → src/SubPackages/react-dom/component/dynamic.js} +8 -14
- package/dist/common/src/SubPackages/react-dom/component/node.js +10 -0
- package/dist/common/src/SubPackages/react-dom/component/pure.js +10 -0
- package/dist/common/src/SubPackages/react-dom/component/static.js +26 -0
- package/dist/common/src/SubPackages/react-dom/component/web.js +16 -0
- package/dist/common/src/SubPackages/react-dom/jsx/dynamic.js +31 -0
- package/dist/common/src/SubPackages/react-dom/jsx/node.js +10 -0
- package/dist/common/src/SubPackages/react-dom/jsx/pure.js +10 -0
- package/dist/common/src/SubPackages/react-dom/jsx/static.js +59 -0
- package/dist/common/src/SubPackages/react-dom/jsx/web.js +16 -0
- package/dist/common/src/SubPackages/react-test-renderer/component/index.js +15 -0
- package/dist/common/src/SubPackages/react-test-renderer/component/pure.js +8 -0
- package/dist/common/src/SubPackages/react-test-renderer/component/test/implementation.js +57 -0
- package/dist/common/src/SubPackages/react-test-renderer/component/test/node.js +10 -0
- package/dist/common/src/SubPackages/react-test-renderer/component/test/pure.js +10 -0
- package/dist/common/src/SubPackages/react-test-renderer/component/test/web.js +10 -0
- package/dist/common/src/SubPackages/react-test-renderer/jsx/pure.js +10 -0
- package/dist/common/{Web.js → src/Web.js} +1 -4
- package/dist/common/src/build.js +223 -0
- package/dist/common/{defaultConfig.js → src/defaultConfig.js} +1 -3
- package/dist/common/{esbuildConfigs → src/esbuildConfigs}/index.js +1 -1
- package/dist/common/{esbuildConfigs → src/esbuildConfigs}/inputFilesPlugin.js +7 -3
- package/dist/common/{esbuildConfigs → src/esbuildConfigs}/node.js +7 -4
- package/dist/common/src/esbuildConfigs/pure.js +41 -0
- package/dist/common/{esbuildConfigs → src/esbuildConfigs}/web.js +8 -5
- package/dist/common/src/examples/react/component/index.js +33 -0
- package/dist/common/src/examples/react/component/test.js +36 -0
- package/dist/common/src/init-docs.js +9 -0
- package/dist/common/{lib → src/lib}/abstractBase.js +99 -95
- package/dist/common/{lib → src/lib}/basebuilder.js +24 -20
- package/dist/common/{lib → src/lib}/classBuilder.js +8 -5
- package/dist/common/{lib → src/lib}/core.js +10 -60
- package/dist/common/{lib → src/lib}/index.js +7 -2
- package/dist/common/{run.js → src/run.js} +12 -4
- package/dist/common/src/utils.js +65 -0
- package/dist/common/testeranto.config.js +41 -0
- package/dist/common/tsconfig.common.tsbuildinfo +1 -1
- package/dist/module/src/Init.js +26 -0
- package/dist/module/src/Node.js +42 -0
- package/dist/module/src/PM/base.js +223 -0
- package/dist/module/src/PM/main.js +986 -0
- package/dist/module/src/PM/node.js +154 -0
- package/dist/module/{PM/node.js → src/PM/pure.js} +25 -16
- package/dist/module/{PM → src/PM}/web.js +14 -47
- package/dist/module/src/Project.js +120 -0
- package/dist/module/{Node.js → src/Pure.js} +9 -7
- package/dist/module/{ReportClient.js → src/ReportClient.js} +1 -1
- package/dist/module/{SubPackages/react/component/web.js → src/SubPackages/react/component/index.js} +3 -4
- package/dist/module/src/SubPackages/react/component/node.js +5 -0
- package/dist/module/src/SubPackages/react/component/pure.js +5 -0
- package/dist/module/{SubPackages/react/jsx → src/SubPackages/react/component}/web.js +3 -3
- package/dist/module/src/SubPackages/react/jsx/index.js +58 -0
- package/dist/module/{SubPackages → src/SubPackages}/react/jsx/node.js +1 -1
- package/dist/module/src/SubPackages/react/jsx/pure.js +5 -0
- package/dist/module/src/SubPackages/react/jsx/web.js +5 -0
- package/dist/module/{SubPackages/react-dom/component/web.js → src/SubPackages/react-dom/component/dynamic.js} +5 -13
- package/dist/module/src/SubPackages/react-dom/component/node.js +5 -0
- package/dist/module/src/SubPackages/react-dom/component/pure.js +5 -0
- package/dist/module/src/SubPackages/react-dom/component/static.js +22 -0
- package/dist/module/src/SubPackages/react-dom/component/web.js +11 -0
- package/dist/module/{SubPackages/react-dom/jsx/node.js → src/SubPackages/react-dom/jsx/dynamic.js} +3 -7
- package/dist/module/src/SubPackages/react-dom/jsx/node.js +5 -0
- package/dist/module/src/SubPackages/react-dom/jsx/pure.js +5 -0
- package/dist/module/src/SubPackages/react-dom/jsx/static.js +53 -0
- package/dist/module/src/SubPackages/react-dom/jsx/web.js +11 -0
- package/dist/module/src/SubPackages/react-test-renderer/component/index.js +14 -0
- package/dist/module/src/SubPackages/react-test-renderer/component/pure.js +3 -0
- package/dist/module/src/SubPackages/react-test-renderer/component/test/implementation.js +54 -0
- package/dist/module/src/SubPackages/react-test-renderer/component/test/node.js +5 -0
- package/dist/module/src/SubPackages/react-test-renderer/component/test/pure.js +5 -0
- package/dist/module/src/SubPackages/react-test-renderer/component/test/web.js +5 -0
- package/dist/module/src/SubPackages/react-test-renderer/jsx/pure.js +5 -0
- package/dist/module/{TestReport.js → src/TestReport.js} +26 -14
- package/dist/module/{Web.js → src/Web.js} +1 -4
- package/dist/module/src/build.js +185 -0
- package/dist/module/{defaultConfig.js → src/defaultConfig.js} +1 -3
- package/dist/module/{esbuildConfigs → src/esbuildConfigs}/index.js +1 -1
- package/dist/module/{esbuildConfigs → src/esbuildConfigs}/inputFilesPlugin.js +7 -3
- package/dist/module/{esbuildConfigs → src/esbuildConfigs}/node.js +7 -4
- package/dist/module/src/esbuildConfigs/pure.js +36 -0
- package/dist/module/{esbuildConfigs → src/esbuildConfigs}/web.js +8 -5
- package/dist/module/src/examples/react/component/index.js +26 -0
- package/dist/module/src/examples/react/component/test.js +32 -0
- package/dist/module/src/init-docs.js +4 -0
- package/dist/module/{lib → src/lib}/abstractBase.js +99 -95
- package/dist/module/{lib → src/lib}/basebuilder.js +24 -20
- package/dist/module/{lib → src/lib}/classBuilder.js +8 -5
- package/dist/module/{lib → src/lib}/core.js +10 -60
- package/dist/module/{lib → src/lib}/index.js +7 -2
- package/dist/module/{run.js → src/run.js} +12 -4
- package/dist/module/src/utils.js +53 -0
- package/dist/module/testeranto.config.js +39 -0
- package/dist/module/tsconfig.module.tsbuildinfo +1 -1
- package/dist/prebuild/Project.css +11367 -0
- package/dist/prebuild/Project.js +24643 -0
- package/dist/prebuild/ReportClient.js +1 -1
- package/dist/prebuild/TestReport.js +13 -12
- package/dist/prebuild/build.mjs +217 -106
- package/dist/prebuild/init-docs.mjs +29 -83
- package/dist/prebuild/run.mjs +803 -686
- package/dist/tsconfig.tsbuildinfo +1 -1
- package/dist/types/src/Init.d.ts +2 -0
- package/dist/types/src/Node.d.ts +9 -0
- package/dist/types/src/PM/base.d.ts +34 -0
- package/dist/types/{PM → src/PM}/index.d.ts +21 -22
- package/dist/types/src/PM/main.d.ts +47 -0
- package/dist/types/src/PM/node.d.ts +38 -0
- package/dist/types/{PM/node.d.ts → src/PM/pure.d.ts} +16 -17
- package/dist/types/{PM → src/PM}/web.d.ts +10 -15
- package/dist/types/src/Pure.d.ts +9 -0
- package/dist/types/src/SubPackages/react/component/index.d.ts +4 -0
- package/dist/types/src/SubPackages/react/component/node.d.ts +4 -0
- package/dist/types/src/SubPackages/react/component/pure.d.ts +4 -0
- package/dist/types/src/SubPackages/react/component/web.d.ts +4 -0
- package/dist/types/src/SubPackages/react/jsx/index.d.ts +5 -0
- package/dist/types/src/SubPackages/react/jsx/node.d.ts +4 -0
- package/dist/types/src/SubPackages/react/jsx/pure.d.ts +4 -0
- package/dist/types/src/SubPackages/react/jsx/web.d.ts +4 -0
- package/dist/types/src/SubPackages/react-dom/component/dynamic.d.ts +20 -0
- package/dist/types/src/SubPackages/react-dom/component/node.d.ts +4 -0
- package/dist/types/src/SubPackages/react-dom/component/pure.d.ts +4 -0
- package/dist/types/src/SubPackages/react-dom/component/static.d.ts +9 -0
- package/dist/types/src/SubPackages/react-dom/component/web.d.ts +4 -0
- package/dist/types/src/SubPackages/react-dom/jsx/dynamic.d.ts +5 -0
- package/dist/types/src/SubPackages/react-dom/jsx/node.d.ts +4 -0
- package/dist/types/src/SubPackages/react-dom/jsx/pure.d.ts +4 -0
- package/dist/types/src/SubPackages/react-dom/jsx/static.d.ts +5 -0
- package/dist/types/src/SubPackages/react-dom/jsx/web.d.ts +5 -0
- package/dist/types/{SubPackages → src/SubPackages}/react-test-renderer/MemoExoticComponent/node.d.ts +1 -1
- package/dist/types/src/SubPackages/react-test-renderer/component/index.d.ts +5 -0
- package/dist/types/src/SubPackages/react-test-renderer/component/interface.d.ts +3 -0
- package/dist/types/src/SubPackages/react-test-renderer/component/node.d.ts +4 -0
- package/dist/types/src/SubPackages/react-test-renderer/component/pure.d.ts +4 -0
- package/dist/types/src/SubPackages/react-test-renderer/component/test/implementation.d.ts +4 -0
- package/dist/types/src/SubPackages/react-test-renderer/component/test/node.d.ts +3 -0
- package/dist/types/src/SubPackages/react-test-renderer/component/test/pure.d.ts +4 -0
- package/dist/types/src/SubPackages/react-test-renderer/component/test/web.d.ts +3 -0
- package/dist/types/src/SubPackages/react-test-renderer/component/web.d.ts +4 -0
- package/dist/types/{SubPackages → src/SubPackages}/react-test-renderer/fc/node.d.ts +1 -1
- package/dist/types/{SubPackages → src/SubPackages}/react-test-renderer/fc/web.d.ts +1 -1
- package/dist/types/src/SubPackages/react-test-renderer/jsx/index.d.ts +11 -0
- package/dist/types/src/SubPackages/react-test-renderer/jsx/node.d.ts +4 -0
- package/dist/types/src/SubPackages/react-test-renderer/jsx/pure.d.ts +4 -0
- package/dist/types/src/SubPackages/react-test-renderer/jsx/web.d.ts +4 -0
- package/dist/types/{SubPackages → src/SubPackages}/react-test-renderer/jsx-promised/node.d.ts +1 -1
- package/dist/types/{SubPackages → src/SubPackages}/react-test-renderer/jsx-promised/web.d.ts +1 -1
- package/dist/types/src/Types.d.ts +88 -0
- package/dist/types/src/Web.d.ts +9 -0
- package/dist/types/src/defaultConfig.d.ts +3 -0
- package/dist/types/src/esbuildConfigs/index.d.ts +4 -0
- package/dist/types/{esbuildConfigs → src/esbuildConfigs}/inputFilesPlugin.d.ts +2 -1
- package/dist/types/src/esbuildConfigs/node.d.ts +4 -0
- package/dist/types/src/esbuildConfigs/pure.d.ts +4 -0
- package/dist/types/src/esbuildConfigs/web.d.ts +4 -0
- package/dist/types/src/examples/react/component/index.d.ts +13 -0
- package/dist/types/src/examples/react/component/test.d.ts +17 -0
- package/dist/types/{lib → src/lib}/abstractBase.d.ts +47 -34
- package/dist/types/{lib → src/lib}/basebuilder.d.ts +7 -9
- package/dist/types/src/lib/classBuilder.d.ts +9 -0
- package/dist/types/src/lib/core.d.ts +7 -0
- package/dist/types/{lib → src/lib}/index.d.ts +14 -36
- package/dist/types/src/lib/types.d.ts +15 -0
- package/dist/types/src/utils.d.ts +18 -0
- package/dist/types/testeranto.config.d.ts +3 -0
- package/dist/types/tsconfig.types.tsbuildinfo +1 -1
- package/eslint.config.mjs +111 -0
- package/package.json +33 -12
- package/src/Init.ts +29 -75
- package/src/Node.ts +42 -46
- package/src/PM/base.ts +299 -0
- package/src/PM/index.ts +28 -21
- package/src/PM/main.ts +569 -819
- package/src/PM/node.ts +88 -44
- package/src/PM/pure.ts +209 -0
- package/src/PM/web.ts +19 -121
- package/src/Project.tsx +200 -0
- package/src/Pure.ts +69 -0
- package/src/ReportClient.tsx +8 -3
- package/src/SubPackages/react/component/index.ts +28 -0
- package/src/SubPackages/react/component/node.ts +12 -82
- package/src/SubPackages/react/component/pure.ts +17 -0
- package/src/SubPackages/react/component/web.ts +12 -81
- package/src/SubPackages/react/jsx/index.ts +56 -52
- package/src/SubPackages/react/jsx/node.ts +12 -29
- package/src/SubPackages/react/jsx/pure.ts +23 -0
- package/src/SubPackages/react/jsx/web.ts +17 -36
- package/src/SubPackages/react-dom/component/dynamic.ts +107 -0
- package/src/SubPackages/react-dom/component/node.ts +11 -116
- package/src/SubPackages/react-dom/component/pure.ts +17 -0
- package/src/SubPackages/react-dom/component/static.ts +41 -0
- package/src/SubPackages/react-dom/component/web.ts +7 -113
- package/src/SubPackages/react-dom/jsx/dynamic.ts +46 -0
- package/src/SubPackages/react-dom/jsx/node.ts +10 -58
- package/src/SubPackages/react-dom/jsx/pure.ts +18 -0
- package/src/SubPackages/react-dom/jsx/static.ts +87 -0
- package/src/SubPackages/react-dom/jsx/web.ts +7 -135
- package/src/SubPackages/react-test-renderer/component/index.ts +27 -51
- package/src/SubPackages/react-test-renderer/component/interface.ts +7 -5
- package/src/SubPackages/react-test-renderer/component/node.ts +7 -25
- package/src/SubPackages/react-test-renderer/component/pure.ts +18 -0
- package/src/SubPackages/react-test-renderer/component/test/implementation.ts +63 -0
- package/src/SubPackages/react-test-renderer/component/test/node.ts +14 -0
- package/src/SubPackages/react-test-renderer/component/test/pure.ts +14 -0
- package/src/SubPackages/react-test-renderer/component/test/web.ts +14 -0
- package/src/SubPackages/react-test-renderer/component/web.ts +7 -23
- package/src/SubPackages/react-test-renderer/jsx/index.ts +13 -46
- package/src/SubPackages/react-test-renderer/jsx/node.ts +9 -15
- package/src/SubPackages/react-test-renderer/jsx/pure.ts +31 -0
- package/src/SubPackages/react-test-renderer/jsx/web.ts +9 -14
- package/src/TestReport.tsx +37 -19
- package/src/Types.ts +114 -140
- package/src/Web.ts +13 -48
- package/src/build.ts +153 -143
- package/src/defaultConfig.ts +3 -5
- package/src/esbuildConfigs/index.ts +3 -3
- package/src/esbuildConfigs/inputFilesPlugin.ts +9 -7
- package/src/esbuildConfigs/node.ts +10 -6
- package/src/esbuildConfigs/pure.ts +72 -0
- package/src/esbuildConfigs/web.ts +11 -7
- package/src/examples/react/component/index.tsx +35 -0
- package/src/examples/react/component/test.ts +83 -0
- package/src/init-docs.ts +2 -15
- package/src/lib/abstractBase.ts +188 -260
- package/src/lib/basebuilder.ts +47 -48
- package/src/lib/classBuilder.ts +28 -35
- package/src/lib/core.ts +35 -102
- package/src/lib/index.ts +37 -65
- package/src/lib/types.ts +23 -98
- package/src/run.ts +18 -5
- package/src/utils.ts +73 -40
- package/testeranto/Project.css +11367 -0
- package/testeranto/Project.js +24643 -0
- package/testeranto/ReportClient.css +11367 -0
- package/testeranto/ReportClient.js +24641 -0
- package/testeranto/TestReport.css +11367 -0
- package/testeranto/TestReport.js +27485 -0
- package/testeranto/bundles/node/react/metafile.json +627 -0
- package/testeranto/bundles/node/react/src/SubPackages/react-test-renderer/component/test/node.mjs +24687 -0
- package/testeranto/bundles/pure/react/metafile.json +8 -0
- package/testeranto/bundles/pure/react/src/SubPackages/react-test-renderer/component/test/pure.mjs +24625 -0
- package/testeranto/bundles/web/react/metafile.json +8 -0
- package/testeranto/bundles/web/react/src/SubPackages/react-test-renderer/component/test/web.html +19 -0
- package/testeranto/bundles/web/react/src/SubPackages/react-test-renderer/component/test/web.mjs +21290 -0
- package/testeranto/index.html +28 -0
- package/testeranto/reports/react/config.json +22 -0
- package/testeranto/reports/react/index.html +24 -0
- package/testeranto/reports/react/src/SubPackages/react-test-renderer/component/test/node/node/console_log.txt +0 -0
- package/testeranto/reports/react/src/SubPackages/react-test-renderer/component/test/pure/pure/bdd_errors.txt +1 -0
- package/testeranto/reports/react/src/SubPackages/react-test-renderer/component/test/pure/pure/featurePrompt.txt +0 -0
- package/testeranto/reports/react/src/SubPackages/react-test-renderer/component/test/pure/pure/lint_errors.json +3381 -0
- package/testeranto/reports/react/src/SubPackages/react-test-renderer/component/test/pure/pure/littleBoard.html +20 -0
- package/testeranto/reports/react/src/SubPackages/react-test-renderer/component/test/pure/pure/log.txt +40 -0
- package/testeranto/reports/react/src/SubPackages/react-test-renderer/component/test/pure/pure/prompt.txt +24 -0
- package/testeranto/reports/react/src/SubPackages/react-test-renderer/component/test/pure/pure/tests.json +132 -0
- package/testeranto/reports/react/src/SubPackages/react-test-renderer/component/test/pure/pure/type_errors.txt +17 -0
- package/testeranto/reports/react/src/SubPackages/react-test-renderer/component/test/web/web/bdd_errors.txt +1 -0
- package/testeranto/reports/react/src/SubPackages/react-test-renderer/component/test/web/web/console_log.txt +1 -0
- package/testeranto/reports/react/src/SubPackages/react-test-renderer/component/test/web/web/lint_errors.json +2947 -0
- package/testeranto/reports/react/src/SubPackages/react-test-renderer/component/test/web/web/littleBoard.html +20 -0
- package/testeranto/reports/react/src/SubPackages/react-test-renderer/component/test/web/web/log.txt +40 -0
- package/testeranto/reports/react/src/SubPackages/react-test-renderer/component/test/web/web/prompt.txt +23 -0
- package/testeranto/reports/react/src/SubPackages/react-test-renderer/component/test/web/web/tests.json +132 -0
- package/testeranto/reports/react/src/SubPackages/react-test-renderer/component/test/web/web/type_errors.txt +18 -0
- package/testeranto/reports/react/summary.json +8 -0
- package/testeranto.config.ts +45 -0
- package/tsc.log +53 -76
- package/type-fix.txt +2 -0
- package/dist/common/Init.js +0 -68
- package/dist/common/PM/main.js +0 -1176
- package/dist/common/SubPackages/react/component/node.js +0 -19
- package/dist/common/SubPackages/react/jsx/index.js +0 -21
- package/dist/common/SubPackages/react-dom/component/node.js +0 -88
- package/dist/common/SubPackages/react-dom/jsx/node.js +0 -39
- package/dist/common/SubPackages/react-dom/jsx/web.js +0 -128
- package/dist/common/SubPackages/react-test-renderer/component/index.js +0 -2
- package/dist/common/build.js +0 -222
- package/dist/common/init-docs.js +0 -53
- package/dist/common/puppeteerConfiger.js +0 -24
- package/dist/common/utils.js +0 -43
- package/dist/module/Init.js +0 -63
- package/dist/module/PM/main.js +0 -1136
- package/dist/module/SubPackages/react/component/node.js +0 -14
- package/dist/module/SubPackages/react/jsx/index.js +0 -15
- package/dist/module/SubPackages/react-dom/component/node.js +0 -80
- package/dist/module/SubPackages/react-dom/jsx/web.js +0 -90
- package/dist/module/SubPackages/react-test-renderer/component/index.js +0 -1
- package/dist/module/build.js +0 -184
- package/dist/module/init-docs.js +0 -15
- package/dist/module/puppeteerConfiger.js +0 -19
- package/dist/module/utils.js +0 -29
- package/dist/types/Init.d.ts +0 -2
- package/dist/types/Node.d.ts +0 -12
- package/dist/types/PM/main.d.ts +0 -66
- package/dist/types/SubPackages/react/component/node.d.ts +0 -7
- package/dist/types/SubPackages/react/component/web.d.ts +0 -7
- package/dist/types/SubPackages/react/jsx/index.d.ts +0 -12
- package/dist/types/SubPackages/react/jsx/node.d.ts +0 -4
- package/dist/types/SubPackages/react/jsx/web.d.ts +0 -4
- package/dist/types/SubPackages/react-dom/component/node.d.ts +0 -11
- package/dist/types/SubPackages/react-dom/component/web.d.ts +0 -20
- package/dist/types/SubPackages/react-dom/jsx/node.d.ts +0 -7
- package/dist/types/SubPackages/react-dom/jsx/web.d.ts +0 -5
- package/dist/types/SubPackages/react-test-renderer/component/index.d.ts +0 -13
- package/dist/types/SubPackages/react-test-renderer/component/interface.d.ts +0 -9
- package/dist/types/SubPackages/react-test-renderer/component/node.d.ts +0 -4
- package/dist/types/SubPackages/react-test-renderer/component/web.d.ts +0 -4
- package/dist/types/SubPackages/react-test-renderer/jsx/index.d.ts +0 -16
- package/dist/types/SubPackages/react-test-renderer/jsx/node.d.ts +0 -9
- package/dist/types/SubPackages/react-test-renderer/jsx/web.d.ts +0 -9
- package/dist/types/Types.d.ts +0 -61
- package/dist/types/Web.d.ts +0 -9
- package/dist/types/defaultConfig.d.ts +0 -3
- package/dist/types/esbuildConfigs/index.d.ts +0 -4
- package/dist/types/esbuildConfigs/node.d.ts +0 -4
- package/dist/types/esbuildConfigs/web.d.ts +0 -4
- package/dist/types/lib/classBuilder.d.ts +0 -7
- package/dist/types/lib/core.d.ts +0 -7
- package/dist/types/lib/types.d.ts +0 -14
- package/dist/types/puppeteerConfiger.d.ts +0 -4
- package/dist/types/utils.d.ts +0 -15
- package/src/puppeteerConfiger.ts +0 -26
- /package/dist/common/{PM → src/PM}/index.js +0 -0
- /package/dist/common/{ReportServer.js → src/ReportServer.js} +0 -0
- /package/dist/common/{SubPackages → src/SubPackages}/react/jsx/node.js +0 -0
- /package/dist/common/{SubPackages → src/SubPackages}/react-dom/jsx/index.js +0 -0
- /package/dist/common/{SubPackages → src/SubPackages}/react-test-renderer/MemoExoticComponent/node.js +0 -0
- /package/dist/common/{SubPackages → src/SubPackages}/react-test-renderer/component/interface.js +0 -0
- /package/dist/common/{SubPackages → src/SubPackages}/react-test-renderer/component/node.js +0 -0
- /package/dist/common/{SubPackages → src/SubPackages}/react-test-renderer/component/web.js +0 -0
- /package/dist/common/{SubPackages → src/SubPackages}/react-test-renderer/fc/node.js +0 -0
- /package/dist/common/{SubPackages → src/SubPackages}/react-test-renderer/fc/web.js +0 -0
- /package/dist/common/{SubPackages → src/SubPackages}/react-test-renderer/jsx/index.js +0 -0
- /package/dist/common/{SubPackages → src/SubPackages}/react-test-renderer/jsx/node.js +0 -0
- /package/dist/common/{SubPackages → src/SubPackages}/react-test-renderer/jsx/web.js +0 -0
- /package/dist/common/{SubPackages → src/SubPackages}/react-test-renderer/jsx-promised/index.js +0 -0
- /package/dist/common/{SubPackages → src/SubPackages}/react-test-renderer/jsx-promised/node.js +0 -0
- /package/dist/common/{SubPackages → src/SubPackages}/react-test-renderer/jsx-promised/web.js +0 -0
- /package/dist/common/{Types.js → src/Types.js} +0 -0
- /package/dist/common/{esbuildConfigs → src/esbuildConfigs}/eslint-formatter-testeranto.js +0 -0
- /package/dist/common/{esbuildConfigs → src/esbuildConfigs}/featuresPlugin.js +0 -0
- /package/dist/common/{lib → src/lib}/types.js +0 -0
- /package/dist/common/{web.html.js → src/web.html.js} +0 -0
- /package/dist/module/{Footer.js → src/Footer.js} +0 -0
- /package/dist/module/{PM → src/PM}/index.js +0 -0
- /package/dist/module/{ReportServer.js → src/ReportServer.js} +0 -0
- /package/dist/module/{SubPackages → src/SubPackages}/react-dom/jsx/index.js +0 -0
- /package/dist/module/{SubPackages → src/SubPackages}/react-test-renderer/MemoExoticComponent/node.js +0 -0
- /package/dist/module/{SubPackages → src/SubPackages}/react-test-renderer/component/interface.js +0 -0
- /package/dist/module/{SubPackages → src/SubPackages}/react-test-renderer/component/node.js +0 -0
- /package/dist/module/{SubPackages → src/SubPackages}/react-test-renderer/component/web.js +0 -0
- /package/dist/module/{SubPackages → src/SubPackages}/react-test-renderer/fc/node.js +0 -0
- /package/dist/module/{SubPackages → src/SubPackages}/react-test-renderer/fc/web.js +0 -0
- /package/dist/module/{SubPackages → src/SubPackages}/react-test-renderer/jsx/index.js +0 -0
- /package/dist/module/{SubPackages → src/SubPackages}/react-test-renderer/jsx/node.js +0 -0
- /package/dist/module/{SubPackages → src/SubPackages}/react-test-renderer/jsx/web.js +0 -0
- /package/dist/module/{SubPackages → src/SubPackages}/react-test-renderer/jsx-promised/index.js +0 -0
- /package/dist/module/{SubPackages → src/SubPackages}/react-test-renderer/jsx-promised/node.js +0 -0
- /package/dist/module/{SubPackages → src/SubPackages}/react-test-renderer/jsx-promised/web.js +0 -0
- /package/dist/module/{Types.js → src/Types.js} +0 -0
- /package/dist/module/{esbuildConfigs → src/esbuildConfigs}/eslint-formatter-testeranto.js +0 -0
- /package/dist/module/{esbuildConfigs → src/esbuildConfigs}/featuresPlugin.js +0 -0
- /package/dist/module/{lib → src/lib}/types.js +0 -0
- /package/dist/module/{web.html.js → src/web.html.js} +0 -0
- /package/dist/types/{ReportServer.d.ts → src/ReportServer.d.ts} +0 -0
- /package/dist/types/{SubPackages → src/SubPackages}/react-dom/jsx/index.d.ts +0 -0
- /package/dist/types/{SubPackages → src/SubPackages}/react-test-renderer/jsx-promised/index.d.ts +0 -0
- /package/dist/types/{build.d.ts → src/build.d.ts} +0 -0
- /package/dist/types/{esbuildConfigs → src/esbuildConfigs}/eslint-formatter-testeranto.d.ts +0 -0
- /package/dist/types/{esbuildConfigs → src/esbuildConfigs}/featuresPlugin.d.ts +0 -0
- /package/dist/types/{init-docs.d.ts → src/init-docs.d.ts} +0 -0
- /package/dist/types/{run.d.ts → src/run.d.ts} +0 -0
- /package/dist/types/{web.html.d.ts → src/web.html.d.ts} +0 -0
|
@@ -1,19 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
-
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
-
};
|
|
5
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
-
const react_1 = __importDefault(require("react"));
|
|
7
|
-
const Node_js_1 = __importDefault(require("../../../Node.js"));
|
|
8
|
-
exports.default = (testImplementations, testSpecifications, testInput) => {
|
|
9
|
-
return (0, Node_js_1.default)(testInput, testSpecifications, testImplementations, {
|
|
10
|
-
beforeEach: async () => {
|
|
11
|
-
return new Promise((resolve, rej) => {
|
|
12
|
-
resolve(react_1.default.createElement(testInput, {}, []));
|
|
13
|
-
});
|
|
14
|
-
},
|
|
15
|
-
andWhen: function (s, whenCB) {
|
|
16
|
-
return whenCB()(s);
|
|
17
|
-
},
|
|
18
|
-
});
|
|
19
|
-
};
|
|
@@ -1,21 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
-
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
-
};
|
|
5
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
-
exports.testInterface = void 0;
|
|
7
|
-
const react_1 = __importDefault(require("react"));
|
|
8
|
-
exports.testInterface = {
|
|
9
|
-
andWhen: async (s, whenCB) => {
|
|
10
|
-
await whenCB(s());
|
|
11
|
-
return new Promise((resolve, rej) => {
|
|
12
|
-
resolve(react_1.default.createElement(s));
|
|
13
|
-
});
|
|
14
|
-
},
|
|
15
|
-
butThen: async (subject, thenCB) => {
|
|
16
|
-
await thenCB(subject());
|
|
17
|
-
return new Promise((resolve, rej) => {
|
|
18
|
-
resolve(react_1.default.createElement(subject));
|
|
19
|
-
});
|
|
20
|
-
},
|
|
21
|
-
};
|
|
@@ -1,88 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
-
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
-
};
|
|
5
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
-
exports.Stream = exports.renderToStaticNodeStream = exports.renderToStaticMarkup = void 0;
|
|
7
|
-
const react_1 = require("react");
|
|
8
|
-
const server_1 = require("react-dom/server");
|
|
9
|
-
Object.defineProperty(exports, "renderToStaticMarkup", { enumerable: true, get: function () { return server_1.renderToStaticMarkup; } });
|
|
10
|
-
Object.defineProperty(exports, "renderToStaticNodeStream", { enumerable: true, get: function () { return server_1.renderToStaticNodeStream; } });
|
|
11
|
-
const stream_1 = __importDefault(require("stream"));
|
|
12
|
-
exports.Stream = stream_1.default;
|
|
13
|
-
const Node_js_1 = __importDefault(require("../../../Node.js"));
|
|
14
|
-
exports.default = (testImplementations, testSpecifications, testInput) => {
|
|
15
|
-
return (0, Node_js_1.default)(testInput, testSpecifications, testImplementations, {
|
|
16
|
-
beforeEach: async () => {
|
|
17
|
-
return new Promise((resolve, rej) => {
|
|
18
|
-
resolve((0, react_1.createElement)(testInput));
|
|
19
|
-
});
|
|
20
|
-
},
|
|
21
|
-
andWhen: async function (s, whenCB) {
|
|
22
|
-
return whenCB(s);
|
|
23
|
-
},
|
|
24
|
-
butThen: async function (s) {
|
|
25
|
-
return s;
|
|
26
|
-
},
|
|
27
|
-
afterEach: async function () {
|
|
28
|
-
return {};
|
|
29
|
-
},
|
|
30
|
-
afterAll: () => {
|
|
31
|
-
return;
|
|
32
|
-
},
|
|
33
|
-
});
|
|
34
|
-
};
|
|
35
|
-
// type IInput = typeof React.Component;
|
|
36
|
-
// type InitialState = unknown;
|
|
37
|
-
// type IWhenShape = any;
|
|
38
|
-
// type IThenShape = any;
|
|
39
|
-
// type ISelection = string;
|
|
40
|
-
// type IStore = string;
|
|
41
|
-
// type ISubject = string
|
|
42
|
-
// export default <ITestShape extends ITTestShape>(
|
|
43
|
-
// testImplementations: ITestImplementation<
|
|
44
|
-
// InitialState,
|
|
45
|
-
// ISelection,
|
|
46
|
-
// IWhenShape,
|
|
47
|
-
// IThenShape,
|
|
48
|
-
// ITestShape
|
|
49
|
-
// >,
|
|
50
|
-
// testSpecifications: ITestSpecification<
|
|
51
|
-
// ITestShape,
|
|
52
|
-
// ISubject,
|
|
53
|
-
// IStore,
|
|
54
|
-
// ISelection,
|
|
55
|
-
// IThenShape
|
|
56
|
-
// >,
|
|
57
|
-
// testInput: IInput
|
|
58
|
-
// ) => {
|
|
59
|
-
// return Testeranto<
|
|
60
|
-
// ITestShape,
|
|
61
|
-
// IInput,
|
|
62
|
-
// ISubject,
|
|
63
|
-
// IStore,
|
|
64
|
-
// ISelection,
|
|
65
|
-
// IThenShape,
|
|
66
|
-
// IWhenShape,
|
|
67
|
-
// InitialState
|
|
68
|
-
// >(
|
|
69
|
-
// testInput,
|
|
70
|
-
// testSpecifications,
|
|
71
|
-
// testImplementations,
|
|
72
|
-
// {
|
|
73
|
-
// beforeEach: async (
|
|
74
|
-
// element,
|
|
75
|
-
// ndx,
|
|
76
|
-
// testResource,
|
|
77
|
-
// artificer
|
|
78
|
-
// ): Promise<IStore> => {
|
|
79
|
-
// return new Promise((resolve, rej) => {
|
|
80
|
-
// resolve(ReactDOMServer.renderToStaticMarkup(element));
|
|
81
|
-
// });
|
|
82
|
-
// },
|
|
83
|
-
// andWhen: function (s: IStore, whenCB): Promise<ISelection> {
|
|
84
|
-
// throw new Error(`"andWhens" are not permitted`);
|
|
85
|
-
// }
|
|
86
|
-
// },
|
|
87
|
-
// )
|
|
88
|
-
// };
|
|
@@ -1,39 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
-
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
-
};
|
|
5
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
-
exports.Stream = exports.renderToStaticNodeStream = exports.renderToStaticMarkup = void 0;
|
|
7
|
-
const react_1 = require("react");
|
|
8
|
-
const server_1 = require("react-dom/server");
|
|
9
|
-
Object.defineProperty(exports, "renderToStaticMarkup", { enumerable: true, get: function () { return server_1.renderToStaticMarkup; } });
|
|
10
|
-
Object.defineProperty(exports, "renderToStaticNodeStream", { enumerable: true, get: function () { return server_1.renderToStaticNodeStream; } });
|
|
11
|
-
const stream_1 = __importDefault(require("stream"));
|
|
12
|
-
exports.Stream = stream_1.default;
|
|
13
|
-
const Node_js_1 = __importDefault(require("../../../Node.js"));
|
|
14
|
-
exports.default = (testImplementations, testSpecifications, testInput) => {
|
|
15
|
-
return (0, Node_js_1.default)(testInput, testSpecifications, testImplementations, {
|
|
16
|
-
beforeAll: async (prototype, artificer) => {
|
|
17
|
-
return await new Promise((resolve, rej) => {
|
|
18
|
-
resolve(null);
|
|
19
|
-
});
|
|
20
|
-
},
|
|
21
|
-
beforeEach: async () => {
|
|
22
|
-
return new Promise((resolve, rej) => {
|
|
23
|
-
resolve((0, react_1.createElement)(testInput));
|
|
24
|
-
});
|
|
25
|
-
},
|
|
26
|
-
andWhen: async function (s, whenCB) {
|
|
27
|
-
return s;
|
|
28
|
-
},
|
|
29
|
-
butThen: async function (s) {
|
|
30
|
-
return s;
|
|
31
|
-
},
|
|
32
|
-
afterEach: async function (store, ndx, artificer) {
|
|
33
|
-
return {};
|
|
34
|
-
},
|
|
35
|
-
afterAll: (store, artificer) => {
|
|
36
|
-
return;
|
|
37
|
-
},
|
|
38
|
-
});
|
|
39
|
-
};
|
|
@@ -1,128 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
-
if (k2 === undefined) k2 = k;
|
|
4
|
-
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
-
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
-
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
-
}
|
|
8
|
-
Object.defineProperty(o, k2, desc);
|
|
9
|
-
}) : (function(o, m, k, k2) {
|
|
10
|
-
if (k2 === undefined) k2 = k;
|
|
11
|
-
o[k2] = m[k];
|
|
12
|
-
}));
|
|
13
|
-
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
14
|
-
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
15
|
-
}) : function(o, v) {
|
|
16
|
-
o["default"] = v;
|
|
17
|
-
});
|
|
18
|
-
var __importStar = (this && this.__importStar) || (function () {
|
|
19
|
-
var ownKeys = function(o) {
|
|
20
|
-
ownKeys = Object.getOwnPropertyNames || function (o) {
|
|
21
|
-
var ar = [];
|
|
22
|
-
for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
|
|
23
|
-
return ar;
|
|
24
|
-
};
|
|
25
|
-
return ownKeys(o);
|
|
26
|
-
};
|
|
27
|
-
return function (mod) {
|
|
28
|
-
if (mod && mod.__esModule) return mod;
|
|
29
|
-
var result = {};
|
|
30
|
-
if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
|
|
31
|
-
__setModuleDefault(result, mod);
|
|
32
|
-
return result;
|
|
33
|
-
};
|
|
34
|
-
})();
|
|
35
|
-
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
36
|
-
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
37
|
-
};
|
|
38
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
39
|
-
const react_1 = __importStar(require("react"));
|
|
40
|
-
const react_2 = require("react");
|
|
41
|
-
const react_dom_1 = __importDefault(require("react-dom"));
|
|
42
|
-
const Web_js_1 = __importDefault(require("../../../Web.js"));
|
|
43
|
-
const TesterantoComponent = ({ done, innerComp, }) => {
|
|
44
|
-
const myContainer = (0, react_1.useRef)(null);
|
|
45
|
-
(0, react_1.useEffect)(() => {
|
|
46
|
-
console.log("useEffect called!", myContainer.current);
|
|
47
|
-
done(myContainer.current);
|
|
48
|
-
}, []);
|
|
49
|
-
return react_1.default.createElement("div", { ref: myContainer }, innerComp());
|
|
50
|
-
};
|
|
51
|
-
exports.default = (testImplementations, testSpecifications, testInput) => {
|
|
52
|
-
const t = (0, Web_js_1.default)(testInput, testSpecifications, testImplementations, {
|
|
53
|
-
beforeAll: async (reactElement, itr) => {
|
|
54
|
-
return await new Promise((resolve, rej) => {
|
|
55
|
-
const htmlElement = document.getElementById("root");
|
|
56
|
-
if (htmlElement) {
|
|
57
|
-
const domRoot = react_dom_1.default.createRoot(htmlElement);
|
|
58
|
-
domRoot.render((0, react_2.createElement)(TesterantoComponent, {
|
|
59
|
-
// ...initialProps,
|
|
60
|
-
innerComp: reactElement,
|
|
61
|
-
done: (reactElement) => {
|
|
62
|
-
resolve({
|
|
63
|
-
htmlElement,
|
|
64
|
-
reactElement,
|
|
65
|
-
domRoot,
|
|
66
|
-
});
|
|
67
|
-
},
|
|
68
|
-
}, []));
|
|
69
|
-
// resolve({ htmlElement });
|
|
70
|
-
}
|
|
71
|
-
});
|
|
72
|
-
},
|
|
73
|
-
beforeEach: async (subject) => {
|
|
74
|
-
return subject;
|
|
75
|
-
// return new Promise((resolve, rej) => {
|
|
76
|
-
// resolve(subject);
|
|
77
|
-
// // const tc = TesterantoComponent({
|
|
78
|
-
// // innerComp: () =>
|
|
79
|
-
// // testInput({
|
|
80
|
-
// // port: 3003,
|
|
81
|
-
// // address: "some-address",
|
|
82
|
-
// // secretKey: "someSecretKey",
|
|
83
|
-
// // abi: "foo",
|
|
84
|
-
// // }),
|
|
85
|
-
// // done: (reactElement: any) => {
|
|
86
|
-
// // console.log("mark9");
|
|
87
|
-
// // resolve(reactElement);
|
|
88
|
-
// // // process.nextTick(() => {
|
|
89
|
-
// // // resolve(reactElement);
|
|
90
|
-
// // // });
|
|
91
|
-
// // },
|
|
92
|
-
// // });
|
|
93
|
-
// // console.log("mark9", tc);
|
|
94
|
-
// // createPortal(tc, subject.domRoot);
|
|
95
|
-
// });
|
|
96
|
-
},
|
|
97
|
-
andWhen: async function (s, whenCB, tr, utils) {
|
|
98
|
-
return whenCB(s, utils);
|
|
99
|
-
// return new Promise(async (resolve, rej) => {
|
|
100
|
-
// // resolve(await whenCB(s, utils));
|
|
101
|
-
// // process.nextTick(() => {
|
|
102
|
-
// // resolve(whenCB()(s));
|
|
103
|
-
// // });
|
|
104
|
-
// });
|
|
105
|
-
},
|
|
106
|
-
butThen: async function (s, thenCB, tr, utils) {
|
|
107
|
-
return new Promise((resolve, rej) => {
|
|
108
|
-
resolve(thenCB(s, utils));
|
|
109
|
-
});
|
|
110
|
-
},
|
|
111
|
-
afterEach: async function (store, ndx, artificer) {
|
|
112
|
-
return new Promise((resolve, rej) => {
|
|
113
|
-
resolve({});
|
|
114
|
-
});
|
|
115
|
-
},
|
|
116
|
-
afterAll: (store, artificer) => {
|
|
117
|
-
return new Promise((resolve, rej) => {
|
|
118
|
-
resolve({});
|
|
119
|
-
});
|
|
120
|
-
},
|
|
121
|
-
});
|
|
122
|
-
document.addEventListener("DOMContentLoaded", function () {
|
|
123
|
-
const rootElement = document.getElementById("root");
|
|
124
|
-
if (rootElement) {
|
|
125
|
-
}
|
|
126
|
-
});
|
|
127
|
-
return t;
|
|
128
|
-
};
|
package/dist/common/build.js
DELETED
|
@@ -1,222 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
-
if (k2 === undefined) k2 = k;
|
|
4
|
-
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
-
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
-
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
-
}
|
|
8
|
-
Object.defineProperty(o, k2, desc);
|
|
9
|
-
}) : (function(o, m, k, k2) {
|
|
10
|
-
if (k2 === undefined) k2 = k;
|
|
11
|
-
o[k2] = m[k];
|
|
12
|
-
}));
|
|
13
|
-
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
14
|
-
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
15
|
-
}) : function(o, v) {
|
|
16
|
-
o["default"] = v;
|
|
17
|
-
});
|
|
18
|
-
var __importStar = (this && this.__importStar) || (function () {
|
|
19
|
-
var ownKeys = function(o) {
|
|
20
|
-
ownKeys = Object.getOwnPropertyNames || function (o) {
|
|
21
|
-
var ar = [];
|
|
22
|
-
for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
|
|
23
|
-
return ar;
|
|
24
|
-
};
|
|
25
|
-
return ownKeys(o);
|
|
26
|
-
};
|
|
27
|
-
return function (mod) {
|
|
28
|
-
if (mod && mod.__esModule) return mod;
|
|
29
|
-
var result = {};
|
|
30
|
-
if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
|
|
31
|
-
__setModuleDefault(result, mod);
|
|
32
|
-
return result;
|
|
33
|
-
};
|
|
34
|
-
})();
|
|
35
|
-
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
36
|
-
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
37
|
-
};
|
|
38
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
39
|
-
const fs_1 = __importDefault(require("fs"));
|
|
40
|
-
const path_1 = __importDefault(require("path"));
|
|
41
|
-
const readline_1 = __importDefault(require("readline"));
|
|
42
|
-
const glob_1 = require("glob");
|
|
43
|
-
const esbuild_1 = __importDefault(require("esbuild"));
|
|
44
|
-
const node_js_1 = __importDefault(require("./esbuildConfigs/node.js"));
|
|
45
|
-
const web_js_1 = __importDefault(require("./esbuildConfigs/web.js"));
|
|
46
|
-
const web_html_js_1 = __importDefault(require("./web.html.js"));
|
|
47
|
-
readline_1.default.emitKeypressEvents(process.stdin);
|
|
48
|
-
if (process.stdin.isTTY)
|
|
49
|
-
process.stdin.setRawMode(true);
|
|
50
|
-
const getRunnables = (tests, payload = {
|
|
51
|
-
nodeEntryPoints: {},
|
|
52
|
-
webEntryPoints: {},
|
|
53
|
-
}) => {
|
|
54
|
-
return tests.reduce((pt, cv, cndx, cry) => {
|
|
55
|
-
if (cv[1] === "node") {
|
|
56
|
-
pt.nodeEntryPoints[cv[0]] = path_1.default.resolve(`./docs/node/${cv[0].split(".").slice(0, -1).concat("mjs").join(".")}`);
|
|
57
|
-
}
|
|
58
|
-
else if (cv[1] === "web") {
|
|
59
|
-
pt.webEntryPoints[cv[0]] = path_1.default.resolve(`./docs/web/${cv[0].split(".").slice(0, -1).concat("mjs").join(".")}`);
|
|
60
|
-
}
|
|
61
|
-
if (cv[3].length) {
|
|
62
|
-
getRunnables(cv[3], payload);
|
|
63
|
-
}
|
|
64
|
-
return pt;
|
|
65
|
-
}, payload);
|
|
66
|
-
};
|
|
67
|
-
Promise.resolve(`${process.cwd() + "/" + process.argv[2]}`).then(s => __importStar(require(s))).then(async (module) => {
|
|
68
|
-
const rawConfig = module.default;
|
|
69
|
-
const getSecondaryEndpointsPoints = (runtime) => {
|
|
70
|
-
const meta = (ts, st) => {
|
|
71
|
-
ts.forEach((t) => {
|
|
72
|
-
if (t[1] === runtime) {
|
|
73
|
-
st.add(t[0]);
|
|
74
|
-
}
|
|
75
|
-
if (Array.isArray(t[3])) {
|
|
76
|
-
meta(t[3], st);
|
|
77
|
-
}
|
|
78
|
-
});
|
|
79
|
-
return st;
|
|
80
|
-
};
|
|
81
|
-
return Array.from(meta(config.tests, new Set()));
|
|
82
|
-
};
|
|
83
|
-
const config = Object.assign(Object.assign({}, rawConfig), { buildDir: process.cwd() + "/" + rawConfig.outdir });
|
|
84
|
-
let nodeDone = false;
|
|
85
|
-
let webDone = false;
|
|
86
|
-
let mode = config.devMode ? "DEV" : "PROD";
|
|
87
|
-
let status = "build";
|
|
88
|
-
// let pm: PM_Main | undefined = new PM_Main(config);
|
|
89
|
-
// const fileHashes = {};
|
|
90
|
-
const { nodeEntryPoints, webEntryPoints } = getRunnables(config.tests);
|
|
91
|
-
const onNodeDone = () => {
|
|
92
|
-
nodeDone = true;
|
|
93
|
-
onDone();
|
|
94
|
-
};
|
|
95
|
-
const onWebDone = () => {
|
|
96
|
-
webDone = true;
|
|
97
|
-
onDone();
|
|
98
|
-
};
|
|
99
|
-
const onDone = async () => {
|
|
100
|
-
if (nodeDone && webDone) {
|
|
101
|
-
status = "built";
|
|
102
|
-
}
|
|
103
|
-
if (nodeDone && webDone && status === "built") {
|
|
104
|
-
// Object.entries(nodeEntryPoints).forEach(([k, outputFile]) => {
|
|
105
|
-
// console.log("watching", outputFile);
|
|
106
|
-
// try {
|
|
107
|
-
// watch(outputFile, async (filename) => {
|
|
108
|
-
// const hash = await fileHash(outputFile);
|
|
109
|
-
// if (fileHashes[k] !== hash) {
|
|
110
|
-
// fileHashes[k] = hash;
|
|
111
|
-
// console.log(`< ${filename} `);
|
|
112
|
-
// pm.launchNode(k, outputFile);
|
|
113
|
-
// }
|
|
114
|
-
// });
|
|
115
|
-
// } catch (e) {
|
|
116
|
-
// console.error(e);
|
|
117
|
-
// }
|
|
118
|
-
// });
|
|
119
|
-
// Object.entries(webEntryPoints).forEach(([k, outputFile]) => {
|
|
120
|
-
// console.log("watching", outputFile);
|
|
121
|
-
// watch(outputFile, async (filename) => {
|
|
122
|
-
// const hash = await fileHash(outputFile);
|
|
123
|
-
// console.log(`< ${filename} ${hash}`);
|
|
124
|
-
// if (fileHashes[k] !== hash) {
|
|
125
|
-
// fileHashes[k] = hash;
|
|
126
|
-
// pm.launchWeb(k, outputFile);
|
|
127
|
-
// }
|
|
128
|
-
// });
|
|
129
|
-
// });
|
|
130
|
-
}
|
|
131
|
-
if (nodeDone && webDone && mode === "PROD") {
|
|
132
|
-
console.log("Testeranto-EsBuild is all done. Goodbye!");
|
|
133
|
-
process.exit();
|
|
134
|
-
}
|
|
135
|
-
else {
|
|
136
|
-
if (mode === "PROD") {
|
|
137
|
-
console.log("waiting for tests to finish");
|
|
138
|
-
console.log(JSON.stringify({
|
|
139
|
-
nodeDone: nodeDone,
|
|
140
|
-
webDone: webDone,
|
|
141
|
-
mode: mode,
|
|
142
|
-
}, null, 2));
|
|
143
|
-
}
|
|
144
|
-
else {
|
|
145
|
-
console.log("waiting for tests to change");
|
|
146
|
-
}
|
|
147
|
-
if (config.devMode) {
|
|
148
|
-
console.log("ready and watching for changes...");
|
|
149
|
-
}
|
|
150
|
-
else {
|
|
151
|
-
// pm.shutDown();
|
|
152
|
-
}
|
|
153
|
-
////////////////////////////////////////////////////////////////////////////////
|
|
154
|
-
}
|
|
155
|
-
};
|
|
156
|
-
console.log(`Press 'q' to shutdown gracefully. Press 'x' to shutdown forcefully.`);
|
|
157
|
-
process.stdin.on("keypress", (str, key) => {
|
|
158
|
-
if (key.name === "q") {
|
|
159
|
-
console.log("Testeranto-Build is shutting down...");
|
|
160
|
-
mode = "PROD";
|
|
161
|
-
onDone();
|
|
162
|
-
}
|
|
163
|
-
if (key.name === "x") {
|
|
164
|
-
console.log("Testeranto-Build is shutting down forcefully...");
|
|
165
|
-
process.exit(-1);
|
|
166
|
-
}
|
|
167
|
-
});
|
|
168
|
-
fs_1.default.writeFileSync(`${config.outdir}/testeranto.json`, JSON.stringify(config, null, 2));
|
|
169
|
-
Promise.resolve(Promise.all([...getSecondaryEndpointsPoints("web")].map(async (sourceFilePath) => {
|
|
170
|
-
const sourceFileSplit = sourceFilePath.split("/");
|
|
171
|
-
const sourceDir = sourceFileSplit.slice(0, -1);
|
|
172
|
-
const sourceFileName = sourceFileSplit[sourceFileSplit.length - 1];
|
|
173
|
-
const sourceFileNameMinusJs = sourceFileName
|
|
174
|
-
.split(".")
|
|
175
|
-
.slice(0, -1)
|
|
176
|
-
.join(".");
|
|
177
|
-
const htmlFilePath = path_1.default.normalize(`${process.cwd()}/${config.outdir}/web/${sourceDir.join("/")}/${sourceFileNameMinusJs}.html`);
|
|
178
|
-
const jsfilePath = `./${sourceFileNameMinusJs}.mjs`;
|
|
179
|
-
return fs_1.default.promises
|
|
180
|
-
.mkdir(path_1.default.dirname(htmlFilePath), { recursive: true })
|
|
181
|
-
.then((x) => fs_1.default.writeFileSync(htmlFilePath, (0, web_html_js_1.default)(jsfilePath, htmlFilePath)));
|
|
182
|
-
})));
|
|
183
|
-
(0, glob_1.glob)(`./${config.outdir}/chunk-*.mjs`, {
|
|
184
|
-
ignore: "node_modules/**",
|
|
185
|
-
}).then((chunks) => {
|
|
186
|
-
chunks.forEach((chunk) => {
|
|
187
|
-
fs_1.default.unlinkSync(chunk);
|
|
188
|
-
});
|
|
189
|
-
});
|
|
190
|
-
await Promise.all([
|
|
191
|
-
esbuild_1.default
|
|
192
|
-
.context((0, node_js_1.default)(config, Object.keys(nodeEntryPoints)))
|
|
193
|
-
.then(async (nodeContext) => {
|
|
194
|
-
if (config.devMode) {
|
|
195
|
-
await nodeContext.watch().then((v) => {
|
|
196
|
-
onNodeDone();
|
|
197
|
-
});
|
|
198
|
-
}
|
|
199
|
-
else {
|
|
200
|
-
nodeContext.rebuild().then((v) => {
|
|
201
|
-
onNodeDone();
|
|
202
|
-
});
|
|
203
|
-
}
|
|
204
|
-
return nodeContext;
|
|
205
|
-
}),
|
|
206
|
-
esbuild_1.default
|
|
207
|
-
.context((0, web_js_1.default)(config, Object.keys(webEntryPoints)))
|
|
208
|
-
.then(async (webContext) => {
|
|
209
|
-
if (config.devMode) {
|
|
210
|
-
await webContext.watch().then((v) => {
|
|
211
|
-
onWebDone();
|
|
212
|
-
});
|
|
213
|
-
}
|
|
214
|
-
else {
|
|
215
|
-
webContext.rebuild().then((v) => {
|
|
216
|
-
onWebDone();
|
|
217
|
-
});
|
|
218
|
-
}
|
|
219
|
-
return webContext;
|
|
220
|
-
}),
|
|
221
|
-
]);
|
|
222
|
-
});
|
package/dist/common/init-docs.js
DELETED
|
@@ -1,53 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
-
if (k2 === undefined) k2 = k;
|
|
4
|
-
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
-
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
-
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
-
}
|
|
8
|
-
Object.defineProperty(o, k2, desc);
|
|
9
|
-
}) : (function(o, m, k, k2) {
|
|
10
|
-
if (k2 === undefined) k2 = k;
|
|
11
|
-
o[k2] = m[k];
|
|
12
|
-
}));
|
|
13
|
-
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
14
|
-
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
15
|
-
}) : function(o, v) {
|
|
16
|
-
o["default"] = v;
|
|
17
|
-
});
|
|
18
|
-
var __importStar = (this && this.__importStar) || (function () {
|
|
19
|
-
var ownKeys = function(o) {
|
|
20
|
-
ownKeys = Object.getOwnPropertyNames || function (o) {
|
|
21
|
-
var ar = [];
|
|
22
|
-
for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
|
|
23
|
-
return ar;
|
|
24
|
-
};
|
|
25
|
-
return ownKeys(o);
|
|
26
|
-
};
|
|
27
|
-
return function (mod) {
|
|
28
|
-
if (mod && mod.__esModule) return mod;
|
|
29
|
-
var result = {};
|
|
30
|
-
if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
|
|
31
|
-
__setModuleDefault(result, mod);
|
|
32
|
-
return result;
|
|
33
|
-
};
|
|
34
|
-
})();
|
|
35
|
-
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
36
|
-
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
37
|
-
};
|
|
38
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
39
|
-
const fs_1 = __importDefault(require("fs"));
|
|
40
|
-
const Init_1 = __importDefault(require("./Init"));
|
|
41
|
-
console.log("Initializing a testeranto project");
|
|
42
|
-
if (!process.argv[2]) {
|
|
43
|
-
console.log("You didn't pass a config file, so I will create one for you.");
|
|
44
|
-
fs_1.default.writeFileSync("testeranto.mts", fs_1.default.readFileSync("node_modules/testeranto/src/defaultConfig.ts"));
|
|
45
|
-
Promise.resolve(`${process.cwd() + "/" + "testeranto.mts"}`).then(s => __importStar(require(s))).then((module) => {
|
|
46
|
-
(0, Init_1.default)(module.default);
|
|
47
|
-
});
|
|
48
|
-
}
|
|
49
|
-
else {
|
|
50
|
-
Promise.resolve(`${process.cwd() + "/" + process.argv[2]}`).then(s => __importStar(require(s))).then((module) => {
|
|
51
|
-
(0, Init_1.default)(module.default);
|
|
52
|
-
});
|
|
53
|
-
}
|
|
@@ -1,24 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
-
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
-
};
|
|
5
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
-
const http_1 = __importDefault(require("http"));
|
|
7
|
-
exports.default = async (port) => new Promise((resolve, reject) => {
|
|
8
|
-
let json = "";
|
|
9
|
-
const request = http_1.default.request({
|
|
10
|
-
host: "127.0.0.1",
|
|
11
|
-
path: "/json/version",
|
|
12
|
-
port,
|
|
13
|
-
}, (response) => {
|
|
14
|
-
response.on("error", reject);
|
|
15
|
-
response.on("data", (chunk) => {
|
|
16
|
-
json += chunk.toString();
|
|
17
|
-
});
|
|
18
|
-
response.on("end", () => {
|
|
19
|
-
resolve(JSON.parse(json));
|
|
20
|
-
});
|
|
21
|
-
});
|
|
22
|
-
request.on("error", reject);
|
|
23
|
-
request.end();
|
|
24
|
-
});
|
package/dist/common/utils.js
DELETED
|
@@ -1,43 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
-
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
-
};
|
|
5
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
-
exports.promptPather = exports.bddExitCodePather = exports.bddPather = exports.lintExitCodePather = exports.lintPather = exports.tscExitCodePather = exports.tscPather = exports.destinationOfRuntime = void 0;
|
|
7
|
-
const path_1 = __importDefault(require("path"));
|
|
8
|
-
const destinationOfRuntime = (f, r, configs) => {
|
|
9
|
-
return path_1.default
|
|
10
|
-
.normalize(`${configs.buildDir}/${r}/${f}`)
|
|
11
|
-
.split(".")
|
|
12
|
-
.slice(0, -1)
|
|
13
|
-
.join(".");
|
|
14
|
-
};
|
|
15
|
-
exports.destinationOfRuntime = destinationOfRuntime;
|
|
16
|
-
const tscPather = (entryPoint, platform) => {
|
|
17
|
-
return path_1.default.join("./docs/", platform, entryPoint.split(".").slice(0, -1).join("."), `type_errors.txt`);
|
|
18
|
-
};
|
|
19
|
-
exports.tscPather = tscPather;
|
|
20
|
-
const tscExitCodePather = (entryPoint, platform) => {
|
|
21
|
-
return path_1.default.join("./docs/", platform, entryPoint.split(".").slice(0, -1).join("."), `type_errors.txt`);
|
|
22
|
-
};
|
|
23
|
-
exports.tscExitCodePather = tscExitCodePather;
|
|
24
|
-
const lintPather = (entryPoint, platform) => {
|
|
25
|
-
return path_1.default.join("./docs/", platform, entryPoint.split(".").slice(0, -1).join("."), `lint_errors.json`);
|
|
26
|
-
};
|
|
27
|
-
exports.lintPather = lintPather;
|
|
28
|
-
const lintExitCodePather = (entryPoint, platform) => {
|
|
29
|
-
return path_1.default.join("./docs/", platform, entryPoint.split(".").slice(0, -1).join("."), `lint_errors.txt`);
|
|
30
|
-
};
|
|
31
|
-
exports.lintExitCodePather = lintExitCodePather;
|
|
32
|
-
const bddPather = (entryPoint, platform) => {
|
|
33
|
-
return path_1.default.join("./docs/", platform, entryPoint.split(".").slice(0, -1).join("."), `tests.json`);
|
|
34
|
-
};
|
|
35
|
-
exports.bddPather = bddPather;
|
|
36
|
-
const bddExitCodePather = (entryPoint, platform) => {
|
|
37
|
-
return path_1.default.join("./docs/", platform, entryPoint.split(".").slice(0, -1).join("."), `bdd_errors.txt`);
|
|
38
|
-
};
|
|
39
|
-
exports.bddExitCodePather = bddExitCodePather;
|
|
40
|
-
const promptPather = (entryPoint, platform) => {
|
|
41
|
-
return path_1.default.join("./docs/", platform, entryPoint.split(".").slice(0, -1).join("."), `prompt.txt`);
|
|
42
|
-
};
|
|
43
|
-
exports.promptPather = promptPather;
|