testeranto 0.135.0 → 0.140.1

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 (187) hide show
  1. package/.aider.chat.history.md +13976 -0
  2. package/.aider.input.history +530 -0
  3. package/.aider.tags.cache.v3/{d8/b0/a8966fcd65890fd9f70d7afe8141.val → bd/91/b71f967fd074cf4b757081b429b7.val} +0 -0
  4. package/.aider.tags.cache.v3/cache.db +0 -0
  5. package/.aider.tags.cache.v3/{8e/ec/2d4659a1589a0187a757ab1cbefa.val → fb/96/b0f91c7e75e08fc5a6907633cf99.val} +0 -0
  6. package/README.md +29 -135
  7. package/bundle.js +1 -1
  8. package/dist/common/src/Init.js +4 -1
  9. package/dist/common/src/Node.js +1 -1
  10. package/dist/common/src/PM/__tests__/nodeSidecar.testeranto.js +2 -2
  11. package/dist/common/src/Web.js +2 -2
  12. package/dist/common/src/build.js +7 -73
  13. package/dist/common/src/defaultConfig.js +0 -1
  14. package/dist/common/src/lib/abstractBase.js +2 -0
  15. package/dist/common/src/lib/basebuilder.js +4 -0
  16. package/dist/common/src/lib/core.js +2 -0
  17. package/dist/common/src/run.js +1 -1
  18. package/dist/common/src/utils/buildTemplates.js +88 -0
  19. package/dist/common/tsconfig.common.tsbuildinfo +1 -1
  20. package/dist/module/src/Init.js +4 -1
  21. package/dist/module/src/Node.js +1 -1
  22. package/dist/module/src/PM/__tests__/nodeSidecar.testeranto.js +2 -2
  23. package/dist/module/src/Project.js +41 -47
  24. package/dist/module/src/TestReport.js +34 -31
  25. package/dist/module/src/Web.js +2 -2
  26. package/dist/module/src/build.js +7 -73
  27. package/dist/module/src/defaultConfig.js +0 -1
  28. package/dist/module/src/lib/abstractBase.js +2 -0
  29. package/dist/module/src/lib/basebuilder.js +4 -0
  30. package/dist/module/src/lib/core.js +2 -0
  31. package/dist/module/src/run.js +1 -1
  32. package/dist/module/src/utils/buildTemplates.js +82 -0
  33. package/dist/module/tsconfig.module.tsbuildinfo +1 -1
  34. package/dist/prebuild/Project.js +62 -13
  35. package/dist/prebuild/TestReport.js +39 -18
  36. package/dist/prebuild/build.mjs +96 -73
  37. package/dist/prebuild/init-docs.mjs +0 -4
  38. package/dist/tsconfig.tsbuildinfo +1 -0
  39. package/dist/types/src/CoreTypes.d.ts +5 -3
  40. package/dist/types/src/Node.d.ts +3 -3
  41. package/dist/types/src/PM/__tests__/nodeSidecar.testeranto.d.ts +17 -1
  42. package/dist/types/src/PM/__tests__/pureSidecar.testeranto.d.ts +17 -1
  43. package/dist/types/src/PM/__tests__/webSidecar.testeranto.d.ts +17 -1
  44. package/dist/types/src/PM/nodeSidecar.d.ts +2 -2
  45. package/dist/types/src/Pure.d.ts +3 -3
  46. package/dist/types/src/Types.d.ts +18 -14
  47. package/dist/types/src/Web.d.ts +3 -3
  48. package/dist/types/src/lib/abstractBase.d.ts +8 -8
  49. package/dist/types/src/lib/basebuilder.d.ts +3 -3
  50. package/dist/types/src/lib/classBuilder.d.ts +2 -2
  51. package/dist/types/src/lib/core.d.ts +2 -2
  52. package/dist/types/src/lib/index.d.ts +7 -6
  53. package/dist/types/src/lib/types.d.ts +8 -8
  54. package/dist/types/src/mothership/test.d.ts +20 -1
  55. package/dist/types/src/utils/buildTemplates.d.ts +3 -0
  56. package/dist/types/tsconfig.types.tsbuildinfo +1 -1
  57. package/docs/index.md +344 -54
  58. package/docs/style.md +116 -0
  59. package/docs.html +537 -0
  60. package/example.css +351 -0
  61. package/fonts/M_PLUS_Rounded_1c/MPLUSRounded1c-Black.ttf +0 -0
  62. package/fonts/M_PLUS_Rounded_1c/MPLUSRounded1c-Bold.ttf +0 -0
  63. package/fonts/M_PLUS_Rounded_1c/MPLUSRounded1c-ExtraBold.ttf +0 -0
  64. package/fonts/M_PLUS_Rounded_1c/MPLUSRounded1c-Light.ttf +0 -0
  65. package/fonts/M_PLUS_Rounded_1c/MPLUSRounded1c-Medium.ttf +0 -0
  66. package/fonts/M_PLUS_Rounded_1c/MPLUSRounded1c-Regular.ttf +0 -0
  67. package/fonts/M_PLUS_Rounded_1c/MPLUSRounded1c-Thin.ttf +0 -0
  68. package/fonts/M_PLUS_Rounded_1c/OFL.txt +91 -0
  69. package/index.html +246 -24
  70. package/logo.svg +72 -0
  71. package/package.json +6 -2
  72. package/scripts/compile-docs.js +89 -0
  73. package/src/CoreTypes.ts +24 -43
  74. package/src/Init.ts +4 -4
  75. package/src/Node.ts +6 -20
  76. package/src/PM/__tests__/nodeSidecar.testeranto.ts +13 -20
  77. package/src/PM/__tests__/pureSidecar.testeranto.ts +8 -15
  78. package/src/PM/__tests__/webSidecar.testeranto.ts +8 -15
  79. package/src/PM/nodeSidecar.ts +2 -2
  80. package/src/PM/pure.ts +0 -4
  81. package/src/Project.tsx +289 -292
  82. package/src/Pure.ts +13 -14
  83. package/src/PureSidecar.ts +1 -0
  84. package/src/TestReport.tsx +179 -165
  85. package/src/Types.ts +29 -144
  86. package/src/Web.ts +15 -11
  87. package/src/build.ts +22 -73
  88. package/src/defaultConfig.ts +2 -1
  89. package/src/lib/BaseSuite.test.ts +457 -0
  90. package/src/lib/BaseSuite.ts +155 -0
  91. package/src/lib/abstractBase.ts +7 -162
  92. package/src/lib/basebuilder.ts +11 -11
  93. package/src/lib/classBuilder.ts +8 -3
  94. package/src/lib/core.ts +12 -12
  95. package/src/lib/index.ts +21 -24
  96. package/src/lib/types.ts +23 -9
  97. package/src/mothership/test.ts +13 -10
  98. package/src/run.ts +1 -1
  99. package/src/style.css +1 -1
  100. package/src/utils/buildTemplates.ts +88 -0
  101. package/style.css +496 -0
  102. package/testeranto/bundles/node/{mothership/chunk-V2EQEXU2.mjs → allTests/chunk-4PJCC2XT.mjs} +66 -59
  103. package/testeranto/bundles/node/allTests/metafile.json +4151 -0
  104. package/testeranto/bundles/node/allTests/src/PM/__tests__/nodeSidecar.testeranto.mjs +187 -0
  105. package/testeranto/bundles/node/{mothership → allTests}/src/PM/__tests__/pureSidecar.testeranto.mjs +1 -1
  106. package/testeranto/bundles/node/{mothership → allTests}/src/PM/__tests__/webSidecar.testeranto.mjs +1 -1
  107. package/testeranto/bundles/node/allTests/src/lib/BaseSuite.test.mjs +305 -0
  108. package/testeranto/bundles/node/{mothership → allTests}/src/mothership/test.mjs +1 -1
  109. package/testeranto/dev.html +29 -0
  110. package/testeranto/index.html +28 -27
  111. package/testeranto/reports/allTests/config.json +57 -0
  112. package/testeranto/reports/{mothership/index.html → allTests/dev.html} +2 -0
  113. package/testeranto/reports/allTests/index.html +26 -0
  114. package/testeranto/reports/{mothership/src/PM/__tests__/sidecar.testeranto/node/index.html → allTests/src/PM/__tests__/nodeSidecar.testeranto/node/dev.html} +4 -3
  115. package/testeranto/reports/allTests/src/PM/__tests__/nodeSidecar.testeranto/node/index.html +21 -0
  116. package/testeranto/reports/allTests/src/PM/__tests__/nodeSidecar.testeranto/node/lint_errors.json +80 -0
  117. package/testeranto/reports/allTests/src/PM/__tests__/nodeSidecar.testeranto/node/message +1 -0
  118. package/testeranto/reports/allTests/src/PM/__tests__/nodeSidecar.testeranto/node/prompt.txt +8 -0
  119. package/testeranto/reports/allTests/src/PM/__tests__/nodeSidecar.testeranto/node/type_errors.txt +28 -0
  120. package/testeranto/reports/{mothership/src/PM/__tests__/webSidecar.testeranto/node/index.html → allTests/src/PM/__tests__/pureSidecar.testeranto/node/dev.html} +4 -3
  121. package/testeranto/reports/allTests/src/PM/__tests__/pureSidecar.testeranto/node/index.html +21 -0
  122. package/testeranto/reports/{mothership → allTests}/src/PM/__tests__/pureSidecar.testeranto/node/lint_errors.json +12 -12
  123. package/testeranto/reports/allTests/src/PM/__tests__/pureSidecar.testeranto/node/message +1 -0
  124. package/testeranto/reports/allTests/src/PM/__tests__/pureSidecar.testeranto/node/prompt.txt +8 -0
  125. package/testeranto/reports/allTests/src/PM/__tests__/pureSidecar.testeranto/node/type_errors.txt +32 -0
  126. package/testeranto/reports/{mothership/src/PM/__tests__/nodeSidecar.testeranto/node/index.html → allTests/src/PM/__tests__/webSidecar.testeranto/node/dev.html} +4 -3
  127. package/testeranto/reports/allTests/src/PM/__tests__/webSidecar.testeranto/node/index.html +21 -0
  128. package/testeranto/reports/{mothership → allTests}/src/PM/__tests__/webSidecar.testeranto/node/lint_errors.json +12 -12
  129. package/testeranto/reports/allTests/src/PM/__tests__/webSidecar.testeranto/node/message +1 -0
  130. package/testeranto/reports/allTests/src/PM/__tests__/webSidecar.testeranto/node/prompt.txt +8 -0
  131. package/testeranto/reports/allTests/src/PM/__tests__/webSidecar.testeranto/node/type_errors.txt +32 -0
  132. package/testeranto/reports/allTests/src/lib/BaseSuite.test/node/console_log.txt +35 -0
  133. package/testeranto/reports/{mothership/src/PM/__tests__/pureSidecar.testeranto/node/index.html → allTests/src/lib/BaseSuite.test/node/dev.html} +4 -3
  134. package/testeranto/reports/allTests/src/lib/BaseSuite.test/node/index.html +21 -0
  135. package/testeranto/reports/allTests/src/lib/BaseSuite.test/node/lint_errors.json +608 -0
  136. package/testeranto/reports/allTests/src/lib/BaseSuite.test/node/message +1 -0
  137. package/testeranto/reports/allTests/src/lib/BaseSuite.test/node/prompt.txt +7 -0
  138. package/testeranto/reports/allTests/src/lib/BaseSuite.test/node/type_errors.txt +68 -0
  139. package/testeranto/reports/allTests/src/mothership/test/node/dev.html +21 -0
  140. package/testeranto/reports/allTests/src/mothership/test/node/index.html +21 -0
  141. package/testeranto/reports/allTests/src/mothership/test/node/message +1 -0
  142. package/testeranto/reports/allTests/src/mothership/test/node/prompt.txt +8 -0
  143. package/testeranto/reports/allTests/src/mothership/test/node/type_errors.txt +24 -0
  144. package/testeranto/reports/allTests/summary.json +37 -0
  145. package/testeranto.config.ts +16 -26
  146. package/tsc.log +66 -69
  147. package/dist/common/src/SP__Polygon.test.js +0 -10
  148. package/dist/module/src/ReportClient.js +0 -132
  149. package/dist/module/src/SP__Polygon.test.js +0 -8
  150. package/dist/prebuild/ReportClient.js +0 -3
  151. package/dist/types/src/SP__Polygon.test.d.ts +0 -1
  152. package/src/ReportClient.tsx +0 -164
  153. package/src/SP__Polygon.test.ts +0 -13
  154. package/testeranto/ReportClient.css +0 -11367
  155. package/testeranto/ReportClient.js +0 -24641
  156. package/testeranto/bundles/node/mothership/metafile.json +0 -389
  157. package/testeranto/bundles/node/mothership/src/PM/__tests__/nodeSidecar.testeranto.mjs +0 -1219
  158. package/testeranto/bundles/node/mothership/src/PM/__tests__/sidecar.testeranto.mjs +0 -1199
  159. package/testeranto/reports/mothership/config.json +0 -25
  160. package/testeranto/reports/mothership/src/PM/__tests__/nodeSidecar.testeranto/node/console_log.txt +0 -0
  161. package/testeranto/reports/mothership/src/PM/__tests__/nodeSidecar.testeranto/node/lint_errors.json +0 -1564
  162. package/testeranto/reports/mothership/src/PM/__tests__/nodeSidecar.testeranto/node/prompt.txt +0 -22
  163. package/testeranto/reports/mothership/src/PM/__tests__/nodeSidecar.testeranto/node/type_errors.txt +0 -35
  164. package/testeranto/reports/mothership/src/PM/__tests__/pureSidecar.testeranto/node/prompt.txt +0 -12
  165. package/testeranto/reports/mothership/src/PM/__tests__/pureSidecar.testeranto/node/type_errors.txt +0 -26
  166. package/testeranto/reports/mothership/src/PM/__tests__/sidecar.testeranto/node/bdd_errors.txt +0 -1
  167. package/testeranto/reports/mothership/src/PM/__tests__/sidecar.testeranto/node/console_log.txt +0 -0
  168. package/testeranto/reports/mothership/src/PM/__tests__/sidecar.testeranto/node/lint_errors.json +0 -1564
  169. package/testeranto/reports/mothership/src/PM/__tests__/sidecar.testeranto/node/log.txt +0 -0
  170. package/testeranto/reports/mothership/src/PM/__tests__/sidecar.testeranto/node/prompt.txt +0 -22
  171. package/testeranto/reports/mothership/src/PM/__tests__/sidecar.testeranto/node/tests.json +0 -56
  172. package/testeranto/reports/mothership/src/PM/__tests__/sidecar.testeranto/node/type_errors.txt +0 -29
  173. package/testeranto/reports/mothership/src/PM/__tests__/webSidecar.testeranto/node/prompt.txt +0 -12
  174. package/testeranto/reports/mothership/src/PM/__tests__/webSidecar.testeranto/node/type_errors.txt +0 -26
  175. package/testeranto/reports/mothership/src/mothership/test/node/bdd_errors.txt +0 -1
  176. package/testeranto/reports/mothership/src/mothership/test/node/console_log.txt +0 -4
  177. package/testeranto/reports/mothership/src/mothership/test/node/index.html +0 -20
  178. package/testeranto/reports/mothership/src/mothership/test/node/log.txt +0 -0
  179. package/testeranto/reports/mothership/src/mothership/test/node/prompt.txt +0 -12
  180. package/testeranto/reports/mothership/src/mothership/test/node/tests.json +0 -24
  181. package/testeranto/reports/mothership/src/mothership/test/node/type_errors.txt +0 -18
  182. package/testeranto/reports/mothership/summary.json +0 -9
  183. /package/testeranto/bundles/node/{mothership → allTests}/chunk-PG6KUKNP.mjs +0 -0
  184. /package/testeranto/bundles/pure/{mothership → allTests}/metafile.json +0 -0
  185. /package/testeranto/bundles/web/{mothership → allTests}/metafile.json +0 -0
  186. /package/testeranto/reports/{mothership/src/PM/__tests__/nodeSidecar.testeranto → allTests/src/lib/BaseSuite.test}/node/log.txt +0 -0
  187. /package/testeranto/reports/{mothership → allTests}/src/mothership/test/node/lint_errors.json +0 -0
