testeranto 0.146.2 → 0.146.4

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 (197) hide show
  1. package/dist/common/src/Node.js +9 -6
  2. package/dist/common/src/PM/PM_WithEslintAndTsc.js +75 -58
  3. package/dist/common/src/PM/main.js +131 -79
  4. package/dist/common/src/PM/node.js +1 -14
  5. package/dist/common/src/PM/nodeSidecar.js +0 -1
  6. package/dist/common/src/Pure.js +17 -1
  7. package/dist/common/src/Pure.test.js +172 -0
  8. package/dist/common/src/build.js +0 -1
  9. package/dist/common/src/esbuildConfigs/consoleDetectorPlugin.js +22 -11
  10. package/dist/common/src/esbuildConfigs/nativeImportDetectorPlugin.js +24 -0
  11. package/dist/common/src/esbuildConfigs/pure.js +2 -1
  12. package/dist/common/src/esbuildConfigs/rebuildPlugin.js +1 -4
  13. package/dist/common/src/lib/BaseSuite.js +89 -0
  14. package/dist/common/src/lib/BaseSuite.test/node.test.js +9 -0
  15. package/dist/common/src/lib/BaseSuite.test/pure.test.js +9 -0
  16. package/dist/common/src/lib/BaseSuite.test/test.js +232 -0
  17. package/dist/common/src/lib/BaseSuite.test/web.test.js +9 -0
  18. package/dist/common/src/lib/abstractBase.js +1 -90
  19. package/dist/common/src/lib/abstractBase.test/MockGiven.js +17 -0
  20. package/dist/common/src/lib/abstractBase.test/MockThen.js +13 -0
  21. package/dist/common/src/lib/abstractBase.test/MockWhen.js +13 -0
  22. package/dist/common/src/lib/abstractBase.test/implementation.js +42 -0
  23. package/dist/common/src/lib/abstractBase.test/index.js +17 -0
  24. package/dist/common/src/lib/abstractBase.test/interface.js +12 -0
  25. package/dist/common/src/lib/abstractBase.test/specification.js +19 -0
  26. package/dist/common/src/lib/abstractBase.test/types.js +2 -0
  27. package/dist/common/src/lib/baseBuilder.test/TestBaseBuilder.js +36 -0
  28. package/dist/common/src/lib/baseBuilder.test/baseBuilder.test.implementation.js +97 -0
  29. package/dist/common/src/lib/baseBuilder.test/baseBuilder.test.interface.js +17 -0
  30. package/dist/common/src/lib/baseBuilder.test/baseBuilder.test.node.js +11 -0
  31. package/dist/common/src/lib/baseBuilder.test/baseBuilder.test.pure.js +11 -0
  32. package/dist/common/src/lib/baseBuilder.test/baseBuilder.test.specification.js +13 -0
  33. package/dist/common/src/lib/baseBuilder.test/baseBuilder.test.types.js +2 -0
  34. package/dist/common/src/lib/baseBuilder.test/baseBuilder.test.web.js +11 -0
  35. package/dist/common/src/lib/basebuilder.js +2 -1
  36. package/dist/common/src/lib/classBuilder.test/TestClassBuilder.js +41 -0
  37. package/dist/common/src/lib/classBuilder.test/classBuilder.test.implementation.js +182 -0
  38. package/dist/common/src/lib/classBuilder.test/classBuilder.test.interface.js +17 -0
  39. package/dist/common/src/lib/classBuilder.test/classBuilder.test.js +11 -0
  40. package/dist/common/src/lib/classBuilder.test/classBuilder.test.specification.js +41 -0
  41. package/dist/common/src/lib/classBuilder.test/classBuilder.test.types.js +2 -0
  42. package/dist/common/src/lib/core.js +4 -13
  43. package/dist/common/src/lib/core.test/MockCore.js +25 -0
  44. package/dist/common/src/lib/core.test/core.test.implementation.js +102 -0
  45. package/dist/common/src/lib/core.test/core.test.interface.js +18 -0
  46. package/dist/common/src/lib/core.test/core.test.js +17 -0
  47. package/dist/common/src/lib/core.test/core.test.specification.js +33 -0
  48. package/dist/common/src/lib/core.test/core.test.types.js +2 -0
  49. package/dist/common/src/lib/pmProxy.js +9 -166
  50. package/dist/common/src/lib/pmProxy.test/implementation.js +76 -0
  51. package/dist/common/src/lib/pmProxy.test/index.js +15 -0
  52. package/dist/common/src/lib/pmProxy.test/interface.js +37 -0
  53. package/dist/common/src/lib/pmProxy.test/mockPM.js +34 -0
  54. package/dist/common/src/lib/pmProxy.test/mockPMBase.js +115 -0
  55. package/dist/common/src/lib/pmProxy.test/specification.js +39 -0
  56. package/dist/common/src/lib/pmProxy.test/types.js +2 -0
  57. package/dist/common/src/run.js +6 -6
  58. package/dist/common/testeranto.config.js +33 -18
  59. package/dist/common/tsconfig.common.tsbuildinfo +1 -1
  60. package/dist/module/src/Node.js +9 -6
  61. package/dist/module/src/PM/PM_WithEslintAndTsc.js +75 -58
  62. package/dist/module/src/PM/main.js +131 -79
  63. package/dist/module/src/PM/node.js +1 -14
  64. package/dist/module/src/PM/nodeSidecar.js +0 -1
  65. package/dist/module/src/Pure.js +17 -1
  66. package/dist/module/src/Pure.test.js +167 -0
  67. package/dist/module/src/build.js +0 -1
  68. package/dist/module/src/esbuildConfigs/consoleDetectorPlugin.js +19 -11
  69. package/dist/module/src/esbuildConfigs/nativeImportDetectorPlugin.js +21 -0
  70. package/dist/module/src/esbuildConfigs/pure.js +2 -1
  71. package/dist/module/src/esbuildConfigs/rebuildPlugin.js +1 -4
  72. package/dist/module/src/lib/BaseSuite.js +85 -0
  73. package/dist/module/src/lib/BaseSuite.test/node.test.js +4 -0
  74. package/dist/module/src/lib/BaseSuite.test/pure.test.js +4 -0
  75. package/dist/module/src/lib/BaseSuite.test/test.js +227 -0
  76. package/dist/module/src/lib/BaseSuite.test/web.test.js +4 -0
  77. package/dist/module/src/lib/abstractBase.js +1 -89
  78. package/dist/module/src/lib/abstractBase.test/MockGiven.js +13 -0
  79. package/dist/module/src/lib/abstractBase.test/MockThen.js +9 -0
  80. package/dist/module/src/lib/abstractBase.test/MockWhen.js +9 -0
  81. package/dist/module/src/lib/abstractBase.test/implementation.js +39 -0
  82. package/dist/module/src/lib/abstractBase.test/index.js +12 -0
  83. package/dist/module/src/lib/abstractBase.test/interface.js +9 -0
  84. package/dist/module/src/lib/abstractBase.test/specification.js +15 -0
  85. package/dist/module/src/lib/abstractBase.test/types.js +1 -0
  86. package/dist/module/src/lib/baseBuilder.test/TestBaseBuilder.js +32 -0
  87. package/dist/module/src/lib/baseBuilder.test/baseBuilder.test.implementation.js +94 -0
  88. package/dist/module/src/lib/baseBuilder.test/baseBuilder.test.interface.js +14 -0
  89. package/dist/module/src/lib/baseBuilder.test/baseBuilder.test.node.js +6 -0
  90. package/dist/module/src/lib/baseBuilder.test/baseBuilder.test.pure.js +6 -0
  91. package/dist/module/src/lib/baseBuilder.test/baseBuilder.test.specification.js +9 -0
  92. package/dist/module/src/lib/baseBuilder.test/baseBuilder.test.types.js +1 -0
  93. package/dist/module/src/lib/baseBuilder.test/baseBuilder.test.web.js +6 -0
  94. package/dist/module/src/lib/basebuilder.js +2 -1
  95. package/dist/module/src/lib/classBuilder.test/TestClassBuilder.js +37 -0
  96. package/dist/module/src/lib/classBuilder.test/classBuilder.test.implementation.js +179 -0
  97. package/dist/module/src/lib/classBuilder.test/classBuilder.test.interface.js +14 -0
  98. package/dist/module/src/lib/classBuilder.test/classBuilder.test.js +6 -0
  99. package/dist/module/src/lib/classBuilder.test/classBuilder.test.specification.js +37 -0
  100. package/dist/module/src/lib/classBuilder.test/classBuilder.test.types.js +1 -0
  101. package/dist/module/src/lib/core.js +3 -12
  102. package/dist/module/src/lib/core.test/MockCore.js +18 -0
  103. package/dist/module/src/lib/core.test/core.test.implementation.js +99 -0
  104. package/dist/module/src/lib/core.test/core.test.interface.js +15 -0
  105. package/dist/module/src/lib/core.test/core.test.js +12 -0
  106. package/dist/module/src/lib/core.test/core.test.specification.js +29 -0
  107. package/dist/module/src/lib/core.test/core.test.types.js +1 -0
  108. package/dist/module/src/lib/pmProxy.js +9 -166
  109. package/dist/module/src/lib/pmProxy.test/implementation.js +73 -0
  110. package/dist/module/src/lib/pmProxy.test/index.js +10 -0
  111. package/dist/module/src/lib/pmProxy.test/interface.js +34 -0
  112. package/dist/module/src/lib/pmProxy.test/mockPM.js +30 -0
  113. package/dist/module/src/lib/pmProxy.test/mockPMBase.js +111 -0
  114. package/dist/module/src/lib/pmProxy.test/specification.js +35 -0
  115. package/dist/module/src/lib/pmProxy.test/types.js +1 -0
  116. package/dist/module/src/run.js +6 -6
  117. package/dist/module/testeranto.config.js +33 -18
  118. package/dist/module/tsconfig.module.tsbuildinfo +1 -1
  119. package/dist/prebuild/Project.js +16 -15
  120. package/dist/prebuild/TestReport.js +14 -12
  121. package/dist/prebuild/build.mjs +34 -34
  122. package/dist/prebuild/run.mjs +259 -173
  123. package/dist/tsconfig.tsbuildinfo +1 -1
  124. package/dist/types/src/PM/PM_WithEslintAndTsc.d.ts +2 -1
  125. package/dist/types/src/PM/main.d.ts +5 -2
  126. package/dist/types/src/Pure.d.ts +2 -2
  127. package/dist/types/src/Pure.test.d.ts +36 -0
  128. package/dist/types/src/Types.d.ts +7 -6
  129. package/dist/types/src/Web.d.ts +1 -1
  130. package/dist/types/src/esbuildConfigs/consoleDetectorPlugin.d.ts +1 -1
  131. package/dist/types/src/esbuildConfigs/nativeImportDetectorPlugin.d.ts +2 -0
  132. package/dist/types/src/lib/BaseSuite.d.ts +39 -0
  133. package/dist/types/src/lib/BaseSuite.test/node.test.d.ts +3 -0
  134. package/dist/types/src/lib/BaseSuite.test/pure.test.d.ts +3 -0
  135. package/dist/types/src/lib/BaseSuite.test/test.d.ts +42 -0
  136. package/dist/types/src/lib/BaseSuite.test/web.test.d.ts +3 -0
  137. package/dist/types/src/lib/abstractBase.d.ts +1 -36
  138. package/dist/types/src/lib/abstractBase.test/MockGiven.d.ts +7 -0
  139. package/dist/types/src/lib/abstractBase.test/MockThen.d.ts +6 -0
  140. package/dist/types/src/lib/abstractBase.test/MockWhen.d.ts +6 -0
  141. package/dist/types/src/lib/abstractBase.test/implementation.d.ts +3 -0
  142. package/dist/types/src/lib/abstractBase.test/index.d.ts +3 -0
  143. package/dist/types/src/lib/abstractBase.test/interface.d.ts +3 -0
  144. package/dist/types/src/lib/abstractBase.test/specification.d.ts +3 -0
  145. package/dist/types/src/lib/abstractBase.test/types.d.ts +39 -0
  146. package/dist/types/src/lib/baseBuilder.test/TestBaseBuilder.d.ts +15 -0
  147. package/dist/types/src/lib/baseBuilder.test/baseBuilder.test.implementation.d.ts +3 -0
  148. package/dist/types/src/lib/baseBuilder.test/baseBuilder.test.interface.d.ts +3 -0
  149. package/dist/types/src/lib/baseBuilder.test/baseBuilder.test.node.d.ts +3 -0
  150. package/dist/types/src/lib/baseBuilder.test/baseBuilder.test.pure.d.ts +3 -0
  151. package/dist/types/src/lib/baseBuilder.test/baseBuilder.test.specification.d.ts +3 -0
  152. package/dist/types/src/lib/baseBuilder.test/baseBuilder.test.types.d.ts +20 -0
  153. package/dist/types/src/lib/baseBuilder.test/baseBuilder.test.web.d.ts +3 -0
  154. package/dist/types/src/lib/classBuilder.test/TestClassBuilder.d.ts +21 -0
  155. package/dist/types/src/lib/classBuilder.test/classBuilder.test.d.ts +3 -0
  156. package/dist/types/src/lib/classBuilder.test/classBuilder.test.implementation.d.ts +3 -0
  157. package/dist/types/src/lib/classBuilder.test/classBuilder.test.interface.d.ts +3 -0
  158. package/dist/types/src/lib/classBuilder.test/classBuilder.test.specification.d.ts +3 -0
  159. package/dist/types/src/lib/classBuilder.test/classBuilder.test.types.d.ts +56 -0
  160. package/dist/types/src/lib/core.d.ts +1 -1
  161. package/dist/types/src/lib/core.test/MockCore.d.ts +10 -0
  162. package/dist/types/src/lib/core.test/core.test.d.ts +3 -0
  163. package/dist/types/src/lib/core.test/core.test.implementation.d.ts +3 -0
  164. package/dist/types/src/lib/core.test/core.test.interface.d.ts +3 -0
  165. package/dist/types/src/lib/core.test/core.test.specification.d.ts +3 -0
  166. package/dist/types/src/lib/core.test/core.test.types.d.ts +46 -0
  167. package/dist/types/src/lib/index.d.ts +2 -1
  168. package/dist/types/src/lib/pmProxy.d.ts +11 -6
  169. package/dist/types/src/lib/pmProxy.test/implementation.d.ts +3 -0
  170. package/dist/types/src/lib/pmProxy.test/index.d.ts +7 -0
  171. package/dist/types/src/lib/pmProxy.test/interface.d.ts +3 -0
  172. package/dist/types/src/lib/pmProxy.test/mockPM.d.ts +10 -0
  173. package/dist/types/src/lib/pmProxy.test/mockPMBase.d.ts +39 -0
  174. package/dist/types/src/lib/pmProxy.test/specification.d.ts +3 -0
  175. package/dist/types/src/lib/pmProxy.test/types.d.ts +42 -0
  176. package/dist/types/src/lib/types.d.ts +2 -1
  177. package/dist/types/tsconfig.types.tsbuildinfo +1 -1
  178. package/docs.html +35 -33
  179. package/index.html +23 -30
  180. package/package.json +3 -2
  181. package/testeranto/index.html +1 -1
  182. package/testeranto/reports/allTests/index.html +1 -1
  183. package/testeranto/reports/allTests/src/Pure.test/pure/index.html +1 -1
  184. package/testeranto/reports/allTests/src/Pure.test/pure/logs.txt +2 -2
  185. package/testeranto/reports/allTests/src/lib/BaseSuite.test/node.test/node/index.html +1 -1
  186. package/testeranto/reports/allTests/src/lib/BaseSuite.test/pure.test/pure/index.html +1 -1
  187. package/testeranto/reports/allTests/src/lib/BaseSuite.test/pure.test/pure/logs.txt +2 -2
  188. package/testeranto/reports/allTests/src/lib/BaseSuite.test/web.test/web/index.html +1 -1
  189. package/testeranto/reports/allTests/src/lib/baseBuilder.test/baseBuilder.test.node/node/index.html +1 -1
  190. package/testeranto/reports/allTests/src/lib/baseBuilder.test/baseBuilder.test.pure/pure/index.html +1 -1
  191. package/testeranto/reports/allTests/src/lib/baseBuilder.test/baseBuilder.test.web/web/index.html +1 -1
  192. package/testeranto/reports/allTests/src/lib/classBuilder.test/classBuilder.test/node/index.html +1 -1
  193. package/testeranto/reports/allTests/src/lib/core.test/core.test/node/index.html +1 -1
  194. package/testeranto/reports/allTests/src/lib/pmProxy.test/index/node/index.html +1 -1
  195. package/testeranto/reports/allTests/src/lib/pmProxy.test/index/node/logs.txt +3 -3
  196. package/testeranto.config.ts +1 -1
  197. package/tsc.log +36 -38
