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.
Files changed (396) hide show
  1. package/.aider.chat.history.md +97001 -0
  2. package/.aider.conf.yml +5 -0
  3. package/.aider.input.history +9 -0
  4. package/.aider.tags.cache.v3/b7/e6/5be87b62aeaf2bc244ff41c1b61a.val +0 -0
  5. package/.aider.tags.cache.v3/cache.db +0 -0
  6. package/.aider.tags.cache.v3/e3/e6/3501625caf5d5eb171f0d248462e.val +0 -0
  7. package/.aider.tags.cache.v3/ec/c0/161c249c35be853cc40cf11f9267.val +0 -0
  8. package/README.md +15 -1
  9. package/bundle.js +1 -1
  10. package/dist/common/src/Init.js +31 -0
  11. package/dist/common/src/Node.js +49 -0
  12. package/dist/common/src/PM/base.js +230 -0
  13. package/dist/common/src/PM/main.js +1026 -0
  14. package/dist/common/src/PM/node.js +161 -0
  15. package/dist/common/{PM/node.js → src/PM/pure.js} +27 -18
  16. package/dist/common/{PM → src/PM}/web.js +14 -47
  17. package/dist/common/{Node.js → src/Pure.js} +11 -9
  18. package/dist/common/{SubPackages/react/component/web.js → src/SubPackages/react/component/index.js} +5 -4
  19. package/dist/common/src/SubPackages/react/component/node.js +10 -0
  20. package/dist/common/src/SubPackages/react/component/pure.js +10 -0
  21. package/dist/common/{SubPackages/react/jsx → src/SubPackages/react/component}/web.js +2 -2
  22. package/dist/common/src/SubPackages/react/jsx/index.js +64 -0
  23. package/dist/common/src/SubPackages/react/jsx/pure.js +10 -0
  24. package/dist/common/src/SubPackages/react/jsx/web.js +10 -0
  25. package/dist/common/{SubPackages/react-dom/component/web.js → src/SubPackages/react-dom/component/dynamic.js} +8 -14
  26. package/dist/common/src/SubPackages/react-dom/component/node.js +10 -0
  27. package/dist/common/src/SubPackages/react-dom/component/pure.js +10 -0
  28. package/dist/common/src/SubPackages/react-dom/component/static.js +26 -0
  29. package/dist/common/src/SubPackages/react-dom/component/web.js +16 -0
  30. package/dist/common/src/SubPackages/react-dom/jsx/dynamic.js +31 -0
  31. package/dist/common/src/SubPackages/react-dom/jsx/node.js +10 -0
  32. package/dist/common/src/SubPackages/react-dom/jsx/pure.js +10 -0
  33. package/dist/common/src/SubPackages/react-dom/jsx/static.js +59 -0
  34. package/dist/common/src/SubPackages/react-dom/jsx/web.js +16 -0
  35. package/dist/common/src/SubPackages/react-test-renderer/component/index.js +15 -0
  36. package/dist/common/src/SubPackages/react-test-renderer/component/pure.js +8 -0
  37. package/dist/common/src/SubPackages/react-test-renderer/component/test/implementation.js +57 -0
  38. package/dist/common/src/SubPackages/react-test-renderer/component/test/node.js +10 -0
  39. package/dist/common/src/SubPackages/react-test-renderer/component/test/pure.js +10 -0
  40. package/dist/common/src/SubPackages/react-test-renderer/component/test/web.js +10 -0
  41. package/dist/common/src/SubPackages/react-test-renderer/jsx/pure.js +10 -0
  42. package/dist/common/{Web.js → src/Web.js} +1 -4
  43. package/dist/common/src/build.js +223 -0
  44. package/dist/common/{defaultConfig.js → src/defaultConfig.js} +1 -3
  45. package/dist/common/{esbuildConfigs → src/esbuildConfigs}/index.js +1 -1
  46. package/dist/common/{esbuildConfigs → src/esbuildConfigs}/inputFilesPlugin.js +7 -3
  47. package/dist/common/{esbuildConfigs → src/esbuildConfigs}/node.js +7 -4
  48. package/dist/common/src/esbuildConfigs/pure.js +41 -0
  49. package/dist/common/{esbuildConfigs → src/esbuildConfigs}/web.js +8 -5
  50. package/dist/common/src/examples/react/component/index.js +33 -0
  51. package/dist/common/src/examples/react/component/test.js +36 -0
  52. package/dist/common/src/init-docs.js +9 -0
  53. package/dist/common/{lib → src/lib}/abstractBase.js +99 -95
  54. package/dist/common/{lib → src/lib}/basebuilder.js +24 -20
  55. package/dist/common/{lib → src/lib}/classBuilder.js +8 -5
  56. package/dist/common/{lib → src/lib}/core.js +10 -60
  57. package/dist/common/{lib → src/lib}/index.js +7 -2
  58. package/dist/common/{run.js → src/run.js} +12 -4
  59. package/dist/common/src/utils.js +65 -0
  60. package/dist/common/testeranto.config.js +41 -0
  61. package/dist/common/tsconfig.common.tsbuildinfo +1 -1
  62. package/dist/module/src/Init.js +26 -0
  63. package/dist/module/src/Node.js +42 -0
  64. package/dist/module/src/PM/base.js +223 -0
  65. package/dist/module/src/PM/main.js +986 -0
  66. package/dist/module/src/PM/node.js +154 -0
  67. package/dist/module/{PM/node.js → src/PM/pure.js} +25 -16
  68. package/dist/module/{PM → src/PM}/web.js +14 -47
  69. package/dist/module/src/Project.js +120 -0
  70. package/dist/module/{Node.js → src/Pure.js} +9 -7
  71. package/dist/module/{ReportClient.js → src/ReportClient.js} +1 -1
  72. package/dist/module/{SubPackages/react/component/web.js → src/SubPackages/react/component/index.js} +3 -4
  73. package/dist/module/src/SubPackages/react/component/node.js +5 -0
  74. package/dist/module/src/SubPackages/react/component/pure.js +5 -0
  75. package/dist/module/{SubPackages/react/jsx → src/SubPackages/react/component}/web.js +3 -3
  76. package/dist/module/src/SubPackages/react/jsx/index.js +58 -0
  77. package/dist/module/{SubPackages → src/SubPackages}/react/jsx/node.js +1 -1
  78. package/dist/module/src/SubPackages/react/jsx/pure.js +5 -0
  79. package/dist/module/src/SubPackages/react/jsx/web.js +5 -0
  80. package/dist/module/{SubPackages/react-dom/component/web.js → src/SubPackages/react-dom/component/dynamic.js} +5 -13
  81. package/dist/module/src/SubPackages/react-dom/component/node.js +5 -0
  82. package/dist/module/src/SubPackages/react-dom/component/pure.js +5 -0
  83. package/dist/module/src/SubPackages/react-dom/component/static.js +22 -0
  84. package/dist/module/src/SubPackages/react-dom/component/web.js +11 -0
  85. package/dist/module/{SubPackages/react-dom/jsx/node.js → src/SubPackages/react-dom/jsx/dynamic.js} +3 -7
  86. package/dist/module/src/SubPackages/react-dom/jsx/node.js +5 -0
  87. package/dist/module/src/SubPackages/react-dom/jsx/pure.js +5 -0
  88. package/dist/module/src/SubPackages/react-dom/jsx/static.js +53 -0
  89. package/dist/module/src/SubPackages/react-dom/jsx/web.js +11 -0
  90. package/dist/module/src/SubPackages/react-test-renderer/component/index.js +14 -0
  91. package/dist/module/src/SubPackages/react-test-renderer/component/pure.js +3 -0
  92. package/dist/module/src/SubPackages/react-test-renderer/component/test/implementation.js +54 -0
  93. package/dist/module/src/SubPackages/react-test-renderer/component/test/node.js +5 -0
  94. package/dist/module/src/SubPackages/react-test-renderer/component/test/pure.js +5 -0
  95. package/dist/module/src/SubPackages/react-test-renderer/component/test/web.js +5 -0
  96. package/dist/module/src/SubPackages/react-test-renderer/jsx/pure.js +5 -0
  97. package/dist/module/{TestReport.js → src/TestReport.js} +26 -14
  98. package/dist/module/{Web.js → src/Web.js} +1 -4
  99. package/dist/module/src/build.js +185 -0
  100. package/dist/module/{defaultConfig.js → src/defaultConfig.js} +1 -3
  101. package/dist/module/{esbuildConfigs → src/esbuildConfigs}/index.js +1 -1
  102. package/dist/module/{esbuildConfigs → src/esbuildConfigs}/inputFilesPlugin.js +7 -3
  103. package/dist/module/{esbuildConfigs → src/esbuildConfigs}/node.js +7 -4
  104. package/dist/module/src/esbuildConfigs/pure.js +36 -0
  105. package/dist/module/{esbuildConfigs → src/esbuildConfigs}/web.js +8 -5
  106. package/dist/module/src/examples/react/component/index.js +26 -0
  107. package/dist/module/src/examples/react/component/test.js +32 -0
  108. package/dist/module/src/init-docs.js +4 -0
  109. package/dist/module/{lib → src/lib}/abstractBase.js +99 -95
  110. package/dist/module/{lib → src/lib}/basebuilder.js +24 -20
  111. package/dist/module/{lib → src/lib}/classBuilder.js +8 -5
  112. package/dist/module/{lib → src/lib}/core.js +10 -60
  113. package/dist/module/{lib → src/lib}/index.js +7 -2
  114. package/dist/module/{run.js → src/run.js} +12 -4
  115. package/dist/module/src/utils.js +53 -0
  116. package/dist/module/testeranto.config.js +39 -0
  117. package/dist/module/tsconfig.module.tsbuildinfo +1 -1
  118. package/dist/prebuild/Project.css +11367 -0
  119. package/dist/prebuild/Project.js +24643 -0
  120. package/dist/prebuild/ReportClient.js +1 -1
  121. package/dist/prebuild/TestReport.js +13 -12
  122. package/dist/prebuild/build.mjs +217 -106
  123. package/dist/prebuild/init-docs.mjs +29 -83
  124. package/dist/prebuild/run.mjs +803 -686
  125. package/dist/tsconfig.tsbuildinfo +1 -1
  126. package/dist/types/src/Init.d.ts +2 -0
  127. package/dist/types/src/Node.d.ts +9 -0
  128. package/dist/types/src/PM/base.d.ts +34 -0
  129. package/dist/types/{PM → src/PM}/index.d.ts +21 -22
  130. package/dist/types/src/PM/main.d.ts +47 -0
  131. package/dist/types/src/PM/node.d.ts +38 -0
  132. package/dist/types/{PM/node.d.ts → src/PM/pure.d.ts} +16 -17
  133. package/dist/types/{PM → src/PM}/web.d.ts +10 -15
  134. package/dist/types/src/Pure.d.ts +9 -0
  135. package/dist/types/src/SubPackages/react/component/index.d.ts +4 -0
  136. package/dist/types/src/SubPackages/react/component/node.d.ts +4 -0
  137. package/dist/types/src/SubPackages/react/component/pure.d.ts +4 -0
  138. package/dist/types/src/SubPackages/react/component/web.d.ts +4 -0
  139. package/dist/types/src/SubPackages/react/jsx/index.d.ts +5 -0
  140. package/dist/types/src/SubPackages/react/jsx/node.d.ts +4 -0
  141. package/dist/types/src/SubPackages/react/jsx/pure.d.ts +4 -0
  142. package/dist/types/src/SubPackages/react/jsx/web.d.ts +4 -0
  143. package/dist/types/src/SubPackages/react-dom/component/dynamic.d.ts +20 -0
  144. package/dist/types/src/SubPackages/react-dom/component/node.d.ts +4 -0
  145. package/dist/types/src/SubPackages/react-dom/component/pure.d.ts +4 -0
  146. package/dist/types/src/SubPackages/react-dom/component/static.d.ts +9 -0
  147. package/dist/types/src/SubPackages/react-dom/component/web.d.ts +4 -0
  148. package/dist/types/src/SubPackages/react-dom/jsx/dynamic.d.ts +5 -0
  149. package/dist/types/src/SubPackages/react-dom/jsx/node.d.ts +4 -0
  150. package/dist/types/src/SubPackages/react-dom/jsx/pure.d.ts +4 -0
  151. package/dist/types/src/SubPackages/react-dom/jsx/static.d.ts +5 -0
  152. package/dist/types/src/SubPackages/react-dom/jsx/web.d.ts +5 -0
  153. package/dist/types/{SubPackages → src/SubPackages}/react-test-renderer/MemoExoticComponent/node.d.ts +1 -1
  154. package/dist/types/src/SubPackages/react-test-renderer/component/index.d.ts +5 -0
  155. package/dist/types/src/SubPackages/react-test-renderer/component/interface.d.ts +3 -0
  156. package/dist/types/src/SubPackages/react-test-renderer/component/node.d.ts +4 -0
  157. package/dist/types/src/SubPackages/react-test-renderer/component/pure.d.ts +4 -0
  158. package/dist/types/src/SubPackages/react-test-renderer/component/test/implementation.d.ts +4 -0
  159. package/dist/types/src/SubPackages/react-test-renderer/component/test/node.d.ts +3 -0
  160. package/dist/types/src/SubPackages/react-test-renderer/component/test/pure.d.ts +4 -0
  161. package/dist/types/src/SubPackages/react-test-renderer/component/test/web.d.ts +3 -0
  162. package/dist/types/src/SubPackages/react-test-renderer/component/web.d.ts +4 -0
  163. package/dist/types/{SubPackages → src/SubPackages}/react-test-renderer/fc/node.d.ts +1 -1
  164. package/dist/types/{SubPackages → src/SubPackages}/react-test-renderer/fc/web.d.ts +1 -1
  165. package/dist/types/src/SubPackages/react-test-renderer/jsx/index.d.ts +11 -0
  166. package/dist/types/src/SubPackages/react-test-renderer/jsx/node.d.ts +4 -0
  167. package/dist/types/src/SubPackages/react-test-renderer/jsx/pure.d.ts +4 -0
  168. package/dist/types/src/SubPackages/react-test-renderer/jsx/web.d.ts +4 -0
  169. package/dist/types/{SubPackages → src/SubPackages}/react-test-renderer/jsx-promised/node.d.ts +1 -1
  170. package/dist/types/{SubPackages → src/SubPackages}/react-test-renderer/jsx-promised/web.d.ts +1 -1
  171. package/dist/types/src/Types.d.ts +88 -0
  172. package/dist/types/src/Web.d.ts +9 -0
  173. package/dist/types/src/defaultConfig.d.ts +3 -0
  174. package/dist/types/src/esbuildConfigs/index.d.ts +4 -0
  175. package/dist/types/{esbuildConfigs → src/esbuildConfigs}/inputFilesPlugin.d.ts +2 -1
  176. package/dist/types/src/esbuildConfigs/node.d.ts +4 -0
  177. package/dist/types/src/esbuildConfigs/pure.d.ts +4 -0
  178. package/dist/types/src/esbuildConfigs/web.d.ts +4 -0
  179. package/dist/types/src/examples/react/component/index.d.ts +13 -0
  180. package/dist/types/src/examples/react/component/test.d.ts +17 -0
  181. package/dist/types/{lib → src/lib}/abstractBase.d.ts +47 -34
  182. package/dist/types/{lib → src/lib}/basebuilder.d.ts +7 -9
  183. package/dist/types/src/lib/classBuilder.d.ts +9 -0
  184. package/dist/types/src/lib/core.d.ts +7 -0
  185. package/dist/types/{lib → src/lib}/index.d.ts +14 -36
  186. package/dist/types/src/lib/types.d.ts +15 -0
  187. package/dist/types/src/utils.d.ts +18 -0
  188. package/dist/types/testeranto.config.d.ts +3 -0
  189. package/dist/types/tsconfig.types.tsbuildinfo +1 -1
  190. package/eslint.config.mjs +111 -0
  191. package/package.json +33 -12
  192. package/src/Init.ts +29 -75
  193. package/src/Node.ts +42 -46
  194. package/src/PM/base.ts +299 -0
  195. package/src/PM/index.ts +28 -21
  196. package/src/PM/main.ts +569 -819
  197. package/src/PM/node.ts +88 -44
  198. package/src/PM/pure.ts +209 -0
  199. package/src/PM/web.ts +19 -121
  200. package/src/Project.tsx +200 -0
  201. package/src/Pure.ts +69 -0
  202. package/src/ReportClient.tsx +8 -3
  203. package/src/SubPackages/react/component/index.ts +28 -0
  204. package/src/SubPackages/react/component/node.ts +12 -82
  205. package/src/SubPackages/react/component/pure.ts +17 -0
  206. package/src/SubPackages/react/component/web.ts +12 -81
  207. package/src/SubPackages/react/jsx/index.ts +56 -52
  208. package/src/SubPackages/react/jsx/node.ts +12 -29
  209. package/src/SubPackages/react/jsx/pure.ts +23 -0
  210. package/src/SubPackages/react/jsx/web.ts +17 -36
  211. package/src/SubPackages/react-dom/component/dynamic.ts +107 -0
  212. package/src/SubPackages/react-dom/component/node.ts +11 -116
  213. package/src/SubPackages/react-dom/component/pure.ts +17 -0
  214. package/src/SubPackages/react-dom/component/static.ts +41 -0
  215. package/src/SubPackages/react-dom/component/web.ts +7 -113
  216. package/src/SubPackages/react-dom/jsx/dynamic.ts +46 -0
  217. package/src/SubPackages/react-dom/jsx/node.ts +10 -58
  218. package/src/SubPackages/react-dom/jsx/pure.ts +18 -0
  219. package/src/SubPackages/react-dom/jsx/static.ts +87 -0
  220. package/src/SubPackages/react-dom/jsx/web.ts +7 -135
  221. package/src/SubPackages/react-test-renderer/component/index.ts +27 -51
  222. package/src/SubPackages/react-test-renderer/component/interface.ts +7 -5
  223. package/src/SubPackages/react-test-renderer/component/node.ts +7 -25
  224. package/src/SubPackages/react-test-renderer/component/pure.ts +18 -0
  225. package/src/SubPackages/react-test-renderer/component/test/implementation.ts +63 -0
  226. package/src/SubPackages/react-test-renderer/component/test/node.ts +14 -0
  227. package/src/SubPackages/react-test-renderer/component/test/pure.ts +14 -0
  228. package/src/SubPackages/react-test-renderer/component/test/web.ts +14 -0
  229. package/src/SubPackages/react-test-renderer/component/web.ts +7 -23
  230. package/src/SubPackages/react-test-renderer/jsx/index.ts +13 -46
  231. package/src/SubPackages/react-test-renderer/jsx/node.ts +9 -15
  232. package/src/SubPackages/react-test-renderer/jsx/pure.ts +31 -0
  233. package/src/SubPackages/react-test-renderer/jsx/web.ts +9 -14
  234. package/src/TestReport.tsx +37 -19
  235. package/src/Types.ts +114 -140
  236. package/src/Web.ts +13 -48
  237. package/src/build.ts +153 -143
  238. package/src/defaultConfig.ts +3 -5
  239. package/src/esbuildConfigs/index.ts +3 -3
  240. package/src/esbuildConfigs/inputFilesPlugin.ts +9 -7
  241. package/src/esbuildConfigs/node.ts +10 -6
  242. package/src/esbuildConfigs/pure.ts +72 -0
  243. package/src/esbuildConfigs/web.ts +11 -7
  244. package/src/examples/react/component/index.tsx +35 -0
  245. package/src/examples/react/component/test.ts +83 -0
  246. package/src/init-docs.ts +2 -15
  247. package/src/lib/abstractBase.ts +188 -260
  248. package/src/lib/basebuilder.ts +47 -48
  249. package/src/lib/classBuilder.ts +28 -35
  250. package/src/lib/core.ts +35 -102
  251. package/src/lib/index.ts +37 -65
  252. package/src/lib/types.ts +23 -98
  253. package/src/run.ts +18 -5
  254. package/src/utils.ts +73 -40
  255. package/testeranto/Project.css +11367 -0
  256. package/testeranto/Project.js +24643 -0
  257. package/testeranto/ReportClient.css +11367 -0
  258. package/testeranto/ReportClient.js +24641 -0
  259. package/testeranto/TestReport.css +11367 -0
  260. package/testeranto/TestReport.js +27485 -0
  261. package/testeranto/bundles/node/react/metafile.json +627 -0
  262. package/testeranto/bundles/node/react/src/SubPackages/react-test-renderer/component/test/node.mjs +24687 -0
  263. package/testeranto/bundles/pure/react/metafile.json +8 -0
  264. package/testeranto/bundles/pure/react/src/SubPackages/react-test-renderer/component/test/pure.mjs +24625 -0
  265. package/testeranto/bundles/web/react/metafile.json +8 -0
  266. package/testeranto/bundles/web/react/src/SubPackages/react-test-renderer/component/test/web.html +19 -0
  267. package/testeranto/bundles/web/react/src/SubPackages/react-test-renderer/component/test/web.mjs +21290 -0
  268. package/testeranto/index.html +28 -0
  269. package/testeranto/reports/react/config.json +22 -0
  270. package/testeranto/reports/react/index.html +24 -0
  271. package/testeranto/reports/react/src/SubPackages/react-test-renderer/component/test/node/node/console_log.txt +0 -0
  272. package/testeranto/reports/react/src/SubPackages/react-test-renderer/component/test/pure/pure/bdd_errors.txt +1 -0
  273. package/testeranto/reports/react/src/SubPackages/react-test-renderer/component/test/pure/pure/featurePrompt.txt +0 -0
  274. package/testeranto/reports/react/src/SubPackages/react-test-renderer/component/test/pure/pure/lint_errors.json +3381 -0
  275. package/testeranto/reports/react/src/SubPackages/react-test-renderer/component/test/pure/pure/littleBoard.html +20 -0
  276. package/testeranto/reports/react/src/SubPackages/react-test-renderer/component/test/pure/pure/log.txt +40 -0
  277. package/testeranto/reports/react/src/SubPackages/react-test-renderer/component/test/pure/pure/prompt.txt +24 -0
  278. package/testeranto/reports/react/src/SubPackages/react-test-renderer/component/test/pure/pure/tests.json +132 -0
  279. package/testeranto/reports/react/src/SubPackages/react-test-renderer/component/test/pure/pure/type_errors.txt +17 -0
  280. package/testeranto/reports/react/src/SubPackages/react-test-renderer/component/test/web/web/bdd_errors.txt +1 -0
  281. package/testeranto/reports/react/src/SubPackages/react-test-renderer/component/test/web/web/console_log.txt +1 -0
  282. package/testeranto/reports/react/src/SubPackages/react-test-renderer/component/test/web/web/lint_errors.json +2947 -0
  283. package/testeranto/reports/react/src/SubPackages/react-test-renderer/component/test/web/web/littleBoard.html +20 -0
  284. package/testeranto/reports/react/src/SubPackages/react-test-renderer/component/test/web/web/log.txt +40 -0
  285. package/testeranto/reports/react/src/SubPackages/react-test-renderer/component/test/web/web/prompt.txt +23 -0
  286. package/testeranto/reports/react/src/SubPackages/react-test-renderer/component/test/web/web/tests.json +132 -0
  287. package/testeranto/reports/react/src/SubPackages/react-test-renderer/component/test/web/web/type_errors.txt +18 -0
  288. package/testeranto/reports/react/summary.json +8 -0
  289. package/testeranto.config.ts +45 -0
  290. package/tsc.log +53 -76
  291. package/type-fix.txt +2 -0
  292. package/dist/common/Init.js +0 -68
  293. package/dist/common/PM/main.js +0 -1176
  294. package/dist/common/SubPackages/react/component/node.js +0 -19
  295. package/dist/common/SubPackages/react/jsx/index.js +0 -21
  296. package/dist/common/SubPackages/react-dom/component/node.js +0 -88
  297. package/dist/common/SubPackages/react-dom/jsx/node.js +0 -39
  298. package/dist/common/SubPackages/react-dom/jsx/web.js +0 -128
  299. package/dist/common/SubPackages/react-test-renderer/component/index.js +0 -2
  300. package/dist/common/build.js +0 -222
  301. package/dist/common/init-docs.js +0 -53
  302. package/dist/common/puppeteerConfiger.js +0 -24
  303. package/dist/common/utils.js +0 -43
  304. package/dist/module/Init.js +0 -63
  305. package/dist/module/PM/main.js +0 -1136
  306. package/dist/module/SubPackages/react/component/node.js +0 -14
  307. package/dist/module/SubPackages/react/jsx/index.js +0 -15
  308. package/dist/module/SubPackages/react-dom/component/node.js +0 -80
  309. package/dist/module/SubPackages/react-dom/jsx/web.js +0 -90
  310. package/dist/module/SubPackages/react-test-renderer/component/index.js +0 -1
  311. package/dist/module/build.js +0 -184
  312. package/dist/module/init-docs.js +0 -15
  313. package/dist/module/puppeteerConfiger.js +0 -19
  314. package/dist/module/utils.js +0 -29
  315. package/dist/types/Init.d.ts +0 -2
  316. package/dist/types/Node.d.ts +0 -12
  317. package/dist/types/PM/main.d.ts +0 -66
  318. package/dist/types/SubPackages/react/component/node.d.ts +0 -7
  319. package/dist/types/SubPackages/react/component/web.d.ts +0 -7
  320. package/dist/types/SubPackages/react/jsx/index.d.ts +0 -12
  321. package/dist/types/SubPackages/react/jsx/node.d.ts +0 -4
  322. package/dist/types/SubPackages/react/jsx/web.d.ts +0 -4
  323. package/dist/types/SubPackages/react-dom/component/node.d.ts +0 -11
  324. package/dist/types/SubPackages/react-dom/component/web.d.ts +0 -20
  325. package/dist/types/SubPackages/react-dom/jsx/node.d.ts +0 -7
  326. package/dist/types/SubPackages/react-dom/jsx/web.d.ts +0 -5
  327. package/dist/types/SubPackages/react-test-renderer/component/index.d.ts +0 -13
  328. package/dist/types/SubPackages/react-test-renderer/component/interface.d.ts +0 -9
  329. package/dist/types/SubPackages/react-test-renderer/component/node.d.ts +0 -4
  330. package/dist/types/SubPackages/react-test-renderer/component/web.d.ts +0 -4
  331. package/dist/types/SubPackages/react-test-renderer/jsx/index.d.ts +0 -16
  332. package/dist/types/SubPackages/react-test-renderer/jsx/node.d.ts +0 -9
  333. package/dist/types/SubPackages/react-test-renderer/jsx/web.d.ts +0 -9
  334. package/dist/types/Types.d.ts +0 -61
  335. package/dist/types/Web.d.ts +0 -9
  336. package/dist/types/defaultConfig.d.ts +0 -3
  337. package/dist/types/esbuildConfigs/index.d.ts +0 -4
  338. package/dist/types/esbuildConfigs/node.d.ts +0 -4
  339. package/dist/types/esbuildConfigs/web.d.ts +0 -4
  340. package/dist/types/lib/classBuilder.d.ts +0 -7
  341. package/dist/types/lib/core.d.ts +0 -7
  342. package/dist/types/lib/types.d.ts +0 -14
  343. package/dist/types/puppeteerConfiger.d.ts +0 -4
  344. package/dist/types/utils.d.ts +0 -15
  345. package/src/puppeteerConfiger.ts +0 -26
  346. /package/dist/common/{PM → src/PM}/index.js +0 -0
  347. /package/dist/common/{ReportServer.js → src/ReportServer.js} +0 -0
  348. /package/dist/common/{SubPackages → src/SubPackages}/react/jsx/node.js +0 -0
  349. /package/dist/common/{SubPackages → src/SubPackages}/react-dom/jsx/index.js +0 -0
  350. /package/dist/common/{SubPackages → src/SubPackages}/react-test-renderer/MemoExoticComponent/node.js +0 -0
  351. /package/dist/common/{SubPackages → src/SubPackages}/react-test-renderer/component/interface.js +0 -0
  352. /package/dist/common/{SubPackages → src/SubPackages}/react-test-renderer/component/node.js +0 -0
  353. /package/dist/common/{SubPackages → src/SubPackages}/react-test-renderer/component/web.js +0 -0
  354. /package/dist/common/{SubPackages → src/SubPackages}/react-test-renderer/fc/node.js +0 -0
  355. /package/dist/common/{SubPackages → src/SubPackages}/react-test-renderer/fc/web.js +0 -0
  356. /package/dist/common/{SubPackages → src/SubPackages}/react-test-renderer/jsx/index.js +0 -0
  357. /package/dist/common/{SubPackages → src/SubPackages}/react-test-renderer/jsx/node.js +0 -0
  358. /package/dist/common/{SubPackages → src/SubPackages}/react-test-renderer/jsx/web.js +0 -0
  359. /package/dist/common/{SubPackages → src/SubPackages}/react-test-renderer/jsx-promised/index.js +0 -0
  360. /package/dist/common/{SubPackages → src/SubPackages}/react-test-renderer/jsx-promised/node.js +0 -0
  361. /package/dist/common/{SubPackages → src/SubPackages}/react-test-renderer/jsx-promised/web.js +0 -0
  362. /package/dist/common/{Types.js → src/Types.js} +0 -0
  363. /package/dist/common/{esbuildConfigs → src/esbuildConfigs}/eslint-formatter-testeranto.js +0 -0
  364. /package/dist/common/{esbuildConfigs → src/esbuildConfigs}/featuresPlugin.js +0 -0
  365. /package/dist/common/{lib → src/lib}/types.js +0 -0
  366. /package/dist/common/{web.html.js → src/web.html.js} +0 -0
  367. /package/dist/module/{Footer.js → src/Footer.js} +0 -0
  368. /package/dist/module/{PM → src/PM}/index.js +0 -0
  369. /package/dist/module/{ReportServer.js → src/ReportServer.js} +0 -0
  370. /package/dist/module/{SubPackages → src/SubPackages}/react-dom/jsx/index.js +0 -0
  371. /package/dist/module/{SubPackages → src/SubPackages}/react-test-renderer/MemoExoticComponent/node.js +0 -0
  372. /package/dist/module/{SubPackages → src/SubPackages}/react-test-renderer/component/interface.js +0 -0
  373. /package/dist/module/{SubPackages → src/SubPackages}/react-test-renderer/component/node.js +0 -0
  374. /package/dist/module/{SubPackages → src/SubPackages}/react-test-renderer/component/web.js +0 -0
  375. /package/dist/module/{SubPackages → src/SubPackages}/react-test-renderer/fc/node.js +0 -0
  376. /package/dist/module/{SubPackages → src/SubPackages}/react-test-renderer/fc/web.js +0 -0
  377. /package/dist/module/{SubPackages → src/SubPackages}/react-test-renderer/jsx/index.js +0 -0
  378. /package/dist/module/{SubPackages → src/SubPackages}/react-test-renderer/jsx/node.js +0 -0
  379. /package/dist/module/{SubPackages → src/SubPackages}/react-test-renderer/jsx/web.js +0 -0
  380. /package/dist/module/{SubPackages → src/SubPackages}/react-test-renderer/jsx-promised/index.js +0 -0
  381. /package/dist/module/{SubPackages → src/SubPackages}/react-test-renderer/jsx-promised/node.js +0 -0
  382. /package/dist/module/{SubPackages → src/SubPackages}/react-test-renderer/jsx-promised/web.js +0 -0
  383. /package/dist/module/{Types.js → src/Types.js} +0 -0
  384. /package/dist/module/{esbuildConfigs → src/esbuildConfigs}/eslint-formatter-testeranto.js +0 -0
  385. /package/dist/module/{esbuildConfigs → src/esbuildConfigs}/featuresPlugin.js +0 -0
  386. /package/dist/module/{lib → src/lib}/types.js +0 -0
  387. /package/dist/module/{web.html.js → src/web.html.js} +0 -0
  388. /package/dist/types/{ReportServer.d.ts → src/ReportServer.d.ts} +0 -0
  389. /package/dist/types/{SubPackages → src/SubPackages}/react-dom/jsx/index.d.ts +0 -0
  390. /package/dist/types/{SubPackages → src/SubPackages}/react-test-renderer/jsx-promised/index.d.ts +0 -0
  391. /package/dist/types/{build.d.ts → src/build.d.ts} +0 -0
  392. /package/dist/types/{esbuildConfigs → src/esbuildConfigs}/eslint-formatter-testeranto.d.ts +0 -0
  393. /package/dist/types/{esbuildConfigs → src/esbuildConfigs}/featuresPlugin.d.ts +0 -0
  394. /package/dist/types/{init-docs.d.ts → src/init-docs.d.ts} +0 -0
  395. /package/dist/types/{run.d.ts → src/run.d.ts} +0 -0
  396. /package/dist/types/{web.html.d.ts → src/web.html.d.ts} +0 -0