package/src/Project.tsx CHANGED
@@ -1,67 +1,45 @@
1
1
  /* eslint-disable @typescript-eslint/no-unused-vars */
2
2
  import ReactDom from "react-dom/client";
3
- import React, { ReactNode, useEffect, useState } from "react";
3
+ import React, { useEffect, useState } from "react";
4
4
  import { Col, Nav, Row, Tab, Table } from "react-bootstrap";
5
5
 
6
6
  import { Footer } from "./Footer";
7
- import { ITestTypes, IRunTime, IBuiltConfig } from "./lib";
7
+ import { IBuiltConfig } from "./lib";
8
8
 
9
- import 'bootstrap/dist/css/bootstrap.min.css';
10
- import "./style.css"
9
+ import "bootstrap/dist/css/bootstrap.min.css";
10
+ import "./style.css";
11
11
  import { ISummary } from "./Types";
12
12
 
13
-
14
- // type ICollation = {
15
- // name: string;
16
- // runTime: IRunTime;
17
- // tr: {
18
- // ports: number;
19
- // };
20
- // sidecars: ITestTypes[];
21
- // staticAnalysis: number | "?";
22
- // typeErrors: number | "?";
23
- // bddErrors: number | "?";
24
- // prompt: string | "?";
25
- // };
26
-
27
- // type ICollations = ICollation[];
28
-
29
13
  const ExternalFeatures = ({ summary }: { summary: ISummaries }) => {
30
- return <div>
31
-
32
- <Row>
33
- <Tab.Container id="external-features-tab-container" >
34
- <Row>
35
-
36
- <Col sm={1}>
37
- <Nav variant="pills" className="flex-column">
38
-
39
- <Nav.Item>
40
- <Nav.Link eventKey={"log"}>
41
- log
42
- </Nav.Link>
43
- <Nav.Link eventKey={"steps"}>
44
- steps
45
- </Nav.Link>
46
- </Nav.Item>
47
-
48
- </Nav>
49
- </Col>
50
-
51
- <Col sm={11}>
52
- <Tab.Content>
53
- <Tab.Pane eventKey={"log"}>
54
- {/* <pre><code>{log}</code></pre> */}
55
- </Tab.Pane>
56
-
57
- <Tab.Pane eventKey={"steps"}>
58
-
59
- <Tab.Container id="secondary-tab-container" defaultActiveKey="first">
60
- <Row>
61
- <Col sm={3}>
62
- <Nav variant="pills" className="flex-column">
63
-
64
- {/* {
14
+ return (
15
+ <div>
16
+ <Row>
17
+ <Tab.Container id="external-features-tab-container">
18
+ <Row>
19
+ <Col sm={1}>
20
+ <Nav variant="pills" className="flex-column">
21
+ <Nav.Item>
22
+ <Nav.Link eventKey={"log"}>log</Nav.Link>
23
+ <Nav.Link eventKey={"steps"}>steps</Nav.Link>
24
+ </Nav.Item>
25
+ </Nav>
26
+ </Col>
27
+
28
+ <Col sm={11}>
29
+ <Tab.Content>
30
+ <Tab.Pane eventKey={"log"}>
31
+ {/* <pre><code>{log}</code></pre> */}
32
+ </Tab.Pane>
33
+
34
+ <Tab.Pane eventKey={"steps"}>
35
+ <Tab.Container
36
+ id="secondary-tab-container"
37
+ defaultActiveKey="first"
38
+ >
39
+ <Row>
40
+ <Col sm={3}>
41
+ <Nav variant="pills" className="flex-column">
42
+ {/* {
65
43
  ...bddErrors.givens.map((g) =>
66
44
  <Nav.Item>
67
45
  <Nav.Link eventKey={g.key}>
@@ -70,31 +48,26 @@ const ExternalFeatures = ({ summary }: { summary: ISummaries }) => {
70
48
  </Nav.Item>
71
49
  )
72
50
  } */}
73
-
74
- </Nav>
75
- </Col>
76
- <Col sm={9}>
77
- <Tab.Content>
78
- {/* {
51
+ </Nav>
52
+ </Col>
53
+ <Col sm={9}>
54
+ <Tab.Content>
55
+ {/* {
79
56
  ...bddErrors.givens.map((g) =>
80
57
 
81
58
  <Tab.Pane eventKey={g.key}><TestPane given={g} /></Tab.Pane>
82
59
 
83
60
  )
84
61
  } */}
85
- </Tab.Content>
86
- </Col>
87
- </Row>
88
-
89
- </Tab.Container>
90
- </Tab.Pane>
91
-
92
- </Tab.Content>
93
-
94
-
95
- </Col>
96
-
97
- {/* <Col sm={3}>
62
+ </Tab.Content>
63
+ </Col>
64
+ </Row>
65
+ </Tab.Container>
66
+ </Tab.Pane>
67
+ </Tab.Content>
68
+ </Col>
69
+
70
+ {/* <Col sm={3}>
98
71
 
99
72
 
100
73
 
@@ -126,150 +99,152 @@ const ExternalFeatures = ({ summary }: { summary: ISummaries }) => {
126
99
  }
127
100
  </Tab.Content>
128
101
  </Col> */}
129
-
130
- </Row>
131
- </Tab.Container>
132
- </Row>
133
-
134
- </div>
135
- }
102
+ </Row>
103
+ </Tab.Container>
104
+ </Row>
105
+ </div>
106
+ );
107
+ };
136
108
 