package/docs.html CHANGED
@@ -19,7 +19,7 @@
19
19
  <div class="parallax-background"></div>
20
20
  <div id="container">
21
21
  <h1>Testeranto docs and core concepts</h1>
22
- <p>Testeranto&#39;s type system provides a rigorous framework for Behavior-Driven Development (BDD) testing. While powerful, the API can initially seem complex but everything you need to know can be summed up in <strong>3 core functions and 5 essential types</strong>. Follow these patterns, and TypeScript&#39;s type checker will guide you through the rest.</p>
22
+ <p>Testeranto&#39;s type system provides a rigorous framework for Behavior-Driven Development (BDD) testing. The API may seem complex but everything you need to know can be summed up in <strong>1 function, 3 runtimes and 5 essential types, and 1 optional type</strong>. Follow these patterns, and TypeScript&#39;s type checker will guide you through the rest.</p>
23
23
  <h3>⚠️ this doc is a work in progress. It is 99% accurate but needs some attention to be complete. ⚠️</h3>
24
24
  <p>Let&#39;s break down the key components using a Rectangle class example.</p>
25
25
  <h3>The Test Subject</h3>
@@ -36,12 +36,24 @@
36
36
  getArea() {
37
37
  return this.width * this.height;
38
38
  }
39
- }</code></pre><h3>Testeranto&#39;s 3 functions</h3>
39
+ }</code></pre><h3>Testeranto&#39;s 1 function</h3>
40
+ <p>Testeranto has 1 function. This function launches and runs the tests. It is here that all 5 types converge and if you can type this function call correctly, the TS type system should guide you through the rest.</p>
41
+ <pre>async <I extends Ibdd_in_any, O extends Ibdd_out, M>(
42
+ input: I["iinput"],
43
+ testSpecification: ITestSpecification<I, O>,
44
+ testImplementation: ITestImplementation<I, O, M>,
45
+ testInterface: Partial<ITestInterface<I>>,
46
+ testResourceRequirement: ITTestResourceRequest = defaultTestResourceRequirement
47
+ ): Promise<Testeranto<I, O, M>></pre><h3>Testeranto&#39;s 3 runtimes</h3>
40
48
  <p>For each of testeranto&#39;s runtime, there is a specific Testeranto main function. Each is it&#39;s own import but all 3 are called in the same way.</p>