@@ -1,37 +1,20 @@
1
1
  import Testeranto from "../../../Node.js";
2
- import { Ibdd_in, Ibdd_out, IPartialInterface } from "../../../Types";
3
-
4
2
  import {
5
- ITestImpl,
6
- ITestSpec,
7
- IInput,
8
- testInterface as baseInterface,
9
- } from "./index.js";
3
+ IPartialInterface,
4
+ ITestImplementation,
5
+ ITestSpecification,
6
+ OT,
7
+ } from "../../../Types";
8
+
9
+ import { testInterface as baseInterface, I } from "./index.js";
10
10
 
11
- export default <
12
- I extends Ibdd_in<
13
- unknown,
14
- unknown,
15
- unknown,
16
- unknown,
17
- unknown,
18
- unknown,
19
- unknown
20
- >,
21
- O extends Ibdd_out<
22
- Record<string, any>,
23
- Record<string, any>,
24
- Record<string, any>,
25
- Record<string, any>,
26
- Record<string, any>
27
- >
28
- >(
29
- testImplementations: ITestImpl<I, O>,
30
- testSpecifications: ITestSpec<I, O>,
31
- testInput: IInput,
11
+ export default <O extends OT, M = {}>(
12
+ testImplementations: ITestImplementation<I, O, M>,
13
+ testSpecifications: ITestSpecification<I, O>,
14
+ testInput: I["iinput"],
32
15
  testInterface: IPartialInterface<I> = baseInterface
33
16
  ) => {
34
- return Testeranto<I, O>(
17
+ return Testeranto<I, O, M>(
35
18
  testInput,
36
19
  testSpecifications,
37
20
  testImplementations,
@@ -0,0 +1,23 @@
1
+ import Testeranto from "../../../Pure.js";
2
+ import {
3
+ IPartialInterface,
4
+ ITestImplementation,
5
+ ITestSpecification,
6
+ OT,
7
+ } from "../../../Types";
8
+
9
+ import { testInterface as baseInterface, I } from "./index.js";
10
+
11
+ export default <O extends OT, M = {}>(
12
+ testImplementations: ITestImplementation<I, O, M>,
13
+ testSpecifications: ITestSpecification<I, O>,
14
+ testInput: I["iinput"],
15
+ testInterface: IPartialInterface<I> = baseInterface
16
+ ) => {
17
+ return Testeranto<I, O, M>(
18
+ testInput,
19
+ testSpecifications,
20
+ testImplementations,
21
+ testInterface
22
+ );
23
+ };
@@ -1,43 +1,24 @@
1
+ import Testeranto from "../../../Web.js";
2
+
1
3
  import {
2
- Ibdd_in,
3
- Ibdd_out,
4
4
  IPartialInterface,
5
- IPartialWebInterface,
5
+ ITestImplementation,
6
+ ITestSpecification,
7
+ OT,
6
8
  } from "../../../Types";
7
- import Testeranto from "../../../Web.js";
8
9
 
9
- import {
10
- ITestImpl,
11
- ITestSpec,
12
- IInput,
13
- testInterface as baseInterface,
14
- } from "./index.js";
10
+ import { testInterface as baseInterface, I } from "./index.js";
15
11
 
16
- export default <
17
- I extends Ibdd_in<
18
- unknown,
19
- unknown,
20
- unknown,
21
- unknown,
22
- unknown,
23
- unknown,
24
- unknown
25
- >,
26
- O extends Ibdd_out<
27
- Record<string, any>,
28
- Record<string, any>,
29
- Record<string, any>,
30
- Record<string, any>,
31
- Record<string, any>
32
- >
33
- >(
34
- testImplementations: ITestImpl<I, O>,
35
- testSpecifications: ITestSpec<I, O>,
36
- testInput: IInput,
37
- testInterface: IPartialWebInterface<I>
12
+ export default <O extends OT, M = {}>(
13
+ testImplementations: ITestImplementation<I, O, M>,
14
+ testSpecifications: ITestSpecification<I, O>,
15
+ testInput: I["iinput"],
16
+ testInterface: IPartialInterface<I> = baseInterface
38
17
  ) => {
39
- return Testeranto<I, O>(testInput, testSpecifications, testImplementations, {
40
- ...baseInterface,
41
- ...testInterface,
42
- });
18
+ return Testeranto<I, O, M>(
19
+ testInput,
20
+ testSpecifications,
21
+ testImplementations,
22
+ testInterface
23
+ );
43
24
  };
@@ -0,0 +1,107 @@
1
+ import React from "react";
2
+ import ReactDom from "react-dom/client";
3
+
4
+ import { Ibdd_in, IPartialInterface, ITestInterface } from "../../../Types";
5
+
6
+ export type IInput = typeof React.Component;
7
+
8
+ export type ISelection = {
9
+ htmlElement: HTMLElement;
10
+ reactElement: any; //CElement<any, any>;
11
+ domRoot: ReactDom.Root;
12
+ };
13
+
14
+ export type IStore = {
15
+ htmlElement: HTMLElement;
16
+ reactElement: any; //CElement<any, any>,
17
+ domRoot: ReactDom.Root;
18
+ };
19
+
20
+ export type ISubject = {
21
+ htmlElement: HTMLElement;
22
+ // reactElement: any; //CElement<any, any>,
23
+ domRoot: ReactDom.Root;
24
+ };
25
+
26
+ export type I = Ibdd_in<
27
+ IInput,
28
+ ISubject,
29
+ ISelection,
30
+ IStore,
31
+ (s: IStore) => IStore,
32
+ (s: IStore) => IStore,
33
+ (s: IStore) => IStore
34
+ >;
35
+
36
+ export const testInterfacer: (
37
+ testInput: IInput
38
+ ) => IPartialInterface<I> = () => {
39
+ class TesterantoComponent extends React.Component {
40
+ done: (t: TesterantoComponent) => void;
41
+ constructor(props) {
42
+ super(props);
43
+ this.done = props.done;
44
+ }
45
+ componentDidMount() {
46
+ super.componentDidMount && super.componentDidMount();
47
+ return this.done(this);
48
+ }
49
+ }
50
+
51
+ return {
52
+ beforeAll: async (subject, artificer) => {
53
+ return await new Promise((resolve, rej) => {
54
+ const htmlElement = document.getElementById("root");
55
+ if (htmlElement) {
56
+ const domRoot = ReactDom.createRoot(htmlElement);
57
+ resolve({ domRoot, htmlElement });
58
+ }
59
+ });
60
+ },
61
+ beforeEach: async (
62
+ { domRoot, htmlElement },
63
+ initialValues,
64
+ testResource,
65
+ artificer
66
+ ) => {
67
+ return new Promise(async (resolve, rej) => {
68
+ domRoot.render(
69
+ createElement(
70
+ TesterantoComponent,
71
+ {
72
+ ...initialValues,
73
+ done: (reactElement) => {
74
+ resolve({
75
+ htmlElement,
76
+ reactElement,
77
+ domRoot,
78
+ });
79
+ },
80
+ },
81
+ []
82
+ )
83
+ );
84
+ });
85
+ },
86
+ andWhen: async function (s, whenCB) {
87
+ return whenCB(s);
88
+ },
89
+ butThen: async function (s, thenCB) {
90
+ return thenCB(s);
91
+ },
92
+ afterEach:
93
+ testInterface?.afterEach ||
94
+ async function (store, ndx, utils) {
95
+ return store;
96
+ },
97
+
98
+ afterAll: async (store, utils) => {
99
+ // setTimeout(() => {
100
+ // console.log("This will run after 1 second");
101
+ // }, 1000); // 1000 milliseconds = 1 second
102
+ // store.htmlElement.remove();
103
+ // store.htmlElement = document.createElement("root");
104
+ return store;
105
+ },
106
+ };
107
+ };
@@ -1,122 +1,17 @@
1
- import React, { ReactNode, createElement } from "react";
2
- import {
3
- renderToStaticMarkup,
4
- renderToStaticNodeStream,
5
- } from "react-dom/server";
6
- import Stream from "stream";
7
-
8
1
  import Testeranto from "../../../Node.js";
2
+ import { ITestImplementation, ITestSpecification, OT } from "../../../Types";
9
3
 
10
- import {
11
- Ibdd_in,
12
- Ibdd_out,
13
- ITestImplementation,
14
- ITestSpecification,
15
- } from "../../../Types";
16
-
17
- type IInput = typeof React.Component;
18
-
19
- export type ISelection = ReactNode;
20
- export type IStore = ReactNode;
21
- export type ISubject = ReactNode;
4
+ import { I, testInterfacer } from "./static.js";
22
5
 
23
- export { renderToStaticMarkup, renderToStaticNodeStream, Stream };
24
-
25
- export default <
26
- I extends Ibdd_in<
27
- IInput,
28
- ISubject,
29
- IStore,
30
- ISelection,
31
- unknown,
32
- (s: IStore) => IStore,
33
- unknown
34
- >,
35
- O extends Ibdd_out<
36
- Record<string, any>,
37
- Record<string, any>,
38
- Record<string, any>,
39
- Record<string, any>,
40
- Record<string, any>
41
- >
42
- >(
43
- testImplementations: ITestImplementation<I, O>,
6
+ export default <O extends OT, M>(
7
+ testImplementations: ITestImplementation<I, O, M>,
44
8
  testSpecifications: ITestSpecification<I, O>,
45
- testInput: IInput
9
+ testInput: I["iinput"]
46
10
  ) => {
47
- return Testeranto<I, O>(testInput, testSpecifications, testImplementations, {
48
- beforeEach: async (): Promise<IStore> => {
49
- return new Promise((resolve, rej) => {
50
- resolve(createElement(testInput));
51
- });
52
- },
53
- andWhen: async function (s, whenCB) {
54
- return whenCB(s);
55
- },
56
- butThen: async function (s) {
57
- return s;
58
- },
59
- afterEach: async function () {
60
- return {};
61
- },
62
- afterAll: () => {
63
- return;
64
- },
65
- });
11
+ return Testeranto<I, O, M>(
12
+ testInput,
13
+ testSpecifications,
14
+ testImplementations,
15
+ testInterfacer(testInput)
16
+ );
66
17
  };
67
-
68
- // type IInput = typeof React.Component;
69
- // type InitialState = unknown;
70
- // type IWhenShape = any;
71
- // type IThenShape = any;
72
- // type ISelection = string;
73
- // type IStore = string;
74
- // type ISubject = string
75
-
76
- // export default <ITestShape extends ITTestShape>(
77
- // testImplementations: ITestImplementation<
78
- // InitialState,
79
- // ISelection,
80
- // IWhenShape,
81
- // IThenShape,
82
- // ITestShape
83
- // >,
84
- // testSpecifications: ITestSpecification<
85
- // ITestShape,
86
- // ISubject,
87
- // IStore,
88
- // ISelection,
89
- // IThenShape
90
- // >,
91
- // testInput: IInput
92
- // ) => {
93
- // return Testeranto<
94
- // ITestShape,
95
- // IInput,
96
- // ISubject,
97
- // IStore,
98
- // ISelection,
99
- // IThenShape,
100
- // IWhenShape,
101
- // InitialState
102
- // >(
103
- // testInput,
104
- // testSpecifications,
105
- // testImplementations,
106
- // {
107
- // beforeEach: async (
108
- // element,
109
- // ndx,
110
- // testResource,
111
- // artificer
112
- // ): Promise<IStore> => {
113
- // return new Promise((resolve, rej) => {
114
- // resolve(ReactDOMServer.renderToStaticMarkup(element));
115
- // });
116
- // },
117
- // andWhen: function (s: IStore, whenCB): Promise<ISelection> {
118
- // throw new Error(`"andWhens" are not permitted`);
119
- // }
120
- // },
121
- // )
122
- // };
@@ -0,0 +1,17 @@
1
+ import Testeranto from "../../../Pure.js";
2
+ import { ITestImplementation, ITestSpecification, OT } from "../../../Types";
3
+
4
+ import { I, testInterfacer } from "./static.js";
5
+
6
+ export default <O extends OT, M>(
7
+ testImplementations: ITestImplementation<I, O, M>,
8
+ testSpecifications: ITestSpecification<I, O>,
9
+ testInput: I["iinput"]
10
+ ) => {
11
+ return Testeranto<I, O, M>(
12
+ testInput,
13
+ testSpecifications,
14
+ testImplementations,
15
+ testInterfacer(testInput)
16
+ );
17
+ };
@@ -0,0 +1,41 @@
1
+ import React, { ReactNode, createElement } from "react";
2
+
3
+ import { Ibdd_in } from "../../../Types";
4
+
5
+ type IInput = typeof React.Component;
6
+
7
+ export type ISelection = ReactNode;
8
+ export type IStore = ReactNode;
9
+ export type ISubject = ReactNode;
10
+
11
+ export type I = Ibdd_in<
12
+ IInput,
13
+ ISubject,
14
+ IStore,
15
+ ISelection,
16
+ unknown,
17
+ (s: IStore) => IStore,
18
+ unknown
19
+ >;
20
+
21
+ export const testInterfacer: (testInput: any) => any = (testInput) => {
22
+ return {
23
+ beforeEach: async (): Promise<IStore> => {
24
+ return new Promise((resolve, rej) => {
25
+ resolve(createElement(testInput));
26
+ });
27
+ },
28
+ andWhen: async function (s, whenCB) {
29
+ return whenCB(s);
30
+ },
31
+ butThen: async function (s) {
32
+ return s;
33
+ },
34
+ afterEach: async function () {
35
+ return {};
36
+ },
37
+ afterAll: () => {
38
+ return;
39
+ },
40
+ };
41
+ };
@@ -1,130 +1,24 @@
1
- import React, { CElement, createElement } from "react";
2
- import ReactDom from "react-dom/client";
3
-
4
1
  import Testeranto from "../../../Web.js";
5
2
  import {
6
- Ibdd_in,
7
- Ibdd_out,
8
- IPartialInterface,
9
3
  IPartialWebInterface,
10
4
  ITestImplementation,
11
5
  ITestSpecification,
6
+ OT,
12
7
  } from "../../../Types";
13
8
 
14
- type IInput = typeof React.Component;
15
- type ISelection = {
16
- htmlElement: HTMLElement;
17
- reactElement: any; //CElement<any, any>;
18
- domRoot: ReactDom.Root;
19
- };
20
-
21
- export type IStore = {
22
- htmlElement: HTMLElement;
23
- reactElement: any; //CElement<any, any>,
24
- domRoot: ReactDom.Root;
25
- };
26
-
27
- type ISubject = {
28
- htmlElement: HTMLElement;
29
- // reactElement: any; //CElement<any, any>,
30
- domRoot: ReactDom.Root;
31
- };
9
+ import { I, IInput } from "./dynamic.js";
32
10
 
33
- export default <
34
- I extends Ibdd_in<
35
- IInput,
36
- ISubject,
37
- ISelection,
38
- IStore,
39
- (s: IStore) => IStore,
40
- (s: IStore) => IStore,
41
- (s: IStore) => IStore
42
- >,
43
- O extends Ibdd_out<
44
- Record<string, any>,
45
- Record<string, any>,
46
- Record<string, any>,
47
- Record<string, any>,
48
- Record<string, any>
49
- >
50
- >(
11
+ export default <O extends OT, M>(
51
12
  testInput: IInput,
52
13
  testSpecifications: ITestSpecification<I, O>,
53
- testImplementations: ITestImplementation<I, O>,
54
- testInterface?: IPartialWebInterface<any>
14
+ testImplementations: ITestImplementation<I, O, M>,
15
+ testInterface: IPartialWebInterface<I>
55
16
  ) => {
56
- class TesterantoComponent extends testInput {
57
- done: (t: TesterantoComponent) => void;
58
- constructor(props) {
59
- super(props);
60
- this.done = props.done;
61
- }
62
- componentDidMount() {
63
- super.componentDidMount && super.componentDidMount();
64
- return this.done(this);
65
- }
66
- }
67
-
68
- const t = Testeranto<I, O>(
17
+ const t = Testeranto<I, O, M>(
69
18
  testInput,
70
19
  testSpecifications,
71
20
  testImplementations,
72
- {
73
- beforeAll: async (subject, artificer): Promise<ISubject> => {
74
- return await new Promise((resolve, rej) => {
75
- const htmlElement = document.getElementById("root");
76
- if (htmlElement) {
77
- const domRoot = ReactDom.createRoot(htmlElement);
78
- resolve({ domRoot, htmlElement });
79
- }
80
- });
81
- },
82
- beforeEach: async (
83
- { domRoot, htmlElement },
84
- initialValues,
85
- testResource,
86
- artificer
87
- ): Promise<IStore> => {
88
- return new Promise(async (resolve, rej) => {
89
- domRoot.render(
90
- createElement(
91
- TesterantoComponent,
92
- {
93
- ...initialValues,
94
- done: (reactElement) => {
95
- resolve({
96
- htmlElement,
97
- reactElement,
98
- domRoot,
99
- });
100
- },
101
- },
102
- []
103
- )
104
- );
105
- });
106
- },
107
- andWhen: async function (s, whenCB) {
108
- return whenCB(s);
109
- },
110
- butThen: async function (s, thenCB) {
111
- return thenCB(s);
112
- },
113
- afterEach:
114
- testInterface?.afterEach ||
115
- async function (store: IStore, ndx, utils) {
116
- return store;
117
- },
118
-
119
- afterAll: async (store: IStore, utils) => {
120
- // setTimeout(() => {
121
- // console.log("This will run after 1 second");
122
- // }, 1000); // 1000 milliseconds = 1 second
123
- // store.htmlElement.remove();
124
- // store.htmlElement = document.createElement("root");
125
- return store;
126
- },
127
- }
21
+ testInterface
128
22
  );
129
23
 
130
24
  document.addEventListener("DOMContentLoaded", function () {
@@ -0,0 +1,46 @@
1
+ import { createElement } from "react";
2
+
3
+ import { Ibdd_in, IPartialInterface } from "../../../Types";
4
+
5
+ import { IInput, ISelection, IStore, IWhenShape, IThenShape } from ".";
6
+
7
+ export type ISubject = HTMLElement;
8
+
9
+ export type I = Ibdd_in<
10
+ IInput,
11
+ ISubject,
12
+ ISelection,
13
+ IStore,
14
+ unknown,
15
+ IWhenShape,
16
+ IThenShape
17
+ >;
18
+
19
+ export const testInterfacer = (
20
+ testInput: I["iinput"]
21
+ ): IPartialInterface<I> => {
22
+ return {
23
+ beforeAll: async (prototype, artificer) => {
24
+ return await new Promise((resolve, rej) => {
25
+ resolve(null);
26
+ });
27
+ },
28
+ beforeEach: async () => {
29
+ return new Promise((resolve, rej) => {
30
+ resolve(createElement(testInput));
31
+ });
32
+ },
33
+ andWhen: async function (s, whenCB) {
34
+ return s;
35
+ },
36
+ butThen: async function (s) {
37
+ return s;
38
+ },
39
+ afterEach: async function (store, ndx, artificer) {
40
+ return {};
41
+ },
42
+ afterAll: (store, artificer) => {
43
+ return;
44
+ },
45
+ };
46
+ };
@@ -1,66 +1,18 @@
1
- import { createElement } from "react";
2
- import {
3
- renderToStaticMarkup,
4
- renderToStaticNodeStream,
5
- } from "react-dom/server";
6
- import Stream from "stream";
7
-
8
1
  import Testeranto from "../../../Node.js";
9
- import {
10
- Ibdd_in,
11
- Ibdd_out,
12
- ITestImplementation,
13
- ITestSpecification,
14
- } from "../../../Types";
15
2
 
16
- import { IInput, ISelection, IStore } from "./index.js";
3
+ import { ITestImplementation, ITestSpecification, OT } from "../../../Types";
17
4
 
18
- export { renderToStaticMarkup, renderToStaticNodeStream, Stream };
5
+ import { I, testInterface } from "./static.js";
19
6
 
20
- export default <
21
- I extends Ibdd_in<
22
- IInput,
23
- unknown,
24
- ISelection,
25
- IStore,
26
- unknown,
27
- unknown,
28
- unknown
29
- >,
30
- O extends Ibdd_out<
31
- Record<string, any>,
32
- Record<string, any>,
33
- Record<string, any>,
34
- Record<string, any>,
35
- Record<string, any>
36
- >
37
- >(
38
- testImplementations: ITestImplementation<I, O>,
7
+ export default <O extends OT, M>(
8
+ testImplementations: ITestImplementation<I, O, M>,
39
9
  testSpecifications: ITestSpecification<I, O>,
40
10
  testInput: I["iinput"]
41
11
  ) => {
42
- return Testeranto<I, O>(testInput, testSpecifications, testImplementations, {
43
- beforeAll: async (prototype, artificer) => {
44
- return await new Promise((resolve, rej) => {
45
- resolve(null);
46
- });
47
- },
48
- beforeEach: async () => {
49
- return new Promise((resolve, rej) => {
50
- resolve(createElement(testInput));
51
- });
52
- },
53
- andWhen: async function (s, whenCB) {
54
- return s;
55
- },
56
- butThen: async function (s: I["istore"]): Promise<I["iselection"]> {
57
- return s;
58
- },
59
- afterEach: async function (store: I["istore"], ndx, artificer) {
60
- return {};
61
- },
62
- afterAll: (store: I["istore"], artificer) => {
63
- return;
64
- },
65
- });
12
+ return Testeranto<I, O, M>(
13
+ testInput,
14
+ testSpecifications,
15
+ testImplementations,
16
+ testInterface
17
+ );
66
18
  };