137
109
  const Features = ({ summary }: { summary: ISummaries }) => {
138
- return <div>
139
-
140
- <Table striped bordered hover>
141
- <thead>
142
- <tr>
143
- <th>project</th>
144
- <th>platform</th>
145
- <th>BDD errors</th>
146
- <th>Lint errors</th>
147
- <th>Type errors</th>
148
- <th>prompt</th>
149
- </tr>
150
-
151
- </thead>
152
-
153
- <tbody>
154
- {
155
- ...summary.map((s) => {
156
- return <>
157
- <tr>
158
- <th>{s[0]}</th>
159
- </tr>
160
- {
161
- ...s[1].tests.map((t) => {
162
-
163
- const x = `${s[0]}/${t[0].split(".").slice(0, -1).join(".")}/${t[1]}`
110
+ return (
111
+ <div>
112
+ <Table striped bordered hover>
113
+ <thead>
114
+ <tr>
115
+ <th>project</th>
116
+ <th>platform</th>
117
+ <th>BDD errors</th>
118
+ <th>Lint errors</th>
119
+ <th>Type errors</th>
120
+ <th>prompt</th>
121
+ </tr>
122
+ </thead>
123
+
124
+ <tbody>
125
+ {...summary.map((s) => {
126
+ return (
127
+ <>
128
+ <tr>
129
+ <th>{s[0]}</th>
130
+ </tr>
131
+ {...s[1].tests.map((t) => {
132
+ const x = `${s[0]}/${t[0]
133
+ .split(".")
134
+ .slice(0, -1)
135
+ .join(".")}/${t[1]}`;
164
136
  const y = s[2][t[0]];
165
137
 
166
- return <tr>
167
- <td>{t[0]}</td>
168
- <td>{t[1]}</td>
169
- <td><a href={`./reports/${x}/index.html`}>{y.runTimeError}</a></td>
170
- <td><a href={`./reports/${x}/lint_errors.json`}>{y.staticErrors}</a></td>
171
- <td><a href={`./reports/${x}/type_errors.txt`}>{y.typeErrors}</a></td>
172
- <td>
173
- <pre>
174
-
175
- {s[2][t[0]].prompt}
176
- {/* <button onClick={() => {
138
+ return (
139
+ <tr>
140
+ <td>{t[0]}</td>
141
+ <td>{t[1]}</td>
142
+ <td>
143
+ <a href={`./asdasasdasdd/reports/${x}/index.html`}>
144
+ {y.runTimeError}
145
+ </a>
146
+ </td>
147
+ <td>
148
+ <a
149
+ href={`./testeasdqqweqweranto/reports/${x}/lint_errors.json`}
150
+ >
151
+ {y.staticErrors}
152
+ </a>
153
+ </td>
154
+ <td>
155
+ <a
156
+ href={`./testezxcdcdfranto/reports/${x}/type_errors.txt`}
157
+ >
158
+ {y.typeErrors}
159
+ </a>
160
+ </td>
161
+ <td>
162
+ <pre>
163
+ {s[2][t[0]].prompt}
164
+ {/* <button onClick={() => {
177
165
  copyToClipboard(s[2][t[0]].prompt)
178
166
  }}>prompt</button> */}
179
- </pre>
180
- </td>
181
-
182
-
183
- </tr>
184
- })
185
- }
186
- </>
187
-
188
-
189
- })
190
- }
191
- </tbody>
192
-
193
- </Table>
194
-
195
- </div>
196
- }
167
+ </pre>
168
+ </td>
169
+ </tr>
170
+ );
171
+ })}
172
+ </>
173
+ );
174
+ })}
175
+ </tbody>
176
+ </Table>
177
+ </div>
178
+ );
179
+ };
197
180
 