41
49
  <h4>Node</h4>
42
50
  <pre>import Testeranto from "testeranto/src/Node"; // <- import the Node main function
43
51
  // below this point, all runtimes are identical!
44
52
 
53
+ import { implementation } from "./Rectangle.test.implementation";
54
+ import { specification } from "./Rectangle.test.specification";
55
+ import { interface } from "./Rectangle.test.interface";
56
+
45
57
  // Note the type parameters I, O, and M: these will be important later
46
58
  export default Testeranto<
47
59
  I extends Ibdd_in,
@@ -88,36 +100,15 @@ export default Testeranto<
88
100
  specification,
89
101
  implementation,
90
102
  interface
91
- );</pre><h3>Testeranto&#39;s 5 Essential Types</h3>
92
- <p>Every testeranto test is built around these 5 types that form a complete testing pipeline:</p>
93
- <ol>
94
- <li><strong>ITestSpecification</strong> - The &quot;what&quot; of your tests (business requirements)</li>
95
- <li><strong>ITestImplementation</strong> - The &quot;how&quot; of your tests (concrete operations)</li>
96
- <li><strong>ITestInterface</strong> - The &quot;glue&quot; between specs and implementation</li>
97
- <li><strong>Ibdd_in</strong> - Defines the internal test flow shape</li>
98
- <li><strong>Ibdd_out</strong> - Defines the external test interface</li>
99
- </ol>
100
- <pre class="mermaid">flowchart LR
101
- S[ITestSpecification] -->|defines| O[Ibdd_out]
102
- I[ITestImplementation] -->|uses| O
103
- I -->|uses| M[Modifier]
104
- T[ITestInterface] -->|connects| N[Ibdd_in]
105
- S -->|flows through| N
106
- I -->|flows through| N
107
-
108
- style S fill:#2aa198,stroke:#073642
109
- style I fill:#859900,stroke:#073642
110
- style T fill:#b58900,stroke:#073642
111
- style O fill:#d33682,stroke:#073642
112
- style N fill:#cb4b16,stroke:#073642
113
- style M fill:#6c71c4,stroke:#073642</pre><h4>The Specification (ITestSpecification)</h4>
103
+ );</pre><h3>Testeranto&#39;s 5 essential types</h3>
104
+ <p>Every testeranto test is built around these 5 types that form a complete testing pipeline.</p>
105
+ <h4>The Specification (ITestSpecification)</h4>
114
106
  <p>The Specification defines the business requirements in plain language, completely separate from implementation details. This is where you describe <strong>what</strong> should be tested without worrying about <strong>how</strong>.</p>
115
107
  <ul>
116
108
  <li>Pure business logic</li>
117
109
  <li>Human-readable test descriptions</li>
118
110
  <li>Defines test suites, scenarios (Given/When/Then)</li>
119
111
  <li>Maps directly to BDD concepts</li>
120
- <li>Uses Ibdd_out for type safety</li>
121
112
  </ul>
122
113
  <pre class="language-typescript line-numbers"><code class="language-typescript">import {
123
114
  Ibdd_in,
@@ -220,9 +211,8 @@ export const implementation: ITestImplementation<
220
211
  Default: () => new Rectangle(2, 2),
221
212
  },
222
213
  };</pre><h4>The Interface aka ITestInterface</h4>
223
- <p>The test interface is code which is NOT BDD . The interface adapts your test subject so that the BDD hooks can be applied. The interface implements the traditional BDD steps &quot;before all&quot;, &quot;after all&quot;, &quot;before each&quot;, &quot;after each&quot;, etc</p>
224
- <pre>
225
- import {
214
+ <p>The test interface is code which is NOT business logic. The interface adapts your test subject so that the BDD hooks can be applied. The interface implements the traditional BDD steps &quot;before all&quot;, &quot;after all&quot;, &quot;before each&quot;, &quot;after each&quot;, etc</p>
215
+ <pre>import {
226
216
  Ibdd_in,
227
217
  ITestInterface,
228
218
  } from "testeranto/src/CoreTypes";
@@ -246,7 +236,7 @@ export const testInterface: ITestInterface<
246
236
  afterAll: () => {},
247
237
  assertThis: (x: any, y) => {},
248
238
  };</pre><h4>type I aka Ibdd_in</h4>
249
- <p>this type describes the &quot;inner&quot; shape of your BDD tests.</p>
239
+ <p>This type describes the &quot;inner&quot; shape of your BDD tests. Over the course of the execution of the test, the subject will change shapes- this test describe those changes.</p>
250
240
  <pre>import { Ibdd_in } from "testeranto/src/CoreTypes";
251
241
 
252
242
  // TODO this is inaccurate
@@ -259,7 +249,7 @@ export type I = Ibdd_in<
259
249
  (...x) => (rectangle: Rectangle, utils: IPM) => Rectangle,
260
250
  (rectangle: Rectangle, utils: IPM) => Rectangle
261
251
  >;</pre><h4>type O aka Ibdd_out</h4>
262
- <p>this type describes the &quot;outer&quot; shape of your BDD tests.</p>
252
+ <p>This type describes the &quot;outer&quot; shape of your BDD tests. This type describes the set of legal BDD clauses.</p>
263
253
  <pre>import { Ibdd_out } from "testeranto/src/CoreTypes";
264
254
 
265
255
  export type O = Ibdd_out<
@@ -295,7 +285,8 @@ export type O = Ibdd_out<
295
285
  WidthOfOneAndHeightOfOne;
296
286
  WidthAndHeightOf: [number, number];
297
287
  }
298
- >;</pre><h4>type M (optional)</h4>
288
+ >;</pre><h3>Testeranto&#39;s 1 optional type</h3>
289
+ <h4>type M (optional)</h4>
299
290
  <p>this type describes the modifications to the shape of the &quot;specification&quot;. It can be used to make your BDD tests DRYer but is not necessary</p>