198
181
  const Docs = ({ summary }: { summary: ISummaries }) => {
199
- return <div>
200
-
201
-
202
- <Tab.Container id="DocsPane-tabs" defaultActiveKey="external">
203
- <Row>
204
- <Col sm={12}>
205
- <Nav >
206
- <Nav.Link eventKey={`external`}>external</Nav.Link>
207
- <Nav.Link eventKey={`markdown`}>markdown</Nav.Link>
208
- <Nav.Link eventKey={`string`}>string</Nav.Link>
209
- </Nav>
210
- </Col>
211
- </Row>
212
- <Row>
213
-
214
-
215
- <Col sm={12}>
216
- <Tab.Content>
217
-
218
- <Tab.Pane eventKey={`external`}>
219
- <ExternalFeatures summary={summary} />
220
- </Tab.Pane>
221
-
222
-
223
- <Tab.Pane eventKey={`markdown`}>
224
- <ExternalFeatures summary={summary} />
225
- </Tab.Pane>
226
-
227
- <Tab.Pane eventKey={`string`}>
228
- <ExternalFeatures summary={summary} />
229
- </Tab.Pane>
182
+ return (
183
+ <div>
184
+ <Tab.Container id="DocsPane-tabs" defaultActiveKey="external">
185
+ <Row>
186
+ <Col sm={12}>
187
+ <Nav>
188
+ <Nav.Link eventKey={`external`}>external</Nav.Link>
189
+ <Nav.Link eventKey={`markdown`}>markdown</Nav.Link>
190
+ <Nav.Link eventKey={`string`}>string</Nav.Link>
191
+ </Nav>
192
+ </Col>
193
+ </Row>
194
+ <Row>
195
+ <Col sm={12}>
196
+ <Tab.Content>
197
+ <Tab.Pane eventKey={`external`}>
198
+ <ExternalFeatures summary={summary} />
199
+ </Tab.Pane>
230
200
 
231
- </Tab.Content>
232
- </Col>
233
- </Row>
234
- </Tab.Container>
201
+ <Tab.Pane eventKey={`markdown`}>
202
+ <ExternalFeatures summary={summary} />
203
+ </Tab.Pane>
235
204
 
236
- </div>
237
- }
205
+ <Tab.Pane eventKey={`string`}>
206
+ <ExternalFeatures summary={summary} />
207
+ </Tab.Pane>
208
+ </Tab.Content>
209
+ </Col>
210
+ </Row>
211
+ </Tab.Container>
212
+ </div>
213
+ );
214
+ };
238
215
 