300
291
  <pre>export type M = {
301
292
  givens: {
@@ -515,7 +506,18 @@ export default Testeranto<
515
506
  );
516
507
 
517
508
 
518
- </pre>
509
+ </pre><h2>Trouble shooting</h2>
510
+ <h3>Double check your runtimes.</h3>
511
+ <p>Every test has a runtime, which must defined in 2 places. Both must match.</p>
512
+ <ol>
513
+ <li>The import of the runtime</li>
514
+ <li>The runtime defined alongside the test in testeranto.config.ts</li>
515
+ </ol>
516
+ <p>By convention, test filenames reveal their runtime. Ex: <code>__tests__/yourClass.node.test</code>. This is ONLY a convention. It has no real bearing on the runtime.</p>
517
+ <h2>Dos and Don&#39;ts</h2>
518
+ <h3>Do pass your test subject to the main testeranto function.</h3>
519
+ <h3>Don&#39;t import your test subject elsewhere in your tests.</h3>
520
+
519
521
  </div>
520
522
  <!-- Prism.js JS -->
521
523
  <script src="https://cdnjs.cloudflare.com/ajax/libs/prism/1.29.0/prism.min.js"></script>
package/index.html CHANGED
@@ -20,24 +20,24 @@
20
20
  <div id="container">
21
21
  <h1>testeranto</h1>
22
22
  <h2>The AI-powered BDD test framework for TypeScript projects</h2>
23
- <h4>🚧 WARNING: Testeranto is still under development and is not ready for production yet. 🚧</h4>
23
+ <h4>🚧 WARNING: Testeranto is still under development but is not ready for production yet. I am rapidly working to release a beta ASAP. If you are interested in joining this beta program, please contact me. 🚧</h4>
24
24
  <ul>
25
- <li>README: <a href="https://adamwong246.github.io/testeranto/">index.html</a></li>
25
+ <li>README: <a href="https://adamwong246.github.io/testeranto/testeranto">adamwong246.github.io/testeranto/testeranto</a></li>
26
26
  <li>demo: <a href="https://www.youtube.com/embed/WvU5xMqGi6Q">youtube</a></li>
27
27
  <li>source: <a href="https://github.com/adamwong246/testeranto">github.com/adamwong246/testeranto</a></li>
28
28
  <li>npm: <a href="https://www.npmjs.com/package/testeranto">npmjs.com/package/testeranto</a></li>
29
- <li>dev: <a href="https://github.dev/adamwong246/testeranto">github.dev/adamwong246/testeranto</a></li>
30
29
  <li>example repo: <a href="https://github.com/adamwong246/testeranto-starter">testeranto-starter</a></li>
30
+ <li>tests report: <a href="https://adamwong246.github.io/testeranto/testeranto/index.html">adamwong246.github.io/testeranto/testeranto</a></li>
31
31
  </ul>
32
32
  <h2>What is testeranto?</h2>
33
33
  <ul>
34
- <li>Testeranto produces test results which can be fed to Aider.ai to automatically fix failing tests.</li>
35
- <li>Testeranto tests are specified in a strongly-typed gherkin-like syntax. Rather than testing your code directly, Testeranto requires you wrap your code with a semantic interface which is based on TS type signatures.</li>
36
- <li>Testeranto can run tests in the frontend or the backend, or both.</li>
34
+ <li>Testeranto produces test results that can be fed to Aider.ai to automatically fix failing tests.</li>
35
+ <li>Testeranto tests are specified in a strongly-typed gherkin-like syntax. Rather than testing your code directly, Testeranto requires you to wrap your code with a semantic interface that is based on TS type signatures.</li>
36
+ <li>Testeranto can run tests in the frontend, the backend, or both.</li>
37
37
  <li>Testeranto can be used to test anything that can be bundled with esbuild.</li>
38
38
  <li>Testeranto connects &quot;features&quot; to &quot;tests&quot;. This allows the AI to read feature documentation from external systems, like Jira.</li>
39
- <li>Testeranto generates test results into static a website which can be deployed to github pages easily.</li>
40
- <li>Testeranto uses esbuild to bundle it&#39;s tests. The result is used to refine the list of files added to the context of the AI. <strong>The consequence of this is that you can fit all relevant files, and ONLY the relevant files, into the LLMs context.</strong></li>
39
+ <li>Testeranto generates test results as a static website that can be easily deployed to GitHub Pages.</li>
40
+ <li>Testeranto uses esbuild to bundle its tests. The result is used to refine the list of files added to the AI&#39;s context. <strong>The consequence of this is that you can fit all relevant files, and only the relevant files, into the LLM&#39;s context.</strong></li>
41
41
  </ul>
42
42
  <h2>Key Technologies</h2>
43
43
  <table>
@@ -75,10 +75,6 @@
75
75
  <td>tsc</td>
76
76
  <td>Type checking of test files</td>
77
77
  </tr>
78
- <tr>
79
- <td>Markdown</td>
80
- <td>Feature documentation format</td>
81
- </tr>
82
78
  </tbody></table>
83
79
  <h2>Quick Start</h2>
84
80
  <ol>
@@ -113,28 +109,24 @@ yarn t-run rectangle.test.ts yourProject dev</pre><p>or build and run your tests
113
109
  <thead>
114
110
  <tr>
115
111
  <th></th>
116
- <th>Runs on</th>
117
112
  <th>You should use this runtime for...</th>
118
113
  <th>Important differences</th>
119
114
  </tr>
120
115
  </thead>
121
116
  <tbody><tr>
122
- <td><strong>Node</strong></td>
123
- <td>node V8 with fork</td>
117
+ <td><strong>Node</strong> : node V8 with fork</td>
124
118
  <td>testing backend code, Node APIs (like <code>fs</code> and <code>crypto</code>), or anything needing filesystem access</td>
125
119
  <td>has access to the filesystem and io</td>
126
120
  </tr>
127
121
  <tr>
128
- <td><strong>Web</strong></td>
129
- <td>chrome browser</td>
122
+ <td><strong>Web</strong> : chrome browser</td>
130
123
  <td>testing frontend code, anything that uses <code>document</code> or <code>window</code>, UI interactions, or visual regression</td>
131
124
  <td>can take screenshots/recordings</td>
132
125
  </tr>
133
126
  <tr>
134
- <td><strong>Pure</strong></td>
135
- <td>node v8, dynamically imported</td>
136
- <td>testing code which can run on both node-v8 and the the browser</td>
137
- <td>Very similar to &quot;Node&quot; but has no IO access and thus, no console.log. This runtime is theoretically faster.</td>
127
+ <td><strong>Pure</strong> : node v8, dynamically imported</td>
128
+ <td>testing code that can run on both node-v8 and the browser</td>
129
+ <td>Very similar to &quot;Node&quot; but has no IO access and thus no console.log. This runtime is theoretically faster.</td>
138
130
  </tr>
139
131
  </tbody></table>
140
132
  <h2>CLI Commands</h2>
@@ -185,7 +177,7 @@ yarn t-run test/rectangle.test.ts once
185
177
  # Get AI help with failures
186
178
  yarn t-aider</pre><h2>Aider</h2>
187
179
  <p>Testeranto generates a &quot;prompt&quot; alongside test results. This prompt is passed to aider as input.</p>
188
- <pre>// input src files which can be edited by aider
180
+ <pre>// input src files that can be edited by Aider
189
181
  /add test/node.ts
190
182
 
191
183
  // test report files that inform aider but should not be edited
@@ -214,18 +206,19 @@ test0: Given.Default(
214
206
  [Then.getWidth(4), Then.getHeight(19)]
215
207
  ),
216
208
  ...
217
- </code></pre><h2>Sidecars (COMING SOON)</h2>
218
- <p>Along side your test, you can include a number of &quot;sidecars&quot; which are other bundled javascript assets upon which your test depends. For example, suppose you have an app with a frontend and backend component. You could run a react test in the web and include the node http server as a sidecar.</p>
219
- <h2><code>eslint</code> and <code>tsc</code></h2>
220
- <p>Alongside the bdd tests, testeranto runs eslint and tsc upon the input files to generate a list of static analysis errors and a list of type errors, respectively.</p>
209
+ </code></pre><h2><code>eslint</code> and <code>tsc</code></h2>
210
+ <p>Alongside the BDD tests, Testeranto runs ESLint and tsc on the input files to generate a list of static analysis errors and type errors, respectively.</p>
211
+ <hr>
212
+ <h2>Sidecars (COMING SOON)</h2>
213
+ <p>Alongside your test, you can include a number of &quot;sidecars&quot; - other bundled JavaScript assets upon which your test depends. For example, suppose you have an app with frontend and backend components. You could run a React test in the web and include the Node HTTP server as a sidecar.</p>
221
214
  <h2>Subprojects</h2>
222
- <p>Testeranto has a core repo, but there are also subprojects which implement tests by type and by technology</p>
215
+ <p>Testeranto has a core repo, but there are also sub-projects which implement tests by type and by technology</p>
223
216
  <h3>testeranto-solidity</h3>
224
- <p>Test a solidity contract. Also included is an example of deploying a contrct to a ganache server.</p>
217
+ <p>Test a solidity contract. Also included is an example of deploying a contract to a ganache server.</p>
225
218
  <h3>testeranto-reduxtoolkit</h3>
226
- <p>Test a redux store.</p>
219
+ <p>Tests a Redux store.</p>
227
220
  <h3>testeranto-http</h3>
228
- <p>Test a node http server.</p>
221
+ <p>Tests a Node HTTP server.</p>
229
222
  <h3>testeranto-react (COMING SOON)</h3>
230
223
  <p>Test a react component. You can choose from a variety of types (jsx functions, class style, etc) and you can test with <code>react</code>, <code>react-dom</code>, or <code>react-test-renderer</code></p>
231
224
  <h3>testeranto-express (COMING SOON)</h3>
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "testeranto",
3
3
  "description": "the AI powered BDD test framework for typescript projects",
4
- "version": "0.146.2",
4
+ "version": "0.146.4",
5
5
  "engines": {
6
6
  "node": "18.18.0"
7
7
  },
@@ -132,7 +132,8 @@
132
132
  "t-run": "tsx src/run.ts",
133
133
  "t-init": "tsx dist/prebuild/init-docs.mjs",
134
134
  "t-report": "tsx dist/prebuild/ReportServer.mjs",
135
- "build-docs": "node scripts/compile-docs.js"
135
+ "build-docs": "node scripts/compile-docs.js",
136
+ "do_it": "clear && rm -rf testeranto/** && yarn build && yarn t-init && yarn t-build allTests once && yarn t-run allTests once && yarn build-docs && yarn type-check"
136
137
  },
137
138
  "peerDependencies": {
138
139
  "@types/react": "18.2.0",
@@ -8,7 +8,7 @@
8
8
  <title>testeranto - testeranto</title>
9
9
  <meta name="viewport" content="width=device-width, initial-scale=1" />
10
10
  <meta name="author" content="" />
11
- <base href="https://adamwong246.github.io/testeranto" target="_blank">
11
+ <base href="https://adamwong246.github.io/testeranto/testeranto" target="_blank">
12
12
 
13
13
  <script type="application/json" id="bigConfig">
14
14
  ["allTests","react"]
@@ -9,7 +9,7 @@
9
9
  <meta name="viewport" content="width=device-width, initial-scale=1" />
10
10
  <meta name="author" content="" />
11
11
 
12
- <base href="https://adamwong246.github.io/testeranto" target="_blank">
12
+ <base href="https://adamwong246.github.io/testeranto/testeranto" target="_blank">
13
13
 
14
14
  <link rel="stylesheet" href="../ReportClient.css" />
15
15
  <script type="module" src="../ReportClient.js"></script>
@@ -4,7 +4,7 @@
4
4
 
5
5
  <head>
6
6
  <meta name="description" content="Webpage description goes here" />
7
- <base href="https://adamwong246.github.io/testeranto" target="_blank">
7
+ <base href="https://adamwong246.github.io/testeranto/testeranto" target="_blank">
8
8
  <meta charset="utf-8" />
9
9
  <title>allTests - testeranto</title>
10
10
  <meta name="viewport" content="width=device-width, initial-scale=1" />
@@ -1,11 +1,11 @@
1
1
  TypeError: Then.initializedProperly is not a function
2
- at specification (file:///Users/adam/Code/testeranto/testeranto/bundles/pure/allTests/src/Pure.test.mjs?cacheBust=1752859436874:320:14)
2
+ at specification (file:///Users/adam/Code/testeranto/testeranto/bundles/pure/allTests/src/Pure.test.mjs?cacheBust=1752859984032:320:14)
3
3
  at new BaseBuilder (file:///Users/adam/Code/testeranto/testeranto/bundles/pure/allTests/chunk-W22WOQNK.mjs:15:18)
4
4
  at new ClassBuilder (file:///Users/adam/Code/testeranto/testeranto/bundles/pure/allTests/chunk-W22WOQNK.mjs:646:5)
5
5
  at new TesterantoCore (file:///Users/adam/Code/testeranto/testeranto/bundles/pure/allTests/chunk-W22WOQNK.mjs:663:5)
6
6
  at new PureTesteranto (file:///Users/adam/Code/testeranto/testeranto/bundles/pure/allTests/chunk-W22WOQNK.mjs:883:5)
7
7
  at Pure_default (file:///Users/adam/Code/testeranto/testeranto/bundles/pure/allTests/chunk-W22WOQNK.mjs:904:10)
8
- at file:///Users/adam/Code/testeranto/testeranto/bundles/pure/allTests/src/Pure.test.mjs?cacheBust=1752859436874:360:25
8
+ at file:///Users/adam/Code/testeranto/testeranto/bundles/pure/allTests/src/Pure.test.mjs?cacheBust=1752859984032:360:25
9
9
  at ModuleJob.run (node:internal/modules/esm/module_job:192:25)
10
10
  at async CustomizedModuleLoader.import (node:internal/modules/esm/loader:228:24)
11
11
  at launchPure (/Users/adam/Code/testeranto/src/PM/main.ts:577:7)
@@ -4,7 +4,7 @@
4
4
 
5
5
  <head>
6
6
  <meta name="description" content="Webpage description goes here" />
7
- <base href="https://adamwong246.github.io/testeranto" target="_blank">
7
+ <base href="https://adamwong246.github.io/testeranto/testeranto" target="_blank">
8
8
  <meta charset="utf-8" />
9
9
  <title>allTests - testeranto</title>
10
10
  <meta name="viewport" content="width=device-width, initial-scale=1" />
@@ -4,7 +4,7 @@
4
4
 
5
5
  <head>
6
6
  <meta name="description" content="Webpage description goes here" />
7
- <base href="https://adamwong246.github.io/testeranto" target="_blank">
7
+ <base href="https://adamwong246.github.io/testeranto/testeranto" target="_blank">
8
8
  <meta charset="utf-8" />
9
9
  <title>allTests - testeranto</title>
10
10
  <meta name="viewport" content="width=device-width, initial-scale=1" />
@@ -1,11 +1,11 @@
1
1
  TypeError: When.addArtifact is not a function
2
- at specification (file:///Users/adam/Code/testeranto/testeranto/bundles/pure/allTests/src/lib/BaseSuite.test/pure.test.mjs?cacheBust=1752859436874:139:14)
2
+ at specification (file:///Users/adam/Code/testeranto/testeranto/bundles/pure/allTests/src/lib/BaseSuite.test/pure.test.mjs?cacheBust=1752859984032:139:14)
3
3
  at new BaseBuilder (file:///Users/adam/Code/testeranto/testeranto/bundles/pure/allTests/chunk-W22WOQNK.mjs:15:18)
4
4
  at new ClassBuilder (file:///Users/adam/Code/testeranto/testeranto/bundles/pure/allTests/chunk-W22WOQNK.mjs:646:5)
5
5
  at new TesterantoCore (file:///Users/adam/Code/testeranto/testeranto/bundles/pure/allTests/chunk-W22WOQNK.mjs:663:5)
6
6
  at new PureTesteranto (file:///Users/adam/Code/testeranto/testeranto/bundles/pure/allTests/chunk-W22WOQNK.mjs:883:5)
7
7
  at Pure_default (file:///Users/adam/Code/testeranto/testeranto/bundles/pure/allTests/chunk-W22WOQNK.mjs:904:10)
8
- at file:///Users/adam/Code/testeranto/testeranto/bundles/pure/allTests/src/lib/BaseSuite.test/pure.test.mjs?cacheBust=1752859436874:315:25
8
+ at file:///Users/adam/Code/testeranto/testeranto/bundles/pure/allTests/src/lib/BaseSuite.test/pure.test.mjs?cacheBust=1752859984032:315:25
9
9
  at ModuleJob.run (node:internal/modules/esm/module_job:192:25)
10
10
  at async CustomizedModuleLoader.import (node:internal/modules/esm/loader:228:24)
11
11
  at launchPure (/Users/adam/Code/testeranto/src/PM/main.ts:577:7)
@@ -4,7 +4,7 @@
4
4
 
5
5
  <head>
6
6
  <meta name="description" content="Webpage description goes here" />
7
- <base href="https://adamwong246.github.io/testeranto" target="_blank">
7
+ <base href="https://adamwong246.github.io/testeranto/testeranto" target="_blank">
8
8
  <meta charset="utf-8" />
9
9
  <title>allTests - testeranto</title>
10
10
  <meta name="viewport" content="width=device-width, initial-scale=1" />
@@ -4,7 +4,7 @@
4
4
 
5
5
  <head>
6
6
  <meta name="description" content="Webpage description goes here" />
7
- <base href="https://adamwong246.github.io/testeranto" target="_blank">
7
+ <base href="https://adamwong246.github.io/testeranto/testeranto" target="_blank">
8
8
  <meta charset="utf-8" />
9
9
  <title>allTests - testeranto</title>
10
10
  <meta name="viewport" content="width=device-width, initial-scale=1" />
@@ -4,7 +4,7 @@
4
4
 
5
5
  <head>
6
6
  <meta name="description" content="Webpage description goes here" />
7
- <base href="https://adamwong246.github.io/testeranto" target="_blank">
7
+ <base href="https://adamwong246.github.io/testeranto/testeranto" target="_blank">
8
8
  <meta charset="utf-8" />
9
9
  <title>allTests - testeranto</title>
10
10
  <meta name="viewport" content="width=device-width, initial-scale=1" />
@@ -4,7 +4,7 @@
4
4
 
5
5
  <head>
6
6
  <meta name="description" content="Webpage description goes here" />
7
- <base href="https://adamwong246.github.io/testeranto" target="_blank">
7
+ <base href="https://adamwong246.github.io/testeranto/testeranto" target="_blank">
8
8
  <meta charset="utf-8" />
9
9
  <title>allTests - testeranto</title>
10
10
  <meta name="viewport" content="width=device-width, initial-scale=1" />
@@ -4,7 +4,7 @@
4
4
 
5
5
  <head>
6
6
  <meta name="description" content="Webpage description goes here" />
7
- <base href="https://adamwong246.github.io/testeranto" target="_blank">
7
+ <base href="https://adamwong246.github.io/testeranto/testeranto" target="_blank">
8
8
  <meta charset="utf-8" />
9
9
  <title>allTests - testeranto</title>
10
10
  <meta name="viewport" content="width=device-width, initial-scale=1" />
@@ -4,7 +4,7 @@
4
4
 
5
5
  <head>
6
6
  <meta name="description" content="Webpage description goes here" />
7
- <base href="https://adamwong246.github.io/testeranto" target="_blank">
7
+ <base href="https://adamwong246.github.io/testeranto/testeranto" target="_blank">
8
8
  <meta charset="utf-8" />
9
9
  <title>allTests - testeranto</title>
10
10
  <meta name="viewport" content="width=device-width, initial-scale=1" />
@@ -4,7 +4,7 @@
4
4
 
5
5
  <head>
6
6
  <meta name="description" content="Webpage description goes here" />
7
- <base href="https://adamwong246.github.io/testeranto" target="_blank">
7
+ <base href="https://adamwong246.github.io/testeranto/testeranto" target="_blank">
8
8
  <meta charset="utf-8" />
9
9
  <title>allTests - testeranto</title>
10
10
  <meta name="viewport" content="width=device-width, initial-scale=1" />
@@ -2,10 +2,10 @@ stdout > mark4
2
2
  args [
3
3
  '/Users/adam/.nvm/versions/node/v20.4.0/bin/node',
4
4
  '/Users/adam/Code/testeranto/testeranto/bundles/node/allTests/src/lib/pmProxy.test/index.mjs',
5
- '{"name":"src/lib/pmProxy.test/index.ts","ports":[],"fs":"testeranto/reports/allTests/src/lib/pmProxy.test/index/node","browserWSEndpoint":"ws://127.0.0.1:3234/devtools/browser/e86a7a37-a4ff-45dd-9f53-47f559d0b440"}',
6
- '/tmp/tpipe_0.4437348145810549'
5
+ '{"name":"src/lib/pmProxy.test/index.ts","ports":[],"fs":"testeranto/reports/allTests/src/lib/pmProxy.test/index/node","browserWSEndpoint":"ws://127.0.0.1:3234/devtools/browser/981b297f-74a2-4ec8-bdc5-43d81fffcd03"}',
6
+ '/tmp/tpipe_0.42363693000216696'
7
7
  ]
8
- receiveTestResourceConfig {"name":"src/lib/pmProxy.test/index.ts","ports":[],"fs":"testeranto/reports/allTests/src/lib/pmProxy.test/index/node","browserWSEndpoint":"ws://127.0.0.1:3234/devtools/browser/e86a7a37-a4ff-45dd-9f53-47f559d0b440"}
8
+ receiveTestResourceConfig {"name":"src/lib/pmProxy.test/index.ts","ports":[],"fs":"testeranto/reports/allTests/src/lib/pmProxy.test/index/node","browserWSEndpoint":"ws://127.0.0.1:3234/devtools/browser/981b297f-74a2-4ec8-bdc5-43d81fffcd03"}
9
9
  stderr > Given error 1: TypeError: store.butThenProxy is not a function
10
10
  at Then.thenCB (file:///Users/adam/Code/testeranto/testeranto/bundles/node/allTests/src/lib/pmProxy.test/index.mjs:137:31)
11
11
  at file:///Users/adam/Code/testeranto/testeranto/bundles/node/allTests/chunk-RF3LIUSG.mjs:606:29
@@ -105,6 +105,6 @@ const config: IProject = {
105
105
  importPlugins: [],
106
106
  },
107
107
  },
108
- reportDomain: "https://adamwong246.github.io/testeranto",
108
+ reportDomain: "https://adamwong246.github.io/testeranto/testeranto",
109
109
  };
110
110
  export default config;
package/tsc.log CHANGED
@@ -109,12 +109,12 @@ src/lib/BaseSuite.test/test.ts(248,35): error TS2322: Type 'TestableSuite' is no
109
109
  src/lib/BaseSuite.test/test.ts(254,7): error TS2322: Type '(suite: TestableSuite) => Promise<TestableSuite>' is not assignable to type '(zel: TestSelection, tr: ITTestResourceConfiguration, utils: PM) => Promise<(store: TestStore) => Promise<TestStore>>'.
110
110
  Types of parameters 'suite' and 'zel' are incompatible.
111
111
  Type 'TestSelection' is missing the following properties from type 'TestableSuite': name, givens, checks, store, and 10 more.
112
- src/lib/BaseSuite.test/test.ts(274,11): error TS2322: Type '() => void' is not assignable to type '((selector: string, page: string) => Promise<unknown>) | ((selector: string) => boolean) | ((selector: string) => boolean)'.
113
- Type '() => void' is not assignable to type '(selector: string, page: string) => Promise<unknown>'.
114
- Type 'void' is not assignable to type 'Promise<unknown>'.
115
- src/lib/BaseSuite.test/test.ts(276,11): error TS2322: Type '() => void' is not assignable to type '((p: any) => Promise<unknown>) | ((p: any) => string) | ((p: any) => string)'.
116
- Type '() => void' is not assignable to type '(p: any) => Promise<unknown>'.
117
- Type 'void' is not assignable to type 'Promise<unknown>'.
112
+ src/lib/BaseSuite.test/test.ts(274,11): error TS2322: Type '() => void' is not assignable to type '((selector: string) => boolean) | ((selector: string) => boolean) | ((selector: string, page: string) => Promise<unknown>)'.
113
+ Type '() => void' is not assignable to type '(selector: string) => boolean'.
114
+ Type 'void' is not assignable to type 'boolean'.
115
+ src/lib/BaseSuite.test/test.ts(276,11): error TS2322: Type '() => void' is not assignable to type '((p: any) => string) | ((p: any) => string) | ((p: any) => Promise<unknown>)'.
116
+ Type '() => void' is not assignable to type '(p: any) => string'.
117
+ Type 'void' is not assignable to type 'string'.
118
118
  src/lib/BaseSuite.test/test.ts(281,11): error TS2345: Argument of type 'null' is not assignable to parameter of type 'typeof BaseSuite'.
119
119
  src/lib/BaseSuite.test/test.ts(295,13): error TS2345: Argument of type 'null' is not assignable to parameter of type 'typeof BaseSuite'.
120
120
  src/lib/BaseSuite.test/test.ts(342,5): error TS2322: Type '(feature: string) => ((suite: TestableSuite) => TestableSuite)' is not assignable to type '(feature: string) => (ssel: TestSelection, utils: PM) => (store: TestStore) => Promise<TestSelection>'.
@@ -130,35 +130,34 @@ src/lib/BaseSuite.test/test.ts(446,44): error TS2554: Expected 1 arguments, but
130
130
  src/lib/BaseSuite.test/test.ts(453,48): error TS2554: Expected 1 arguments, but got 2.
131
131
  src/lib/BaseSuite.test/test.ts(455,3): error TS2322: Type '(store: I["istore"]) => I["istore"]' is not assignable to type '(store: TestStore, key: string, pm: IPM) => Promise<unknown>'.
132
132
  Type 'TestStore' is missing the following properties from type 'Promise<unknown>': then, catch, finally, [Symbol.toStringTag]
133
- src/lib/classBuilder.test/classBuilder.test.implementation.ts(11,3): error TS2741: Property 'ExtendedSuite' is missing in type '{ Default: string; }' but required in type 'TestSuiteImplementation<O>'.
134
- src/lib/classBuilder.test/classBuilder.test.implementation.ts(21,9): error TS2345: Argument of type 'typeof (Anonymous class)' is not assignable to parameter of type 'ISuiteKlasser<I, O>'.
133
+ src/lib/classBuilder.test/classBuilder.test.implementation.ts(12,3): error TS2741: Property 'ExtendedSuite' is missing in type '{ Default: string; }' but required in type 'TestSuiteImplementation<O>'.
134
+ src/lib/classBuilder.test/classBuilder.test.implementation.ts(22,9): error TS2345: Argument of type 'typeof (Anonymous class)' is not assignable to parameter of type 'ISuiteKlasser<I, O>'.
135
135
  Type 'typeof (Anonymous class)' provides no match for the signature '(name: string, index: number, givens: IGivens<I>, checks: BaseCheck<I>[]): BaseSuite<I, O>'.
136
- src/lib/classBuilder.test/classBuilder.test.implementation.ts(34,9): error TS2345: Argument of type 'typeof (Anonymous class)' is not assignable to parameter of type 'ISuiteKlasser<I, O>'.
136
+ src/lib/classBuilder.test/classBuilder.test.implementation.ts(35,9): error TS2345: Argument of type 'typeof (Anonymous class)' is not assignable to parameter of type 'ISuiteKlasser<I, O>'.
137
137
  Type 'typeof (Anonymous class)' provides no match for the signature '(name: string, index: number, givens: IGivens<I>, checks: BaseCheck<I>[]): BaseSuite<I, O>'.
138
- src/lib/classBuilder.test/classBuilder.test.implementation.ts(47,9): error TS2345: Argument of type 'typeof (Anonymous class)' is not assignable to parameter of type 'ISuiteKlasser<I, O>'.
138
+ src/lib/classBuilder.test/classBuilder.test.implementation.ts(48,9): error TS2345: Argument of type 'typeof (Anonymous class)' is not assignable to parameter of type 'ISuiteKlasser<I, O>'.
139
139
  Type 'typeof (Anonymous class)' provides no match for the signature '(name: string, index: number, givens: IGivens<I>, checks: BaseCheck<I>[]): BaseSuite<I, O>'.
140
- src/lib/classBuilder.test/classBuilder.test.implementation.ts(60,9): error TS2345: Argument of type 'typeof (Anonymous class)' is not assignable to parameter of type 'ISuiteKlasser<I, O>'.
140
+ src/lib/classBuilder.test/classBuilder.test.implementation.ts(61,9): error TS2345: Argument of type 'typeof (Anonymous class)' is not assignable to parameter of type 'ISuiteKlasser<I, O>'.
141
141
  Type 'typeof (Anonymous class)' provides no match for the signature '(name: string, index: number, givens: IGivens<I>, checks: BaseCheck<I>[]): BaseSuite<I, O>'.
142
- src/lib/classBuilder.test/classBuilder.test.implementation.ts(73,9): error TS2345: Argument of type 'typeof (Anonymous class)' is not assignable to parameter of type 'ISuiteKlasser<any, any>'.
142
+ src/lib/classBuilder.test/classBuilder.test.implementation.ts(74,9): error TS2345: Argument of type 'typeof (Anonymous class)' is not assignable to parameter of type 'ISuiteKlasser<any, any>'.
143
143
  Type 'typeof (Anonymous class)' provides no match for the signature '(name: string, index: number, givens: IGivens<any>, checks: BaseCheck<any>[]): BaseSuite<any, any>'.
144
- src/lib/classBuilder.test/classBuilder.test.implementation.ts(182,30): error TS2322: Type '(builder: ClassBuilder<any, any, any>) => Promise<ClassBuilder<any, any, any>>' is not assignable to type '(builder: ClassBuilder<any, any, any>) => ClassBuilder<any, any, any>'.
144
+ src/lib/classBuilder.test/classBuilder.test.implementation.ts(183,30): error TS2322: Type '(builder: ClassBuilder<any, any, any>) => Promise<ClassBuilder<any, any, any>>' is not assignable to type '(builder: ClassBuilder<any, any, any>) => ClassBuilder<any, any, any>'.
145
145
  Type 'Promise<ClassBuilder<any, any, any>>' is missing the following properties from type 'ClassBuilder<any, any, any>': specs, assertThis, testResourceRequirement, artifacts, and 14 more.
146
- src/lib/classBuilder.test/classBuilder.test.implementation.ts(184,23): error TS2339: Property 'testRun' does not exist on type 'ClassBuilder<any, any, any>'.
147
- src/lib/classBuilder.test/classBuilder.test.implementation.ts(199,20): error TS2322: Type 'PassThrough' is not assignable to type '() => ClassBuilder<any, any, any>'.
146
+ src/lib/classBuilder.test/classBuilder.test.implementation.ts(185,23): error TS2339: Property 'testRun' does not exist on type 'ClassBuilder<any, any, any>'.
147
+ src/lib/classBuilder.test/classBuilder.test.implementation.ts(200,20): error TS2322: Type 'PassThrough' is not assignable to type '() => ClassBuilder<any, any, any>'.
148
148
  Type 'Transform' provides no match for the signature '(): ClassBuilder<any, any, any>'.
149
- src/lib/classBuilder.test/classBuilder.test.implementation.ts(200,41): error TS2322: Type 'boolean' is not assignable to type '() => ClassBuilder<any, any, any>'.
150
- src/lib/classBuilder.test/classBuilder.test.implementation.ts(201,40): error TS2322: Type 'boolean' is not assignable to type '() => ClassBuilder<any, any, any>'.
151
- src/lib/classBuilder.test/classBuilder.test.interface.ts(4,14): error TS2741: Property 'beforeAll' is missing in type '{ beforeEach: (subject: BaseBuilder<any, any, any, any, any, any>, initializer: (c?: any) => () => BaseBuilder<any, any, any, any, any, any>) => Promise<() => BaseBuilder<any, any, any, any, any, any>>; ... 4 more ...; assertThis: (x: any) => void; }' but required in type 'ITestInterface<I>'.
152
- src/lib/classBuilder.test/classBuilder.test.interface.ts(9,26): error TS2554: Expected 1 arguments, but got 2.
153
- src/lib/classBuilder.test/classBuilder.test.interface.ts(12,26): error TS2554: Expected 1 arguments, but got 2.
154
- src/lib/classBuilder.test/classBuilder.test.specification.ts(21,28): error TS2554: Expected 4 arguments, but got 3.
155
- src/lib/classBuilder.test/classBuilder.test.specification.ts(26,37): error TS2554: Expected 4 arguments, but got 3.
156
- src/lib/classBuilder.test/classBuilder.test.specification.ts(69,37): error TS2554: Expected 4 arguments, but got 3.
157
- src/lib/classBuilder.test/classBuilder.test.specification.ts(70,11): error TS2552: Cannot find name 'implementation'. Did you mean 'DOMImplementation'?
158
- src/lib/classBuilder.test/classBuilder.test.specification.ts(74,36): error TS2554: Expected 4 arguments, but got 3.
159
- src/lib/classBuilder.test/classBuilder.test.specification.ts(88,54): error TS2304: Cannot find name 'ITestJob'.
160
- src/lib/classBuilder.test/classBuilder.test.specification.ts(107,15): error TS2554: Expected 4 arguments, but got 1.
149
+ src/lib/classBuilder.test/classBuilder.test.implementation.ts(201,41): error TS2322: Type 'boolean' is not assignable to type '() => ClassBuilder<any, any, any>'.
150
+ src/lib/classBuilder.test/classBuilder.test.implementation.ts(202,40): error TS2322: Type 'boolean' is not assignable to type '() => ClassBuilder<any, any, any>'.
151
+ src/lib/classBuilder.test/classBuilder.test.interface.ts(5,14): error TS2741: Property 'beforeAll' is missing in type '{ beforeEach: (subject: BaseBuilder<any, any, any, any, any, any>, initializer: (c?: any) => () => BaseBuilder<any, any, any, any, any, any>) => Promise<() => BaseBuilder<any, any, any, any, any, any>>; ... 4 more ...; assertThis: (x: any) => void; }' but required in type 'ITestInterface<I>'.
152
+ src/lib/classBuilder.test/classBuilder.test.interface.ts(10,26): error TS2554: Expected 1 arguments, but got 2.
153
+ src/lib/classBuilder.test/classBuilder.test.interface.ts(13,26): error TS2554: Expected 1 arguments, but got 2.
154
+ src/lib/classBuilder.test/classBuilder.test.specification.ts(22,28): error TS2554: Expected 4 arguments, but got 3.
155
+ src/lib/classBuilder.test/classBuilder.test.specification.ts(27,37): error TS2554: Expected 4 arguments, but got 3.
156
+ src/lib/classBuilder.test/classBuilder.test.specification.ts(70,37): error TS2554: Expected 4 arguments, but got 3.
157
+ src/lib/classBuilder.test/classBuilder.test.specification.ts(71,11): error TS2304: Cannot find name 'implementation'.
158
+ src/lib/classBuilder.test/classBuilder.test.specification.ts(75,36): error TS2554: Expected 4 arguments, but got 3.
161
159
  src/lib/classBuilder.test/classBuilder.test.specification.ts(108,15): error TS2554: Expected 4 arguments, but got 1.
160
+ src/lib/classBuilder.test/classBuilder.test.specification.ts(109,15): error TS2554: Expected 4 arguments, but got 1.
162
161
  src/lib/classBuilder.ts(90,18): error TS2556: A spread argument must either have a tuple type or be passed to a rest parameter.
163
162
  src/lib/classBuilder.ts(105,28): error TS2556: A spread argument must either have a tuple type or be passed to a rest parameter.
164
163
  src/lib/core.test/core.test.implementation.ts(18,9): error TS2304: Cannot find name 'specification'.
@@ -210,19 +209,19 @@ src/lib/pmProxy.test/implementation.ts(21,5): error TS2322: Type '(method: IProx
210
209
  Types of parameters 'store' and 'ssel' are incompatible.
211
210
  Property 'butThenProxy' is missing in type '{ proxies: ITestProxies; filepath: string; mockPm: IPM; }' but required in type '{ butThenProxy: IProxy; }'.
212
211
  src/lib/pmProxy.test/implementation.ts(44,35): error TS2339: Property 'getLastCall' does not exist on type 'IPM'.
213
- Property 'getLastCall' does not exist on type 'PM_Node'.
212
+ Property 'getLastCall' does not exist on type 'PM_Pure'.
214
213
  src/lib/pmProxy.test/implementation.ts(45,38): error TS2339: Property 'getLastCall' does not exist on type 'IPM'.
215
- Property 'getLastCall' does not exist on type 'PM_Node'.
214
+ Property 'getLastCall' does not exist on type 'PM_Pure'.
216
215
  src/lib/pmProxy.test/implementation.ts(52,35): error TS2339: Property 'getLastCall' does not exist on type 'IPM'.
217
- Property 'getLastCall' does not exist on type 'PM_Node'.
216
+ Property 'getLastCall' does not exist on type 'PM_Pure'.
218
217
  src/lib/pmProxy.test/implementation.ts(58,19): error TS2322: Type '"screen.png"' is not assignable to type '`${string}.webm`'.
219
218
  src/lib/pmProxy.test/implementation.ts(64,35): error TS2339: Property 'getLastCall' does not exist on type 'IPM'.
220
- Property 'getLastCall' does not exist on type 'PM_Node'.
219
+ Property 'getLastCall' does not exist on type 'PM_Pure'.
221
220
  src/lib/pmProxy.test/implementation.ts(65,38): error TS2339: Property 'getLastCall' does not exist on type 'IPM'.
222
- Property 'getLastCall' does not exist on type 'PM_Node'.
221
+ Property 'getLastCall' does not exist on type 'PM_Pure'.
223
222
  src/lib/pmProxy.test/implementation.ts(70,19): error TS2322: Type '"shot.png"' is not assignable to type '`${string}.webm`'.
224
223
  src/lib/pmProxy.test/implementation.ts(73,35): error TS2339: Property 'getLastCall' does not exist on type 'IPM'.
225
- Property 'getLastCall' does not exist on type 'PM_Node'.
224
+ Property 'getLastCall' does not exist on type 'PM_Pure'.
226
225
  src/lib/pmProxy.test/implementation.ts(102,5): error TS2322: Type '(s: string) => string' is not assignable to type '() => [string, string]'.
227
226
  Target signature provides too few arguments. Expected 1 or more, but got 0.
228
227
  src/lib/pmProxy.test/index.ts(17,3): error TS2345: Argument of type 'ITestImplementation<I, O, M>' is not assignable to parameter of type 'Omit<{ suites: TestSuiteImplementation<O>; givens: TestGivenImplementation<I, O>; whens: TestWhenImplementation<I, O>; thens: TestThenImplementation<...>; checks: TestCheckImplementation<...>; }, never>'.
@@ -300,11 +299,10 @@ src/Project.tsx(144,30): error TS2551: Property 'runTimeError' does not exist on
300
299
  src/Project.tsx(328,40): error TS2551: Property 'runTimeError' does not exist on type '{ runTimeErrors: number | "?" | undefined; typeErrors: number | "?" | undefined; staticErrors: number | "?" | undefined; prompt: string | undefined; failingFeatures: object | undefined; }'. Did you mean 'runTimeErrors'?
301
300
  src/Project.tsx(398,38): error TS2345: Argument of type 'FunctionComponentElement<{}>' is not assignable to parameter of type 'ReactNode'.
302
301
  Property 'children' is missing in type 'FunctionComponentElement<{}>' but required in type 'ReactPortal'.
303
- src/Pure.test.ts(297,3): error TS2345: Argument of type '{ suites: { Default: string; }; givens: { Default: () => { pm: IPM; config: {}; proxies: { butThenProxy: (pm: IPM, path: string) => { writeFileSync: (p: string, c: string) => any; testResourceConfiguration: ITTestResourceConfiguration; client: Socket; server: any; } | { ...; } | { ...; }; andWhenProxy: (pm: IPM, pat...' is not assignable to parameter of type 'Omit<{ suites: TestSuiteImplementation<PureO>; givens: TestGivenImplementation<PureI, PureO>; whens: TestWhenImplementation<PureI, PureO>; thens: TestThenImplementation<...>; checks: TestCheckImplementation<...>; }, never>'.
304
- The types returned by 'checks.Default(...)' are incompatible between these types.
305
- Type 'IPM' is not assignable to type '() => IPM'.
306
- Type 'PM_Node' is not assignable to type '() => IPM'.
307
- Type 'PM_Node' provides no match for the signature '(): IPM'.
302
+ src/Pure.test.ts(297,3): error TS2345: Argument of type '{ suites: { Default: string; }; givens: { Default: () => { pm: IPM; config: {}; proxies: { butThenProxy: (pm: IPM, path: string) => { writeFileSync: (p: string, c: string) => any; server: PuppetMasterServer; testResourceConfiguration: ITTestResourceConfiguration; } | { ...; } | { ...; }; andWhenProxy: (pm: IPM, path...' is not assignable to parameter of type 'Omit<{ suites: TestSuiteImplementation<PureO>; givens: TestGivenImplementation<PureI, PureO>; whens: TestWhenImplementation<PureI, PureO>; thens: TestThenImplementation<...>; checks: TestCheckImplementation<...>; }, never>'.
303
+ The types returned by 'givens.Default(...)' are incompatible between these types.
304
+ Type '{ pm: IPM; config: {}; proxies: { butThenProxy: (pm: IPM, path: string) => { writeFileSync: (p: string, c: string) => any; server: PuppetMasterServer; testResourceConfiguration: ITTestResourceConfiguration; } | { ...; } | { ...; }; andWhenProxy: (pm: IPM, path: string) => { ...; } | ... 1 more ... | { ...; }; before...' is not assignable to type '() => IPM'.
305
+ Type '{ pm: IPM; config: {}; proxies: { butThenProxy: (pm: IPM, path: string) => { writeFileSync: (p: string, c: string) => any; server: PuppetMasterServer; testResourceConfiguration: ITTestResourceConfiguration; } | { ...; } | { ...; }; andWhenProxy: (pm: IPM, path: string) => { ...; } | ... 1 more ... | { ...; }; before...' provides no match for the signature '(): IPM'.
308
306
  src/Pure.ts(32,7): error TS2345: Argument of type 'ITestImplementation<I, O, M>' is not assignable to parameter of type 'Omit<{ suites: TestSuiteImplementation<O>; givens: TestGivenImplementation<I, O>; whens: TestWhenImplementation<I, O>; thens: TestThenImplementation<...>; checks: TestCheckImplementation<...>; }, keyof M> & M & { ...; }'.
309
307
  Type 'Omit<{ suites: TestSuiteImplementation<O>; givens: TestGivenImplementation<I, O>; whens: TestWhenImplementation<I, O>; thens: TestThenImplementation<...>; checks: TestCheckImplementation<...>; }, keyof M>' is missing the following properties from type '{ suites: Record<string, any>; givens: Record<string, any>; whens: Record<string, any>; thens: Record<string, any>; checks: Record<string, any>; }': suites, givens, whens, thens, checks
310
308
  src/Pure.ts(41,9): error TS2416: Property 'receiveTestResourceConfig' in type 'PureTesteranto<I, O, M>' is not assignable to the same property in base type 'TesterantoCore<I, O, M>'.