239
- type ISummaries = [
240
- string,
241
- IBuiltConfig,
242
- ISummary
243
- ][];
216
+ type ISummaries = [string, IBuiltConfig, ISummary][];
244
217
 
245
218
  const BigBoard = () => {
246
-
247
- const bigConfigElement = document.getElementById('bigConfig');
248
- if (!bigConfigElement) throw new Error('bigConfig element not found');
219
+ const bigConfigElement = document.getElementById("bigConfig");
220
+ if (!bigConfigElement) throw new Error("bigConfig element not found");
249
221
  const projects = JSON.parse(bigConfigElement.innerHTML) as string[];
250
222
 
251
223
  const [summary, setSummary] = useState<ISummaries>();
252
224
  useEffect(() => {
253
225
  (async () => {
254
-
255
- const x: Promise<[string, IBuiltConfig, ISummary]>[] = projects.map(async (p) => {
256
- return [
257
- p,
258
- (await (await fetch(`./reports/${p}/config.json`)).json()) as IBuiltConfig,
259
- (await (await fetch(`./reports/${p}/summary.json`)).json()) as ISummary
260
- ] as [string, IBuiltConfig, ISummary]
261
- })
226
+ const x: Promise<[string, IBuiltConfig, ISummary]>[] = projects.map(
227
+ async (p) => {
228
+ return [
229
+ p,
230
+ (await (
231
+ await fetch(`./testeranto/reports/${p}/config.json`)
232
+ ).json()) as IBuiltConfig,
233
+ (await (
234
+ await fetch(`./testeranto/reports/${p}/summary.json`)
235
+ ).json()) as ISummary,
236
+ ] as [string, IBuiltConfig, ISummary];
237
+ }
238
+ );
262
239
 
263
240
  Promise.all(x).then((v) => {
264
- setSummary(v)
265
- })
266
-
241
+ setSummary(v);
242
+ });
267
243
  })();
268
244
  }, []);
269
245
 
270
-
271
246
  if (!summary || summary?.length === 0) {
272
- return <div>loading...</div>
247
+ return <div>loading...</div>;
273
248
  }
274
249
 
275
250
  // console.log("summary", summary)
@@ -288,111 +263,134 @@ const BigBoard = () => {
288
263
  // // });
289
264
 
290
265
  function copyToClipboard(text) {
291
- navigator.clipboard.writeText(text)
266
+ navigator.clipboard
267
+ .writeText(text)
292
268
  .then(() => {
293
- console.log('Text copied to clipboard');
269
+ console.log("Text copied to clipboard");
294
270
  })
295
- .catch(err => {
296
- console.error('Error copying text: ', err);
271
+ .catch((err) => {
272
+ console.error("Error copying text: ", err);
297
273
  });
298
274
  }
299
275
 
300
-
301
- return <div> <Tab.Container id="TestPane-tabs" defaultActiveKey="tests">
302
- <Row>
303
- <Col sm={12}>
304
- <Nav >
305
- <Nav.Link eventKey={`tests`}>tests</Nav.Link>
306
- <Nav.Link eventKey={`features`}>features</Nav.Link>
307
- <Nav.Link eventKey={`docs`}>docs</Nav.Link>
308
- </Nav>
309
- </Col>
310
- </Row>
311
- <Row>
312
-
313
-
314
- <Col sm={12}>
315
- <Tab.Content>
316
-
317
- <Tab.Pane eventKey={`tests`}>
318
- <Table striped bordered hover>
319
- <thead>
320
- <tr>
321
- <th>project</th>
322
- <th>platform</th>
323
- <th>BDD errors</th>
324
- <th>Lint errors</th>
325
- <th>Type errors</th>
326
- <th>prompt</th>
327
- <th>failing features</th>
328
- </tr>
329
-
330
- </thead>
331
-
332
- <tbody>
333
- {
334
- ...summary.map((s) => {
335
- return <>
336
- <tr>
337
- <th>{s[0]}</th>
338
- </tr>
339
- {
340
- ...s[1].tests.map((t) => {
341
-
342
- const x = `${s[0]}/${t[0].split(".").slice(0, -1).join(".")}/${t[1]}`
343
- const y = s[2][t[0]];
344
-
345
- return <tr>
346
- <td>{t[0]}</td>
347
- <td>{t[1]}</td>
348
- <td><a href={`./reports/${x}/index.html`}>{y.runTimeError}</a></td>
349
- <td><a href={`./reports/${x}/lint_errors.json`}>{y.staticErrors}</a></td>
350
- <td><a href={`./reports/${x}/type_errors.txt`}>{y.typeErrors}</a></td>
351
- <td>
352
- <pre>
353
-
354
- {/* {s[2][t[0]].prompt} */}
355
- <button onClick={() => {
356
- copyToClipboard(s[2][t[0]].prompt)
357
- }}>copy</button>
358
- </pre>
359
- </td>
360
- <td>
361
- {/* <a href={`./reports/${x}/type_errors.txt`}>{y.typeErrors}</a> */}
362
- <pre><code>{JSON.stringify(y.failingFeatures, null, 2)}</code></pre>
363
- </td>
364
-
276
+ return (
277
+ <div>
278
+ {" "}
279
+ <Tab.Container id="TestPane-tabs" defaultActiveKey="tests">
280
+ <Row>
281
+ <Col sm={12}>
282
+ <Nav>
283
+ <Nav.Link eventKey={`tests`}>tests</Nav.Link>
284
+ <Nav.Link eventKey={`features`}>features</Nav.Link>
285
+ <Nav.Link eventKey={`docs`}>docs</Nav.Link>
286
+ </Nav>
287
+ </Col>
288
+ </Row>
289
+ <Row>
290
+ <Col sm={12}>
291
+ <Tab.Content>
292
+ <Tab.Pane eventKey={`tests`}>
293
+ <Table striped bordered hover>
294
+ <thead>
295
+ <tr>
296
+ <th>project</th>
297
+ <th>platform</th>
298
+ <th>BDD errors</th>
299
+ <th>Lint errors</th>
300
+ <th>Type errors</th>
301
+ <th>prompt</th>
302
+ <th>failing features</th>
303
+ </tr>
304
+ </thead>
305
+
306
+ <tbody>
307
+ {...summary.map((s) => {
308
+ return (
309
+ <>
310
+ <tr>
311
+ <th>{s[0]}</th>
365
312
  </tr>
366
- })
367
- }
368
- </>
369
-
370
-
371
- })
372
- }
373
- </tbody>
374
-
375
- </Table>
376
- </Tab.Pane>
377
-
378
-
379
- <Tab.Pane eventKey={`features`}>
380
- <Features summary={summary} />
381
- </Tab.Pane>
382
-
383
- <Tab.Pane eventKey={`docs`}>
384
- <Docs summary={summary} />
385
- </Tab.Pane>
386
-
387
- </Tab.Content>
388
- </Col>
389
- </Row>
390
- </Tab.Container>
313
+ {...s[1].tests.map((t) => {
314
+ const x = `${s[0]}/${t[0]
315
+ .split(".")
316
+ .slice(0, -1)
317
+ .join(".")}/${t[1]}`;
318
+ const y = s[2][t[0]];
319
+
320
+ return (
321
+ <tr>
322
+ <td>{t[0]}</td>
323
+ <td>{t[1]}</td>
324
+ <td>
325
+ <a
326
+ href={`./testeranto/reports/${x}/index.html`}
327
+ >
328
+ {y.runTimeError}
329
+ </a>
330
+ </td>
331
+ <td>
332
+ <a
333
+ href={`./testeranto/reports/${x}/lint_errors.json`}
334
+ >
335
+ {y.staticErrors}
336
+ </a>
337
+ </td>
338
+ <td>
339
+ <a
340
+ href={`./testeranto/reports/${x}/type_errors.txt`}
341
+ >
342
+ {y.typeErrors}
343
+ </a>
344
+ </td>
345
+ <td>
346
+ <pre>
347
+ {/* {s[2][t[0]].prompt} */}
348
+ <button
349
+ onClick={() => {
350
+ copyToClipboard(s[2][t[0]].prompt);
351
+ }}
352
+ >
353
+ copy
354
+ </button>
355
+ </pre>
356
+ </td>
357
+ <td>
358
+ {/* <a href={`./reports/${x}/type_errors.txt`}>{y.typeErrors}</a> */}
359
+ <pre>
360
+ <code>
361
+ {JSON.stringify(
362
+ y.failingFeatures,
363
+ null,
364
+ 2
365
+ )}
366
+ </code>
367
+ </pre>
368
+ </td>
369
+ </tr>
370
+ );
371
+ })}
372
+ </>
373
+ );
374
+ })}
375
+ </tbody>
376
+ </Table>
377
+ </Tab.Pane>
391
378
 
392
- <Footer />
393
- </div>
379
+ <Tab.Pane eventKey={`features`}>
380
+ <Features summary={summary} />
381
+ </Tab.Pane>
394
382
 
395
- }
383
+ <Tab.Pane eventKey={`docs`}>
384
+ <Docs summary={summary} />
385
+ </Tab.Pane>
386
+ </Tab.Content>
387
+ </Col>
388
+ </Row>
389
+ </Tab.Container>
390
+ <Footer />
391
+ </div>
392
+ );
393
+ };
396
394
 
397
395
  document.addEventListener("DOMContentLoaded", function () {
398
396
  const elem = document.getElementById("root");
@@ -400,4 +398,3 @@ document.addEventListener("DOMContentLoaded", function () {
400
398
  ReactDom.createRoot(elem).render(React.createElement(BigBoard, {}));
401
399
  }
402
400
  });
403
-