@thinkwise/testwise 0.2.67 → 0.2.99

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 (434) hide show
  1. package/Testwise.ts +35 -0
  2. package/artifact-builder/ArtifactManager.ts +25 -2
  3. package/artifact-builder/ComponentClassModelBuilder.ts +148 -0
  4. package/artifact-builder/InterfaceGenerator.ts +31 -33
  5. package/artifact-builder/ModelDataBuilder.ts +18 -20
  6. package/artifact-builder/ModelDataRefiner.ts +23 -3
  7. package/artifact-builder/SchemaGenerator.ts +45 -35
  8. package/artifact-builder/ScreenInterfaceRefiner.ts +25 -10
  9. package/artifact-builder/SelectorBuilder.ts +30 -24
  10. package/artifact-builder/SubjectClassModelBuilder.ts +209 -0
  11. package/artifact-builder/SubjectComponentGenerator.ts +67 -246
  12. package/artifact-builder/SubjectGenerator.ts +117 -230
  13. package/artifact-builder/SubjectRegistration.ts +41 -32
  14. package/artifact-builder/TsFileModel.ts +94 -0
  15. package/artifact-builder/TsFileSerializer.ts +247 -0
  16. package/artifact-builder/helpers/DataRetriever.ts +64 -27
  17. package/artifact-builder/helpers/NamingHandler.ts +23 -78
  18. package/artifact-builder/helpers/PipelinePaths.ts +123 -0
  19. package/artifact-builder/helpers/Stopwatch.ts +10 -0
  20. package/artifact-builder/helpers/index.ts +1 -0
  21. package/artifact-builder/index.ts +4 -0
  22. package/components/BaseComponentObjects.ts +17 -0
  23. package/components/action-bar/ActionBar.ts +35 -47
  24. package/components/action-bar/ActionBarObjects.ts +2 -0
  25. package/components/action-bar/CustomActionBar.ts +6 -0
  26. package/components/cardlist/Cardlist.ts +6 -0
  27. package/components/chart/Chart.ts +6 -0
  28. package/components/combined-filter/CombinedFilter.ts +9 -0
  29. package/components/cube-view-bar/CubeViewBar.ts +6 -0
  30. package/components/export/ExportComponent.ts +12 -0
  31. package/components/filter/ExcelStyleFilterPopup.ts +35 -2
  32. package/components/filter/FilterForm.ts +10 -0
  33. package/components/filter/FilterPopup.ts +30 -9
  34. package/components/filter/FilterPopupObjects.ts +10 -3
  35. package/components/filter/FindForm.ts +7 -0
  36. package/components/filter/ManagePrefilterPopup.ts +11 -0
  37. package/components/form/Form.ts +16 -0
  38. package/components/grid/Grid.ts +18 -1
  39. package/components/maps/Maps.ts +6 -0
  40. package/components/menu/ListBarMenuComponent.ts +10 -0
  41. package/components/pivot-grid/PivotGrid.ts +6 -0
  42. package/components/pivot-grid/PivotGridFieldList.ts +7 -0
  43. package/components/pop-up/AllRowsPopUp.ts +12 -0
  44. package/components/pop-up/PopUpComponent.ts +11 -0
  45. package/components/prefilter-list/PrefilterList.ts +9 -0
  46. package/components/preview/Preview.ts +6 -0
  47. package/components/report-bar/ReportBar.ts +6 -0
  48. package/components/report-tiles/ReportTiles.ts +6 -0
  49. package/components/scheduler/Scheduler.ts +6 -0
  50. package/components/snackbar/SnackBar.ts +12 -0
  51. package/components/splitter/Splitter.ts +6 -0
  52. package/components/tab/BaseTab.ts +5 -0
  53. package/components/tab/DetailTabPage.ts +11 -0
  54. package/components/tab/Tab.ts +10 -0
  55. package/components/task/TaskBar.ts +13 -3
  56. package/components/task/TaskTiles.ts +12 -3
  57. package/components/topbar/TopBar.ts +10 -0
  58. package/components/tree-view/TreeView.ts +9 -0
  59. package/controls/DateControl.ts +40 -1
  60. package/controls/FormComboBox.ts +30 -0
  61. package/controls/GridColumnControl.ts +34 -3
  62. package/controls/InputFieldControl.ts +49 -0
  63. package/controls/LookupDropdown.ts +29 -0
  64. package/dist/Testwise.js +35 -0
  65. package/dist/Testwise.js.map +1 -1
  66. package/dist/artifact-builder/ArtifactManager.d.ts +18 -1
  67. package/dist/artifact-builder/ArtifactManager.js +24 -2
  68. package/dist/artifact-builder/ArtifactManager.js.map +1 -1
  69. package/dist/artifact-builder/ComponentClassModelBuilder.d.ts +22 -0
  70. package/dist/artifact-builder/ComponentClassModelBuilder.js +115 -0
  71. package/dist/artifact-builder/ComponentClassModelBuilder.js.map +1 -0
  72. package/dist/artifact-builder/InterfaceGenerator.d.ts +15 -6
  73. package/dist/artifact-builder/InterfaceGenerator.js +27 -26
  74. package/dist/artifact-builder/InterfaceGenerator.js.map +1 -1
  75. package/dist/artifact-builder/ModelDataBuilder.d.ts +7 -0
  76. package/dist/artifact-builder/ModelDataBuilder.js +13 -5
  77. package/dist/artifact-builder/ModelDataBuilder.js.map +1 -1
  78. package/dist/artifact-builder/ModelDataRefiner.d.ts +18 -1
  79. package/dist/artifact-builder/ModelDataRefiner.js +18 -3
  80. package/dist/artifact-builder/ModelDataRefiner.js.map +1 -1
  81. package/dist/artifact-builder/SchemaGenerator.d.ts +21 -5
  82. package/dist/artifact-builder/SchemaGenerator.js +38 -26
  83. package/dist/artifact-builder/SchemaGenerator.js.map +1 -1
  84. package/dist/artifact-builder/ScreenInterfaceRefiner.d.ts +18 -1
  85. package/dist/artifact-builder/ScreenInterfaceRefiner.js +23 -9
  86. package/dist/artifact-builder/ScreenInterfaceRefiner.js.map +1 -1
  87. package/dist/artifact-builder/SelectorBuilder.d.ts +18 -5
  88. package/dist/artifact-builder/SelectorBuilder.js +29 -14
  89. package/dist/artifact-builder/SelectorBuilder.js.map +1 -1
  90. package/dist/artifact-builder/SubjectClassModelBuilder.d.ts +38 -0
  91. package/dist/artifact-builder/SubjectClassModelBuilder.js +158 -0
  92. package/dist/artifact-builder/SubjectClassModelBuilder.js.map +1 -0
  93. package/dist/artifact-builder/SubjectComponentGenerator.d.ts +25 -14
  94. package/dist/artifact-builder/SubjectComponentGenerator.js +65 -189
  95. package/dist/artifact-builder/SubjectComponentGenerator.js.map +1 -1
  96. package/dist/artifact-builder/SubjectGenerator.d.ts +32 -13
  97. package/dist/artifact-builder/SubjectGenerator.js +81 -165
  98. package/dist/artifact-builder/SubjectGenerator.js.map +1 -1
  99. package/dist/artifact-builder/SubjectRegistration.d.ts +22 -8
  100. package/dist/artifact-builder/SubjectRegistration.js +29 -14
  101. package/dist/artifact-builder/SubjectRegistration.js.map +1 -1
  102. package/dist/artifact-builder/TsFileModel.d.ts +86 -0
  103. package/dist/artifact-builder/TsFileModel.js +2 -0
  104. package/dist/artifact-builder/TsFileModel.js.map +1 -0
  105. package/dist/artifact-builder/TsFileSerializer.d.ts +19 -0
  106. package/dist/artifact-builder/TsFileSerializer.js +225 -0
  107. package/dist/artifact-builder/TsFileSerializer.js.map +1 -0
  108. package/dist/artifact-builder/helpers/DataRetriever.d.ts +22 -3
  109. package/dist/artifact-builder/helpers/DataRetriever.js +56 -26
  110. package/dist/artifact-builder/helpers/DataRetriever.js.map +1 -1
  111. package/dist/artifact-builder/helpers/NamingHandler.d.ts +18 -6
  112. package/dist/artifact-builder/helpers/NamingHandler.js +20 -61
  113. package/dist/artifact-builder/helpers/NamingHandler.js.map +1 -1
  114. package/dist/artifact-builder/helpers/PipelinePaths.d.ts +52 -0
  115. package/dist/artifact-builder/helpers/PipelinePaths.js +99 -0
  116. package/dist/artifact-builder/helpers/PipelinePaths.js.map +1 -0
  117. package/dist/artifact-builder/helpers/Stopwatch.d.ts +10 -0
  118. package/dist/artifact-builder/helpers/Stopwatch.js +10 -0
  119. package/dist/artifact-builder/helpers/Stopwatch.js.map +1 -1
  120. package/dist/artifact-builder/helpers/index.d.ts +1 -0
  121. package/dist/artifact-builder/helpers/index.js +1 -0
  122. package/dist/artifact-builder/helpers/index.js.map +1 -1
  123. package/dist/artifact-builder/index.d.ts +4 -0
  124. package/dist/artifact-builder/index.js +4 -0
  125. package/dist/artifact-builder/index.js.map +1 -1
  126. package/dist/components/BaseComponentObjects.d.ts +17 -0
  127. package/dist/components/BaseComponentObjects.js +17 -0
  128. package/dist/components/BaseComponentObjects.js.map +1 -1
  129. package/dist/components/action-bar/ActionBar.d.ts +21 -24
  130. package/dist/components/action-bar/ActionBar.js +31 -24
  131. package/dist/components/action-bar/ActionBar.js.map +1 -1
  132. package/dist/components/action-bar/ActionBarObjects.d.ts +1 -0
  133. package/dist/components/action-bar/ActionBarObjects.js +1 -0
  134. package/dist/components/action-bar/ActionBarObjects.js.map +1 -1
  135. package/dist/components/action-bar/CustomActionBar.d.ts +6 -0
  136. package/dist/components/action-bar/CustomActionBar.js +6 -0
  137. package/dist/components/action-bar/CustomActionBar.js.map +1 -1
  138. package/dist/components/cardlist/Cardlist.d.ts +6 -0
  139. package/dist/components/cardlist/Cardlist.js +6 -0
  140. package/dist/components/cardlist/Cardlist.js.map +1 -1
  141. package/dist/components/chart/Chart.d.ts +6 -0
  142. package/dist/components/chart/Chart.js +6 -0
  143. package/dist/components/chart/Chart.js.map +1 -1
  144. package/dist/components/combined-filter/CombinedFilter.d.ts +9 -0
  145. package/dist/components/combined-filter/CombinedFilter.js +9 -0
  146. package/dist/components/combined-filter/CombinedFilter.js.map +1 -1
  147. package/dist/components/cube-view-bar/CubeViewBar.d.ts +6 -0
  148. package/dist/components/cube-view-bar/CubeViewBar.js +6 -0
  149. package/dist/components/cube-view-bar/CubeViewBar.js.map +1 -1
  150. package/dist/components/export/ExportComponent.d.ts +12 -0
  151. package/dist/components/export/ExportComponent.js +12 -0
  152. package/dist/components/export/ExportComponent.js.map +1 -1
  153. package/dist/components/filter/ExcelStyleFilterPopup.d.ts +17 -4
  154. package/dist/components/filter/ExcelStyleFilterPopup.js +35 -23
  155. package/dist/components/filter/ExcelStyleFilterPopup.js.map +1 -1
  156. package/dist/components/filter/ExcelStyleFilterPopupObjects.d.ts +1 -1
  157. package/dist/components/filter/ExcelStyleFilterPopupObjects.js +2 -2
  158. package/dist/components/filter/ExcelStyleFilterPopupObjects.js.map +1 -1
  159. package/dist/components/filter/FilterForm.d.ts +10 -0
  160. package/dist/components/filter/FilterForm.js +10 -0
  161. package/dist/components/filter/FilterForm.js.map +1 -1
  162. package/dist/components/filter/FilterPopup.d.ts +22 -4
  163. package/dist/components/filter/FilterPopup.js +17 -9
  164. package/dist/components/filter/FilterPopup.js.map +1 -1
  165. package/dist/components/filter/FilterPopupObjects.d.ts +5 -2
  166. package/dist/components/filter/FilterPopupObjects.js +5 -2
  167. package/dist/components/filter/FilterPopupObjects.js.map +1 -1
  168. package/dist/components/filter/FindForm.d.ts +7 -0
  169. package/dist/components/filter/FindForm.js +7 -0
  170. package/dist/components/filter/FindForm.js.map +1 -1
  171. package/dist/components/filter/ManagePrefilterPopup.d.ts +11 -0
  172. package/dist/components/filter/ManagePrefilterPopup.js +11 -0
  173. package/dist/components/filter/ManagePrefilterPopup.js.map +1 -1
  174. package/dist/components/form/Form.d.ts +16 -0
  175. package/dist/components/form/Form.js +16 -0
  176. package/dist/components/form/Form.js.map +1 -1
  177. package/dist/components/grid/Grid.d.ts +17 -0
  178. package/dist/components/grid/Grid.js +18 -1
  179. package/dist/components/grid/Grid.js.map +1 -1
  180. package/dist/components/maps/Maps.d.ts +6 -0
  181. package/dist/components/maps/Maps.js +6 -0
  182. package/dist/components/maps/Maps.js.map +1 -1
  183. package/dist/components/menu/ListBarMenuComponent.d.ts +10 -0
  184. package/dist/components/menu/ListBarMenuComponent.js +10 -0
  185. package/dist/components/menu/ListBarMenuComponent.js.map +1 -1
  186. package/dist/components/pivot-grid/PivotGrid.d.ts +6 -0
  187. package/dist/components/pivot-grid/PivotGrid.js +6 -0
  188. package/dist/components/pivot-grid/PivotGrid.js.map +1 -1
  189. package/dist/components/pivot-grid/PivotGridFieldList.d.ts +7 -0
  190. package/dist/components/pivot-grid/PivotGridFieldList.js +7 -0
  191. package/dist/components/pivot-grid/PivotGridFieldList.js.map +1 -1
  192. package/dist/components/pop-up/AllRowsPopUp.d.ts +12 -0
  193. package/dist/components/pop-up/AllRowsPopUp.js +12 -0
  194. package/dist/components/pop-up/AllRowsPopUp.js.map +1 -1
  195. package/dist/components/pop-up/PopUpComponent.d.ts +11 -0
  196. package/dist/components/pop-up/PopUpComponent.js +11 -0
  197. package/dist/components/pop-up/PopUpComponent.js.map +1 -1
  198. package/dist/components/prefilter-list/PrefilterList.d.ts +9 -0
  199. package/dist/components/prefilter-list/PrefilterList.js +9 -0
  200. package/dist/components/prefilter-list/PrefilterList.js.map +1 -1
  201. package/dist/components/preview/Preview.d.ts +6 -0
  202. package/dist/components/preview/Preview.js +6 -0
  203. package/dist/components/preview/Preview.js.map +1 -1
  204. package/dist/components/report-bar/ReportBar.d.ts +6 -0
  205. package/dist/components/report-bar/ReportBar.js +6 -0
  206. package/dist/components/report-bar/ReportBar.js.map +1 -1
  207. package/dist/components/report-tiles/ReportTiles.d.ts +6 -0
  208. package/dist/components/report-tiles/ReportTiles.js +6 -0
  209. package/dist/components/report-tiles/ReportTiles.js.map +1 -1
  210. package/dist/components/scheduler/Scheduler.d.ts +6 -0
  211. package/dist/components/scheduler/Scheduler.js +6 -0
  212. package/dist/components/scheduler/Scheduler.js.map +1 -1
  213. package/dist/components/snackbar/SnackBar.d.ts +12 -0
  214. package/dist/components/snackbar/SnackBar.js +12 -0
  215. package/dist/components/snackbar/SnackBar.js.map +1 -1
  216. package/dist/components/splitter/Splitter.d.ts +6 -0
  217. package/dist/components/splitter/Splitter.js +6 -0
  218. package/dist/components/splitter/Splitter.js.map +1 -1
  219. package/dist/components/tab/BaseTab.d.ts +5 -0
  220. package/dist/components/tab/BaseTab.js +5 -0
  221. package/dist/components/tab/BaseTab.js.map +1 -1
  222. package/dist/components/tab/DetailTabPage.d.ts +11 -0
  223. package/dist/components/tab/DetailTabPage.js +11 -0
  224. package/dist/components/tab/DetailTabPage.js.map +1 -1
  225. package/dist/components/tab/Tab.d.ts +10 -0
  226. package/dist/components/tab/Tab.js +10 -0
  227. package/dist/components/tab/Tab.js.map +1 -1
  228. package/dist/components/task/TaskBar.d.ts +12 -2
  229. package/dist/components/task/TaskBar.js +13 -3
  230. package/dist/components/task/TaskBar.js.map +1 -1
  231. package/dist/components/task/TaskTiles.d.ts +11 -2
  232. package/dist/components/task/TaskTiles.js +12 -3
  233. package/dist/components/task/TaskTiles.js.map +1 -1
  234. package/dist/components/topbar/TopBar.d.ts +10 -0
  235. package/dist/components/topbar/TopBar.js +10 -0
  236. package/dist/components/topbar/TopBar.js.map +1 -1
  237. package/dist/components/tree-view/TreeView.d.ts +9 -0
  238. package/dist/components/tree-view/TreeView.js +9 -0
  239. package/dist/components/tree-view/TreeView.js.map +1 -1
  240. package/dist/controls/DateControl.d.ts +39 -0
  241. package/dist/controls/DateControl.js +18 -1
  242. package/dist/controls/DateControl.js.map +1 -1
  243. package/dist/controls/FormComboBox.d.ts +30 -0
  244. package/dist/controls/FormComboBox.js +8 -0
  245. package/dist/controls/FormComboBox.js.map +1 -1
  246. package/dist/controls/GridColumnControl.d.ts +30 -0
  247. package/dist/controls/GridColumnControl.js +12 -3
  248. package/dist/controls/GridColumnControl.js.map +1 -1
  249. package/dist/controls/InputFieldControl.d.ts +49 -0
  250. package/dist/controls/InputFieldControl.js +30 -0
  251. package/dist/controls/InputFieldControl.js.map +1 -1
  252. package/dist/controls/LookupDropdown.d.ts +29 -0
  253. package/dist/controls/LookupDropdown.js +8 -0
  254. package/dist/controls/LookupDropdown.js.map +1 -1
  255. package/dist/enums/ElementTypes.d.ts +18 -0
  256. package/dist/enums/ElementTypes.js +18 -0
  257. package/dist/enums/ElementTypes.js.map +1 -1
  258. package/dist/enums/ExportFormat.d.ts +8 -0
  259. package/dist/enums/ExportFormat.js +8 -0
  260. package/dist/enums/ExportFormat.js.map +1 -1
  261. package/dist/enums/LogLevel.d.ts +17 -0
  262. package/dist/enums/LogLevel.js +17 -1
  263. package/dist/enums/LogLevel.js.map +1 -1
  264. package/dist/enums/index.d.ts +1 -0
  265. package/dist/enums/index.js +1 -0
  266. package/dist/enums/index.js.map +1 -1
  267. package/dist/helpers/ConfigChecker.d.ts +13 -0
  268. package/dist/helpers/ConfigChecker.js +13 -0
  269. package/dist/helpers/ConfigChecker.js.map +1 -1
  270. package/dist/helpers/Ensure.d.ts +13 -0
  271. package/dist/helpers/Ensure.js +13 -0
  272. package/dist/helpers/Ensure.js.map +1 -1
  273. package/dist/helpers/FlightTracker.d.ts +13 -3
  274. package/dist/helpers/FlightTracker.js +103 -17
  275. package/dist/helpers/FlightTracker.js.map +1 -1
  276. package/dist/helpers/GlobalWaitEventHandler.d.ts +13 -0
  277. package/dist/helpers/GlobalWaitEventHandler.js +13 -0
  278. package/dist/helpers/GlobalWaitEventHandler.js.map +1 -1
  279. package/dist/helpers/LoginHelper.d.ts +35 -1
  280. package/dist/helpers/LoginHelper.js +46 -11
  281. package/dist/helpers/LoginHelper.js.map +1 -1
  282. package/dist/helpers/PathResolver.d.ts +22 -0
  283. package/dist/helpers/PathResolver.js +22 -0
  284. package/dist/helpers/PathResolver.js.map +1 -1
  285. package/dist/helpers/Poll.d.ts +13 -1
  286. package/dist/helpers/Poll.js +12 -0
  287. package/dist/helpers/Poll.js.map +1 -1
  288. package/dist/helpers/RegexHelper.d.ts +15 -0
  289. package/dist/helpers/RegexHelper.js +15 -3
  290. package/dist/helpers/RegexHelper.js.map +1 -1
  291. package/dist/helpers/SubjectNavigator.d.ts +26 -0
  292. package/dist/helpers/SubjectNavigator.js +51 -0
  293. package/dist/helpers/SubjectNavigator.js.map +1 -0
  294. package/dist/helpers/UserSimulationHelper.d.ts +14 -0
  295. package/dist/helpers/UserSimulationHelper.js +14 -0
  296. package/dist/helpers/UserSimulationHelper.js.map +1 -1
  297. package/dist/helpers/index.d.ts +1 -0
  298. package/dist/helpers/index.js +1 -0
  299. package/dist/helpers/index.js.map +1 -1
  300. package/dist/index.d.ts +6 -20
  301. package/dist/index.js +1 -0
  302. package/dist/index.js.map +1 -1
  303. package/dist/interfaces/IComponentObjects.d.ts +12 -0
  304. package/dist/interfaces/IComponentSchemaMeta.d.ts +15 -0
  305. package/dist/interfaces/IComponentSchemaMeta.js +2 -0
  306. package/dist/interfaces/IComponentSchemaMeta.js.map +1 -0
  307. package/dist/interfaces/IProperty.d.ts +13 -0
  308. package/dist/interfaces/IRegisteredSubjects.d.ts +12 -0
  309. package/dist/interfaces/ISeedSubjectDraft.d.ts +16 -0
  310. package/dist/interfaces/ISeedSubjectDraft.js +2 -0
  311. package/dist/interfaces/ISeedSubjectDraft.js.map +1 -0
  312. package/dist/interfaces/ISubject.d.ts +13 -0
  313. package/dist/interfaces/ISubjectDetail.d.ts +11 -0
  314. package/dist/interfaces/ISubjectDetail.js +2 -0
  315. package/dist/interfaces/ISubjectDetail.js.map +1 -0
  316. package/dist/mcp/ArtifactResolver.d.ts +152 -0
  317. package/dist/mcp/ArtifactResolver.js +232 -0
  318. package/dist/mcp/ArtifactResolver.js.map +1 -0
  319. package/dist/mcp/index.d.ts +2 -0
  320. package/dist/mcp/index.js +2 -0
  321. package/dist/mcp/index.js.map +1 -0
  322. package/dist/page-extensions/GlobalComponents.d.ts +30 -0
  323. package/dist/page-extensions/GlobalComponents.js +30 -0
  324. package/dist/page-extensions/GlobalComponents.js.map +1 -1
  325. package/dist/page-extensions/GoToDeepLink.d.ts +9 -0
  326. package/dist/page-extensions/GoToDeepLink.js +9 -0
  327. package/dist/page-extensions/GoToDeepLink.js.map +1 -1
  328. package/dist/page-extensions/LoginFeatures.d.ts +8 -0
  329. package/dist/page-extensions/LoginFeatures.js +8 -0
  330. package/dist/page-extensions/LoginFeatures.js.map +1 -1
  331. package/dist/page-extensions/SubjectRegistry.d.ts +31 -0
  332. package/dist/page-extensions/SubjectRegistry.js +31 -0
  333. package/dist/page-extensions/SubjectRegistry.js.map +1 -1
  334. package/dist/page-extensions/UserSimulation.d.ts +21 -0
  335. package/dist/page-extensions/UserSimulation.js +21 -0
  336. package/dist/page-extensions/UserSimulation.js.map +1 -1
  337. package/dist/page-extensions/WaitEventHandler.d.ts +20 -0
  338. package/dist/page-extensions/WaitEventHandler.js +20 -0
  339. package/dist/page-extensions/WaitEventHandler.js.map +1 -1
  340. package/dist/page-overrides/ClickOverride.d.ts +23 -2
  341. package/dist/page-overrides/ClickOverride.js +34 -50
  342. package/dist/page-overrides/ClickOverride.js.map +1 -1
  343. package/dist/page-overrides/FillOverride.d.ts +23 -0
  344. package/dist/page-overrides/FillOverride.js +46 -66
  345. package/dist/page-overrides/FillOverride.js.map +1 -1
  346. package/dist/services/ConfigBuilder.d.ts +24 -0
  347. package/dist/services/ConfigBuilder.js +24 -0
  348. package/dist/services/ConfigBuilder.js.map +1 -1
  349. package/dist/services/IndiciumApi.service.d.ts +26 -0
  350. package/dist/services/IndiciumApi.service.js +40 -5
  351. package/dist/services/IndiciumApi.service.js.map +1 -1
  352. package/dist/services/Logger.d.ts +13 -0
  353. package/dist/services/Logger.js +39 -0
  354. package/dist/services/Logger.js.map +1 -1
  355. package/dist/types/Components.d.ts +18 -1
  356. package/dist/types/Components.js +0 -1
  357. package/dist/types/Components.js.map +1 -1
  358. package/dist/types/LocatorType.d.ts +5 -0
  359. package/dist/types/LocatorType.js +2 -0
  360. package/dist/types/LocatorType.js.map +1 -0
  361. package/dist/types/PollTypes.d.ts +8 -0
  362. package/dist/types/Test.d.ts +18 -0
  363. package/dist/types/Universal.d.ts +12 -0
  364. package/dist/types/index.d.ts +2 -0
  365. package/dist/types/index.js +2 -0
  366. package/dist/types/index.js.map +1 -1
  367. package/enums/ElementTypes.ts +18 -0
  368. package/enums/ExportFormat.ts +8 -0
  369. package/enums/LogLevel.ts +17 -1
  370. package/enums/index.ts +1 -0
  371. package/helpers/ConfigChecker.ts +13 -0
  372. package/helpers/Ensure.ts +13 -0
  373. package/helpers/FlightTracker.ts +109 -20
  374. package/helpers/GlobalWaitEventHandler.ts +13 -0
  375. package/helpers/LoginHelper.ts +49 -12
  376. package/helpers/PathResolver.ts +22 -0
  377. package/helpers/Poll.ts +13 -1
  378. package/helpers/RegexHelper.ts +15 -3
  379. package/helpers/SubjectNavigator.ts +57 -0
  380. package/helpers/UserSimulationHelper.ts +14 -0
  381. package/helpers/index.ts +1 -0
  382. package/index.ts +1 -0
  383. package/interfaces/IComponentObjects.ts +12 -0
  384. package/interfaces/IComponentSchemaMeta.ts +17 -0
  385. package/interfaces/IProperty.ts +13 -0
  386. package/interfaces/IRegisteredSubjects.ts +12 -0
  387. package/interfaces/ISeedSubjectDraft.ts +17 -0
  388. package/interfaces/ISubject.ts +13 -0
  389. package/interfaces/ISubjectDetail.ts +12 -0
  390. package/mcp/ArtifactResolver.ts +296 -0
  391. package/mcp/index.ts +2 -0
  392. package/package.json +20 -8
  393. package/page-extensions/GlobalComponents.ts +30 -0
  394. package/page-extensions/GoToDeepLink.ts +9 -0
  395. package/page-extensions/LoginFeatures.ts +8 -0
  396. package/page-extensions/SubjectRegistry.ts +32 -0
  397. package/page-extensions/UserSimulation.ts +21 -0
  398. package/page-extensions/WaitEventHandler.ts +20 -0
  399. package/page-overrides/ClickOverride.ts +36 -55
  400. package/page-overrides/FillOverride.ts +59 -73
  401. package/promptCredentials.js +1 -1
  402. package/scripts/Testwise.template.json +1 -1
  403. package/scripts/diagram.js +2267 -0
  404. package/scripts/main.js +84 -63
  405. package/scripts/postinstall.js +55 -42
  406. package/scripts/setup.js +91 -37
  407. package/scripts/sync.js +767 -748
  408. package/services/ConfigBuilder.ts +24 -0
  409. package/services/IndiciumApi.service.ts +44 -6
  410. package/services/Logger.ts +40 -0
  411. package/templates/copilot-instructions.md +130 -0
  412. package/templates/mcp.json +9 -0
  413. package/templates/testwise-test-expert.agent.md +453 -0
  414. package/tests/tsconfig.json +12 -0
  415. package/tsconfig.json +6 -2
  416. package/types/Components.ts +17 -2
  417. package/types/LocatorType.ts +5 -0
  418. package/types/PollTypes.ts +8 -0
  419. package/types/Test.ts +18 -0
  420. package/types/Universal.ts +12 -0
  421. package/types/index.ts +2 -0
  422. package/dist/interfaces/IStoredTestResults.d.ts +0 -5
  423. package/dist/interfaces/IStoredTestResults.js +0 -2
  424. package/dist/interfaces/IStoredTestResults.js.map +0 -1
  425. package/dist/templates/test-artifacts/SubjectPageBase.d.ts +0 -5
  426. package/dist/templates/test-artifacts/SubjectPageBase.js +0 -6
  427. package/dist/templates/test-artifacts/SubjectPageBase.js.map +0 -1
  428. package/dist/templates/test-artifacts/screens/index.d.ts +0 -1
  429. package/dist/templates/test-artifacts/screens/index.js +0 -2
  430. package/dist/templates/test-artifacts/screens/index.js.map +0 -1
  431. package/dist/templates/test-artifacts/subjects/index.d.ts +0 -1
  432. package/dist/templates/test-artifacts/subjects/index.js +0 -2
  433. package/dist/templates/test-artifacts/subjects/index.js.map +0 -1
  434. package/interfaces/IStoredTestResults.ts +0 -6
@@ -5,10 +5,22 @@ import { testwiseConfig } from '../services/ConfigBuilder.js';
5
5
  import { pollUntil } from './Poll.js';
6
6
  const dirname = path.dirname(fileURLToPath(import.meta.url));
7
7
  const configFixture = JSON.parse(fs.readFileSync(path.resolve(dirname, '../../config.json'), 'utf-8'));
8
+ /**
9
+ * Handles authentication against the Thinkwise Indicium API and the
10
+ * web application login screen.
11
+ *
12
+ * Exposed on the page fixture via `LoginFeatures` as `page.logIn()`,
13
+ * `page.logInWithCredentials()`, `page.logInWithOptions()`, and `page.logOut()`.
14
+ * You do not instantiate `LoginHelper` directly in tests.
15
+ *
16
+ * Credentials are read from `Testwise.json` (`environmentSettings.username`
17
+ * and `environmentSettings.password`) by default, and can be overridden
18
+ * per-call via `logInWithCredentials()` or `logInWithOptions()`.
19
+ */
8
20
  export class LoginHelper {
9
21
  constructor(page) {
10
- this.serviceUrl = String(testwiseConfig().get('environmentSettings.serviceUrl'));
11
- this.metaEndpoint = String(testwiseConfig().get('environmentSettings.metaEndpoint'));
22
+ this.serviceUrl = String(testwiseConfig().get('environmentSettings.serviceUrl')).replace(/\/+$/, '');
23
+ this.metaEndpoint = String(testwiseConfig().get('environmentSettings.metaEndpoint')).replace(/\/+$/, '');
12
24
  if (!this.serviceUrl || this.serviceUrl === 'undefined')
13
25
  throw new Error('Service URL not found');
14
26
  if (!this.metaEndpoint || this.metaEndpoint === 'undefined')
@@ -46,18 +58,19 @@ export class LoginHelper {
46
58
  await this.logInAndConfigureApplication(options);
47
59
  }
48
60
  /**
49
- * Navigate to the home page and wait for the menu to load
61
+ * Navigate to the home page and wait for the menu to load.
50
62
  */
51
63
  async navigateHomeAndWaitForMenuToLoad() {
52
- const baseUrl = testwiseConfig().get('environmentSettings.baseUrl');
64
+ const baseUrl = testwiseConfig().get('environmentSettings.baseUrl')?.replace(/\/+$/, '');
65
+ const minimumTimeout = 60000;
53
66
  if (!baseUrl) {
54
67
  throw new Error('Base URL is not defined in the configuration.');
55
68
  }
69
+ let timeout = Number(testwiseConfig().get('featureSettings.other.loginTimeout') ?? minimumTimeout);
70
+ if (Number.isNaN(timeout) || timeout < minimumTimeout) {
71
+ timeout = minimumTimeout;
72
+ }
56
73
  await this._page.goto(baseUrl);
57
- await this._page.route('**/i_ui_menu?**', (route) => {
58
- route.continue();
59
- });
60
- const timeout = Number(testwiseConfig().get('featureSettings.other.loginTimeout') ?? 30000);
61
74
  await pollUntil(async () => this._page.url().includes('#application='), {
62
75
  timeout,
63
76
  interval: 200,
@@ -76,8 +89,8 @@ export class LoginHelper {
76
89
  throw new Error('Username and password are required for login.');
77
90
  }
78
91
  if (serviceUrl && metaEndpoint) {
79
- this.serviceUrl = serviceUrl;
80
- this.metaEndpoint = metaEndpoint;
92
+ this.serviceUrl = serviceUrl.replace(/\/+$/, '');
93
+ this.metaEndpoint = metaEndpoint.replace(/\/+$/, '');
81
94
  }
82
95
  const response = await this._page.request.post(`${this.serviceUrl}/account/api/login`, {
83
96
  form: {
@@ -137,6 +150,10 @@ export class LoginHelper {
137
150
  });
138
151
  });
139
152
  }
153
+ /**
154
+ * Logs out the current session by POSTing to the logout endpoint (accepts 204 or 401
155
+ * as valid responses), then clears all browser cookies.
156
+ */
140
157
  async logOut() {
141
158
  const response = await this._page.request.post(`${this.serviceUrl}/account/api/logout`);
142
159
  if (![204, 401].includes(response.status())) {
@@ -146,6 +163,14 @@ export class LoginHelper {
146
163
  }
147
164
  }
148
165
  export class UserPreferences {
166
+ /**
167
+ * Initialises the `UserPreferences` service, resolving the service URL, meta endpoint,
168
+ * and GUI application alias from config (overridable via optional parameters) and
169
+ * constructing the full Indicium endpoint URL.
170
+ * @param requestContext - The Playwright `Page` used to make API requests.
171
+ * @param serviceUrl - Optional override for the service URL from config.
172
+ * @param metaEndpoint - Optional override for the meta endpoint from config.
173
+ */
149
174
  constructor(requestContext, serviceUrl, metaEndpoint) {
150
175
  this.guiApplAlias = String(testwiseConfig().get('environmentSettings.guiApplAlias'));
151
176
  this._page = requestContext;
@@ -157,8 +182,13 @@ export class UserPreferences {
157
182
  throw new Error('Meta endpoint not found or is empty');
158
183
  if (!this.guiApplAlias)
159
184
  throw new Error('GUI application alias not found or is empty');
160
- this.url = `${serviceUrl}/${metaEndpoint}/${this.guiApplAlias}`;
185
+ this.url = `${serviceUrl.replace(/\/+$/, '')}/${metaEndpoint.replace(/\/+$/, '')}/${this.guiApplAlias}`;
161
186
  }
187
+ /**
188
+ * Activates a specific user preference configuration for the current session by POSTing
189
+ * to the `set_up_configuration` endpoint with the given configuration ID.
190
+ * @param upConfigurationId - The ID of the user preference configuration to activate.
191
+ */
162
192
  async run(upConfigurationId) {
163
193
  const fullUrl = `${this.url}/set_up_configuration`;
164
194
  const data = {
@@ -166,6 +196,11 @@ export class UserPreferences {
166
196
  };
167
197
  await this._page.request.post(fullUrl, { headers: { 'Content-Type': 'application/json; charset=utf-8' }, data });
168
198
  }
199
+ /**
200
+ * Disables all active user preferences for the current session by POSTing to the
201
+ * `disable_up` endpoint.
202
+ * @returns The raw Playwright `APIResponse`.
203
+ */
169
204
  async disable() {
170
205
  const fullUrl = `${this.url}/disable_up`;
171
206
  return await this._page.request.post(fullUrl, { headers: { 'Content-Type': 'application/json; charset=utf-8' } });
@@ -1 +1 @@
1
- {"version":3,"file":"LoginHelper.js","sourceRoot":"","sources":["../../helpers/LoginHelper.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,SAAS,CAAC;AACzB,OAAO,IAAI,MAAM,WAAW,CAAC;AAC7B,OAAO,EAAE,aAAa,EAAE,MAAM,UAAU,CAAC;AAEzC,OAAO,EAAE,cAAc,EAAE,MAAM,8BAA8B,CAAC;AAE9D,OAAO,EAAE,SAAS,EAAE,MAAM,WAAW,CAAC;AAE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AAK,CAAC,OAAO;QAClB,MAAM,OAAO,GAAG,GAAG,IAAI,CAAC,GAAG,aAAa,CAAC;QAEzC,OAAO,MAAM,IAAI,CAAC,KAAK,CAAC,OAAO,CAAC,IAAI,CAAC,OAAO,EAAE,EAAE,OAAO,EAAE,EAAE,cAAc,EAAE,iCAAiC,EAAE,EAAE,CAAC,CAAC;IACpH,CAAC;CACF"}
@@ -1,3 +1,25 @@
1
+ /**
2
+ * Locates the root directory of the **consumer project** (the project that has
3
+ * `@thinkwise/testwise` installed as a dependency) at runtime.
4
+ *
5
+ * **Why this exists:** Testwise runs from inside `node_modules` but needs to
6
+ * read and write files that belong to the consuming project (e.g.
7
+ * `registeredSubjects.json`, `Testwise.json`). Simply using `process.cwd()`
8
+ * is unreliable when scripts are invoked from sub-directories. This class
9
+ * walks up the directory tree looking for the first `package.json` whose
10
+ * `name` is NOT `@thinkwise/testwise`, which is guaranteed to be the consumer
11
+ * project root.
12
+ *
13
+ * **How to use it:** Inject it into any pipeline helper that needs to write
14
+ * to the consumer project. `PipelinePaths` already does this — you rarely
15
+ * need to instantiate `PathResolver` directly.
16
+ */
1
17
  export declare class PathResolver {
18
+ /**
19
+ * Walks up the directory tree from `process.cwd()` to find the nearest `package.json`
20
+ * whose `name` is not `@thinkwise/testwise`, returning that directory as the consumer
21
+ * project root. Falls back to `process.cwd()` if no such package is found.
22
+ * @returns Absolute path to the consumer project's root directory.
23
+ */
2
24
  getConsumerRootDirectory(): string;
3
25
  }
@@ -1,6 +1,28 @@
1
1
  import fs from 'node:fs';
2
2
  import path from 'node:path';
3
+ /**
4
+ * Locates the root directory of the **consumer project** (the project that has
5
+ * `@thinkwise/testwise` installed as a dependency) at runtime.
6
+ *
7
+ * **Why this exists:** Testwise runs from inside `node_modules` but needs to
8
+ * read and write files that belong to the consuming project (e.g.
9
+ * `registeredSubjects.json`, `Testwise.json`). Simply using `process.cwd()`
10
+ * is unreliable when scripts are invoked from sub-directories. This class
11
+ * walks up the directory tree looking for the first `package.json` whose
12
+ * `name` is NOT `@thinkwise/testwise`, which is guaranteed to be the consumer
13
+ * project root.
14
+ *
15
+ * **How to use it:** Inject it into any pipeline helper that needs to write
16
+ * to the consumer project. `PipelinePaths` already does this — you rarely
17
+ * need to instantiate `PathResolver` directly.
18
+ */
3
19
  export class PathResolver {
20
+ /**
21
+ * Walks up the directory tree from `process.cwd()` to find the nearest `package.json`
22
+ * whose `name` is not `@thinkwise/testwise`, returning that directory as the consumer
23
+ * project root. Falls back to `process.cwd()` if no such package is found.
24
+ * @returns Absolute path to the consumer project's root directory.
25
+ */
4
26
  getConsumerRootDirectory() {
5
27
  let directory = process.cwd();
6
28
  let lastDir = '';
@@ -1 +1 @@
1
- {"version":3,"file":"PathResolver.js","sourceRoot":"","sources":["../../helpers/PathResolver.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,SAAS,CAAC;AACzB,OAAO,IAAI,MAAM,WAAW,CAAC;AAE7B,MAAM,OAAO,YAAY;IAChB,wBAAwB;QAC7B,IAAI,SAAS,GAAG,OAAO,CAAC,GAAG,EAAE,CAAC;QAC9B,IAAI,OAAO,GAAG,EAAE,CAAC;QACjB,IAAI,KAAK,GAAG,KAAK,CAAC;QAElB,OAAO,SAAS,KAAK,OAAO,EAAE,CAAC;YAC7B,MAAM,OAAO,GAAG,IAAI,CAAC,IAAI,CAAC,SAAS,EAAE,cAAc,CAAC,CAAC;YAErD,IAAI,EAAE,CAAC,UAAU,CAAC,OAAO,CAAC,EAAE,CAAC;gBAC3B,MAAM,GAAG,GAAG,IAAI,CAAC,KAAK,CAAC,EAAE,CAAC,YAAY,CAAC,OAAO,EAAE,OAAO,CAAC,CAAC,CAAC;gBAC1D,IAAI,GAAG,CAAC,IAAI,KAAK,qBAAqB,EAAE,CAAC;oBACvC,KAAK,GAAG,IAAI,CAAC;oBACb,MAAM;gBACR,CAAC;YACH,CAAC;YAED,OAAO,GAAG,SAAS,CAAC;YACpB,SAAS,GAAG,IAAI,CAAC,OAAO,CAAC,SAAS,CAAC,CAAC;QACtC,CAAC;QACD,IAAI,CAAC,KAAK,EAAE,CAAC;YACX,SAAS,GAAG,OAAO,CAAC,GAAG,EAAE,CAAC;QAC5B,CAAC;QAED,OAAO,SAAS,CAAC;IACnB,CAAC;CACF"}
1
+ {"version":3,"file":"PathResolver.js","sourceRoot":"","sources":["../../helpers/PathResolver.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,SAAS,CAAC;AACzB,OAAO,IAAI,MAAM,WAAW,CAAC;AAE7B;;;;;;;;;;;;;;;GAeG;AACH,MAAM,OAAO,YAAY;IACvB;;;;;OAKG;IACI,wBAAwB;QAC7B,IAAI,SAAS,GAAG,OAAO,CAAC,GAAG,EAAE,CAAC;QAC9B,IAAI,OAAO,GAAG,EAAE,CAAC;QACjB,IAAI,KAAK,GAAG,KAAK,CAAC;QAElB,OAAO,SAAS,KAAK,OAAO,EAAE,CAAC;YAC7B,MAAM,OAAO,GAAG,IAAI,CAAC,IAAI,CAAC,SAAS,EAAE,cAAc,CAAC,CAAC;YAErD,IAAI,EAAE,CAAC,UAAU,CAAC,OAAO,CAAC,EAAE,CAAC;gBAC3B,MAAM,GAAG,GAAG,IAAI,CAAC,KAAK,CAAC,EAAE,CAAC,YAAY,CAAC,OAAO,EAAE,OAAO,CAAC,CAAC,CAAC;gBAC1D,IAAI,GAAG,CAAC,IAAI,KAAK,qBAAqB,EAAE,CAAC;oBACvC,KAAK,GAAG,IAAI,CAAC;oBACb,MAAM;gBACR,CAAC;YACH,CAAC;YAED,OAAO,GAAG,SAAS,CAAC;YACpB,SAAS,GAAG,IAAI,CAAC,OAAO,CAAC,SAAS,CAAC,CAAC;QACtC,CAAC;QACD,IAAI,CAAC,KAAK,EAAE,CAAC;YACX,SAAS,GAAG,OAAO,CAAC,GAAG,EAAE,CAAC;QAC5B,CAAC;QAED,OAAO,SAAS,CAAC;IACnB,CAAC;CACF"}
@@ -1,2 +1,14 @@
1
- import type { PollOptions } from '../types/PollTypes.ts';
1
+ import type { PollOptions } from '../types/PollTypes.js';
2
+ /**
3
+ * Repeatedly calls `fn` at a configurable interval until the optional `predicate` returns
4
+ * truthy or the `timeout` is exceeded, at which point it throws.
5
+ * `onTick` is called with the last value and elapsed time after each failing attempt.
6
+ * @param fn - The async or sync function to poll.
7
+ * @param opts.timeout - Maximum wait time in milliseconds (default `10 000`).
8
+ * @param opts.interval - Polling interval in milliseconds (default `200`).
9
+ * @param opts.predicate - Returns `true` when the result is acceptable (default: truthy check).
10
+ * @param opts.onTick - Called after each failing attempt with the last value and elapsed ms.
11
+ * @returns The first value for which `predicate` returns `true`.
12
+ * @throws If `timeout` is exceeded before `predicate` returns `true`.
13
+ */
2
14
  export declare function pollUntil<T>(fn: () => Promise<T> | T, opts?: PollOptions<T>): Promise<T>;
@@ -1,3 +1,15 @@
1
+ /**
2
+ * Repeatedly calls `fn` at a configurable interval until the optional `predicate` returns
3
+ * truthy or the `timeout` is exceeded, at which point it throws.
4
+ * `onTick` is called with the last value and elapsed time after each failing attempt.
5
+ * @param fn - The async or sync function to poll.
6
+ * @param opts.timeout - Maximum wait time in milliseconds (default `10 000`).
7
+ * @param opts.interval - Polling interval in milliseconds (default `200`).
8
+ * @param opts.predicate - Returns `true` when the result is acceptable (default: truthy check).
9
+ * @param opts.onTick - Called after each failing attempt with the last value and elapsed ms.
10
+ * @returns The first value for which `predicate` returns `true`.
11
+ * @throws If `timeout` is exceeded before `predicate` returns `true`.
12
+ */
1
13
  export async function pollUntil(fn, opts = {}) {
2
14
  const timeout = opts.timeout ?? 10000;
3
15
  const interval = opts.interval ?? 200;
@@ -1 +1 @@
1
- {"version":3,"file":"Poll.js","sourceRoot":"","sources":["../../helpers/Poll.ts"],"names":[],"mappings":"AAEA,MAAM,CAAC,KAAK,UAAU,SAAS,CAAI,EAAwB,EAAE,OAAuB,EAAE;IACpF,MAAM,OAAO,GAAG,IAAI,CAAC,OAAO,IAAI,KAAM,CAAC;IACvC,MAAM,QAAQ,GAAG,I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AG,GAAG,MAAM,EAAE,EAAE,CAAC;QACvB,IAAI,EAAE,CAAC,GAAG,CAAC;YAAE,OAAO,GAAG,CAAC;QAExB,IAAI,CAAC,MAAM,EAAE,CAAC,GAAG,EAAE,IAAI,CAAC,GAAG,EAAE,GAAG,KAAK,CAAC,CAAC;QACvC,IAAI,IAAI,CAAC,GAAG,EAAE,GAAG,KAAK,IAAI,OAAO,EAAE,CAAC;YAClC,MAAM,IAAI,KAAK,CAAC,2BAA2B,OAAO,IAAI,CAAC,CAAC;QAC1D,CAAC;QACD,MAAM,IAAI,OAAO,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,UAAU,CAAC,CAAC,EAAE,QAAQ,CAAC,CAAC,CAAC;IACpD,CAAC;AACH,CAAC"}
@@ -1,4 +1,19 @@
1
+ /**
2
+ * Escapes all characters with special meaning in regular expressions so that `input`
3
+ * can be safely embedded inside a `RegExp` constructor without unintended pattern matching.
4
+ * @param input - The raw string to escape.
5
+ * @returns The escaped string.
6
+ */
1
7
  export declare function escapeRegex(input: string): string;
8
+ /**
9
+ * Builds a case-insensitive, Unicode-safe `RegExp` that exactly matches `input`.
10
+ * Optionally trims leading/trailing whitespace and collapses internal whitespace runs
11
+ * to a single space to match typical UI text normalization.
12
+ * @param input - The text to match exactly.
13
+ * @param opts.trim - Trim leading/trailing whitespace before matching (default `true`).
14
+ * @param opts.collapseWhitespace - Collapse runs of whitespace to a single space (default `false`).
15
+ * @returns A case-insensitive `RegExp` anchored with `^` and `$`.
16
+ */
2
17
  export declare function exactTextRegex(input: string, opts?: {
3
18
  trim?: boolean;
4
19
  collapseWhitespace?: boolean;
@@ -1,9 +1,21 @@
1
- // Escapes characters with special meaning in regexes.
1
+ /**
2
+ * Escapes all characters with special meaning in regular expressions so that `input`
3
+ * can be safely embedded inside a `RegExp` constructor without unintended pattern matching.
4
+ * @param input - The raw string to escape.
5
+ * @returns The escaped string.
6
+ */
2
7
  export function escapeRegex(input) {
3
8
  return input.replace(/[.*+?^${}()|[\]\\]/g, '\\$&');
4
9
  }
5
- // Exact match, case-insensitive, Unicode-safe.
6
- // By default trims the input; set trim=false for truly literal.
10
+ /**
11
+ * Builds a case-insensitive, Unicode-safe `RegExp` that exactly matches `input`.
12
+ * Optionally trims leading/trailing whitespace and collapses internal whitespace runs
13
+ * to a single space to match typical UI text normalization.
14
+ * @param input - The text to match exactly.
15
+ * @param opts.trim - Trim leading/trailing whitespace before matching (default `true`).
16
+ * @param opts.collapseWhitespace - Collapse runs of whitespace to a single space (default `false`).
17
+ * @returns A case-insensitive `RegExp` anchored with `^` and `$`.
18
+ */
7
19
  export function exactTextRegex(input, opts) {
8
20
  const { trim = true, collapseWhitespace = false } = opts ?? {};
9
21
  let s = trim ? input.trim() : input;
@@ -1 +1 @@
1
- {"version":3,"file":"RegexHelper.js","sourceRoot":"","sources":["../../helpers/RegexHelper.ts"],"names":[],"mappings":"AAAA,sDAAsD;AACtD,MAAM,UAAU,WAAW,CAAC,KAAa;IACvC,OAAO,KAAK,CAAC,OAAO,CAAC,qBAAqB,EAAE,MAAM,CAAC,CAAC;AACtD,CAAC;AAED,+CAA+C;AAC/C,gEAAgE;AAChE,MAAM,UAAU,cAAc,CAAC,KAAa,EAAE,IAAuD;IACnG,MAAM,EAAE,IAAI,GAAG,IAAI,EAAE,kBAAkB,GAAG,KAAK,EAAE,GAAG,IAAI,IAAI,EAAE,CAAC;IAC/D,IAAI,CAAC,GAAG,IAAI,CAAC,CAAC,CAAC,KAAK,CAAC,IAAI,EAAE,CAAC,CAAC,CAAC,KAAK,CAAC;IAEpC,IAAI,kBAAkB,EAAE,CAAC;QACvB,wEAAwE;QACxE,CAAC,GAAG,CAAC,CAAC,OAAO,CAAC,MAAM,EAAE,GAAG,CAAC,CAAC;IAC7B,CAAC;IACD,OAAO,IAAI,MAAM,CAAC,IAAI,WAAW,CAAC,CAAC,CAAC,GAAG,EAAE,IAAI,CAAC,CAAC,CAAC,oCAAoC;AACtF,CAAC"}
1
+ {"version":3,"file":"RegexHelper.js","sourceRoot":"","sources":["../../helpers/RegexHelper.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AACH,MAAM,UAAU,WAAW,CAAC,KAAa;IACvC,OAAO,KAAK,CAAC,OAAO,CAAC,qBAAqB,EAAE,MAAM,CAAC,CAAC;AACtD,CAAC;AAED;;;;;;;;GAQG;AACH,MAAM,UAAU,cAAc,CAAC,KAAa,EAAE,IAAuD;IACnG,MAAM,EAAE,IAAI,GAAG,IAAI,EAAE,kBAAkB,GAAG,KAAK,EAAE,GAAG,IAAI,IAAI,EAAE,CAAC;IAC/D,IAAI,CAAC,GAAG,IAAI,CAAC,CAAC,CAAC,KAAK,CAAC,IAAI,EAAE,CAAC,CAAC,CAAC,KAAK,CAAC;IAEpC,IAAI,kBAAkB,EAAE,CAAC;QACvB,wEAAwE;QACxE,CAAC,GAAG,CAAC,CAAC,OAAO,CAAC,MAAM,EAAE,GAAG,CAAC,CAAC;IAC7B,CAAC;IACD,OAAO,IAAI,MAAM,CAAC,IAAI,WAAW,CAAC,CAAC,CAAC,GAAG,EAAE,IAAI,CAAC,CAAC,CAAC,oCAAoC;AACtF,CAAC"}
@@ -0,0 +1,26 @@
1
+ import type { Page } from '@playwright/test';
2
+ /**
3
+ * Navigates the browser to a Thinkwise subject deep-link URL and waits for
4
+ * the application to fully settle before returning control to the test.
5
+ *
6
+ * **Why this exists:** Calling `page.goto()` directly does not account for
7
+ * the asynchronous XHR requests that the Thinkwise app fires after a navigation
8
+ * event. Tests that act immediately after a bare `goto` frequently encounter
9
+ * loading spinners, empty grids, or incomplete form data. `SubjectNavigator`
10
+ * wraps navigation in a `FlightTracker` session so the test only continues
11
+ * once the network is truly idle.
12
+ *
13
+ * **How to use it:** You typically don't call this directly — it is used
14
+ * internally by the generated subject class `goTo()` methods. If you need
15
+ * to navigate imperatively in a test, prefer `page.subject.MySubjectClass.goTo()`.
16
+ *
17
+ * @example
18
+ * // Inside a generated subject class:
19
+ * const navigator = new SubjectNavigator(page);
20
+ * await navigator.navigateTo('subjects/Employee/Editable1/Main');
21
+ */
22
+ export declare class SubjectNavigator {
23
+ private readonly _page;
24
+ constructor(page: Page);
25
+ navigateTo(url: string): Promise<void>;
26
+ }
@@ -0,0 +1,51 @@
1
+ import { FlightTracker } from './FlightTracker.js';
2
+ /**
3
+ * Navigates the browser to a Thinkwise subject deep-link URL and waits for
4
+ * the application to fully settle before returning control to the test.
5
+ *
6
+ * **Why this exists:** Calling `page.goto()` directly does not account for
7
+ * the asynchronous XHR requests that the Thinkwise app fires after a navigation
8
+ * event. Tests that act immediately after a bare `goto` frequently encounter
9
+ * loading spinners, empty grids, or incomplete form data. `SubjectNavigator`
10
+ * wraps navigation in a `FlightTracker` session so the test only continues
11
+ * once the network is truly idle.
12
+ *
13
+ * **How to use it:** You typically don't call this directly — it is used
14
+ * internally by the generated subject class `goTo()` methods. If you need
15
+ * to navigate imperatively in a test, prefer `page.subject.MySubjectClass.goTo()`.
16
+ *
17
+ * @example
18
+ * // Inside a generated subject class:
19
+ * const navigator = new SubjectNavigator(page);
20
+ * await navigator.navigateTo('subjects/Employee/Editable1/Main');
21
+ */
22
+ export class SubjectNavigator {
23
+ constructor(page) {
24
+ this._page = page;
25
+ }
26
+ async navigateTo(url) {
27
+ const flightTracker = new FlightTracker();
28
+ const onRequest = (request) => {
29
+ flightTracker.handleRequestStarted(request.url(), request.resourceType());
30
+ };
31
+ const onResponse = (response) => {
32
+ flightTracker.handleRequestFinished(response.request().url());
33
+ };
34
+ const onRequestFailed = (request) => {
35
+ flightTracker.handleRequestFailed(request.url());
36
+ };
37
+ this._page.on('request', onRequest);
38
+ this._page.on('response', onResponse);
39
+ this._page.on('requestfailed', onRequestFailed);
40
+ try {
41
+ await this._page.goToDeepLink(url);
42
+ await flightTracker.waitForNavigationToSettle();
43
+ }
44
+ finally {
45
+ this._page.off('request', onRequest);
46
+ this._page.off('response', onResponse);
47
+ this._page.off('requestfailed', onRequestFailed);
48
+ }
49
+ }
50
+ }
51
+ //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,CAAC,KAAK,CAAC,GAAG,CAAC,SAAS,EAAE,SAAS,CAAC,CAAC;YACrC,IAAI,CAAC,KAAK,CAAC,GAAG,CAAC,UAAU,EAAE,UAAU,CAAC,CAAC;YACvC,IAAI,CAAC,KAAK,CAAC,GAAG,CAAC,eAAe,EAAE,eAAe,CAAC,CAAC;QACnD,CAAC;IACH,CAAC;CACF"}
@@ -1,4 +1,18 @@
1
1
  import type { Page } from '@playwright/test';
2
+ /**
3
+ * Simulates switching the active user identity in the Thinkwise application
4
+ * at runtime, without logging out and back in. Useful for testing
5
+ * role-based access control (RBAC) and user-specific workflows.
6
+ *
7
+ * Exposed on the page fixture via `UserSimulation` as `page.simulateUser()`,
8
+ * `page.getSimulatedUser()`, and `page.stopSimulation()`. You do not
9
+ * instantiate `UserSimulationHelper` directly in tests.
10
+ *
11
+ * @example
12
+ * await page.simulateUser('john.doe@example.com');
13
+ * // ... assert behaviour for this user ...
14
+ * await page.stopSimulation();
15
+ */
2
16
  export declare class UserSimulationHelper {
3
17
  private _page;
4
18
  private _serviceUrl;
@@ -1,5 +1,19 @@
1
1
  import { testwiseConfig } from '../services/ConfigBuilder.js';
2
2
  import { pollUntil } from './Poll.js';
3
+ /**
4
+ * Simulates switching the active user identity in the Thinkwise application
5
+ * at runtime, without logging out and back in. Useful for testing
6
+ * role-based access control (RBAC) and user-specific workflows.
7
+ *
8
+ * Exposed on the page fixture via `UserSimulation` as `page.simulateUser()`,
9
+ * `page.getSimulatedUser()`, and `page.stopSimulation()`. You do not
10
+ * instantiate `UserSimulationHelper` directly in tests.
11
+ *
12
+ * @example
13
+ * await page.simulateUser('john.doe@example.com');
14
+ * // ... assert behaviour for this user ...
15
+ * await page.stopSimulation();
16
+ */
3
17
  export class UserSimulationHelper {
4
18
  constructor(page) {
5
19
  this._page = page;
@@ -1 +1 @@
1
- {"version":3,"file":"UserSimulationHelper.js","sourceRoot":"","sources":["../../helpers/UserSimulationHelper.ts"],"names":[],"mappings":"AACA,OAAO,EAA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E,CAAC,IAAI,CAAC,gBAAgB,EAAE,EAAE;YAC7C,OAAO,EAAE,IAAK;YACd,QAAQ,EAAE,GAAG;YACb,SAAS,EAAE,CAAC,GAAG,EAAE,EAAE,CAAC,GAAG,KAAK,EAAE;SAC/B,CAAC,CAAC;IACL,CAAC;IAED;;;OAGG;IACI,KAAK,CAAC,YAAY,CAAC,QAAgB;QACxC,MAAM,QAAQ,GAAG,MAAM,IAAI,CAAC,KAAK,CAAC,OAAO,CAAC,KAAK,CAAC,GAAG,IAAI,CAAC,WAAW,6BAA6B,EAAE;YAChG,OAAO,EAAE;gBACP,cAAc,EAAE,kBAAkB;gBAClC,MAAM,EAAE,kBAAkB;aAC3B;YACD,IAAI,EAAE,IAAI,CAAC,SAAS,CAAC;gBACnB,cAAc,EAAE,QAAQ;aACzB,CAAC;SACH,CAAC,CAAC;QAEH,IAAI,QAAQ,CAAC,MAAM,EAAE,KAAK,GAAG,EAAE,CAAC;YAC9B,OAAO,CAAC,IAAI,CAAC,uCAAuC,EAAE,MAAM,QAAQ,CAAC,MAAM,EAAE,CAAC,CAAC;QACjF,CAAC;aAAM,CAAC;YACN,MAAM,IAAI,KAAK,CAAC,0CAA0C,MAAM,QAAQ,CAAC,MAAM,EAAE,EAAE,CAAC,CAAC;QACvF,CAAC;IACH,CAAC;CACF"}
@@ -1,3 +1,4 @@
1
1
  export * from './LoginHelper.js';
2
2
  export * from './PathResolver.js';
3
3
  export * from './RegexHelper.js';
4
+ export * from './SubjectNavigator.js';
@@ -1,4 +1,5 @@
1
1
  export * from './LoginHelper.js';
2
2
  export * from './PathResolver.js';
3
3
  export * from './RegexHelper.js';
4
+ export * from './SubjectNavigator.js';
4
5
  //# sourceMappingURL=index.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../helpers/index.ts"],"names":[],"mappings":"AAAA,cAAc,kBAAkB,CAAC;AACjC,cAAc,mBAAmB,CAAC;AAClC,cAAc,kBAAkB,CAAC"}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../helpers/index.ts"],"names":[],"mappings":"AAAA,cAAc,kBAAkB,CAAC;AACjC,cAAc,mBAAmB,CAAC;AAClC,cAAc,kBAAkB,CAAC;AACjC,cAAc,uBAAuB,CAAC"}
package/dist/index.d.ts CHANGED
@@ -1,28 +1,14 @@
1
- declare const originalLog: {
2
- (...data: any[]): void;
3
- (message?: any, ...optionalParams: any[]): void;
4
- };
5
- declare const originalInfo: {
6
- (...data: any[]): void;
7
- (message?: any, ...optionalParams: any[]): void;
8
- };
9
- declare const originalWarn: {
10
- (...data: any[]): void;
11
- (message?: any, ...optionalParams: any[]): void;
12
- };
13
- declare const originalError: {
14
- (...data: any[]): void;
15
- (message?: any, ...optionalParams: any[]): void;
16
- };
17
- declare const originalDebug: {
18
- (...data: any[]): void;
19
- (message?: any, ...optionalParams: any[]): void;
20
- };
1
+ declare const originalLog: (...data: any[]) => void;
2
+ declare const originalInfo: (...data: any[]) => void;
3
+ declare const originalWarn: (...data: any[]) => void;
4
+ declare const originalError: (...data: any[]) => void;
5
+ declare const originalDebug: (...data: any[]) => void;
21
6
  export * from './artifact-builder/index.js';
22
7
  export * from './components/index.js';
23
8
  export * from './controls/index.js';
24
9
  export * from './enums/index.js';
25
10
  export * from './helpers/index.js';
11
+ export * from './mcp/index.js';
26
12
  export * from './page-extensions/index.js';
27
13
  export * from './page-overrides/index.js';
28
14
  export * from './services/index.js';
package/dist/index.js CHANGED
@@ -14,6 +14,7 @@ export * from './components/index.js';
14
14
  export * from './controls/index.js';
15
15
  export * from './enums/index.js';
16
16
  export * from './helpers/index.js';
17
+ export * from './mcp/index.js';
17
18
  export * from './page-extensions/index.js';
18
19
  export * from './page-overrides/index.js';
19
20
  export * from './services/index.js';
package/dist/index.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,EAAE,MAAM,sBAAsB,CAAC;A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;AACnC,cAAc,gBAAgB,CAAC;AAC/B,cAAc,4BAA4B,CAAC;AAC3C,cAAc,2BAA2B,CAAC;AAC1C,cAAc,qBAAqB,CAAC;AACpC,cAAc,eAAe,CAAC;AAC9B,cAAc,kBAAkB,CAAC;AACjC,OAAO,EAAE,aAAa,EAAE,aAAa,EAAE,YAAY,EAAE,WAAW,EAAE,YAAY,EAAE,CAAC"}
@@ -1,5 +1,17 @@
1
1
  import type { Locator } from '@playwright/test';
2
+ /**
3
+ * Base contract that every `*Objects` class in `components/` and `controls/`
4
+ * must implement.
5
+ *
6
+ * **Why this exists:** Each component is split into two files — a `<Name>.ts`
7
+ * (public API with interaction methods) and a `<Name>Objects.ts` (raw locator
8
+ * accessors). `IComponentObjects` enforces that every `Objects` class exposes
9
+ * the two locators that all Thinkwise screens share: the scoped `context`
10
+ * locator and the page-level `mainHeader` locator used for presence checks.
11
+ */
2
12
  export interface IComponentObjects {
13
+ /** The scoped Playwright `Locator` that roots all locator lookups for this component instance. */
3
14
  context: Locator;
15
+ /** Locator for `main header` — used as a presence anchor to confirm the screen has rendered. */
4
16
  mainHeader: Locator;
5
17
  }
@@ -0,0 +1,15 @@
1
+ import type { SubjectComponents } from '../types/Components.js';
2
+ /** Metadata for a single property within a generated component schema. */
3
+ export interface IComponentPropertyMeta {
4
+ colId: string;
5
+ elementType: string;
6
+ }
7
+ /**
8
+ * The full meta file that SchemaGenerator writes alongside each `.json`
9
+ * schema file, and that SubjectComponentGenerator reads back to drive code
10
+ * generation.
11
+ */
12
+ export interface IComponentSchemaMeta {
13
+ componentType: SubjectComponents;
14
+ properties: Record<string, IComponentPropertyMeta>;
15
+ }
@@ -0,0 +1,2 @@
1
+ export {};
2
+ //# sourceMappingURL=IComponentSchemaMeta.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"IComponentSchemaMeta.js","sourceRoot":"","sources":["../../interfaces/IComponentSchemaMeta.ts"],"names":[],"mappings":""}
@@ -1,4 +1,17 @@
1
+ /**
2
+ * Describes a single field or column on a Thinkwise screen, as returned by
3
+ * the Indicium API and stored in `seed-data/subjects.json`.
4
+ *
5
+ * The `control_type` drives which Testwise control helper gets generated for
6
+ * the property (e.g. `"field"` → `InputFieldControl`, `"lookup"` → `LookupDropdown`).
7
+ */
1
8
  export interface IProperty {
9
+ /** The field or column identifier as defined in the Thinkwise model (e.g. `"employee_id"`). */
2
10
  col: string;
11
+ /**
12
+ * The Thinkwise UI control type for this property.
13
+ * Drives the control class suffix appended in generated subject components.
14
+ * Common values: `"field"`, `"lookup"`, `"dropdown"`, `"checkbox"`, `"date_picker"`, `"combo_box"`.
15
+ */
3
16
  control_type: string;
4
17
  }
@@ -1,5 +1,17 @@
1
+ /**
2
+ * Describes a subject that has been registered in the consumer project's
3
+ * `registeredSubjects.json` file.
4
+ *
5
+ * The `SubjectRegistration` pipeline step reads generated subject classes and
6
+ * writes an entry here for each one. The `SubjectRegistry` page-extension
7
+ * reads this file at test startup to make all subjects available on
8
+ * `page.subject.<ClassName>`.
9
+ */
1
10
  export interface IRegisteredSubjects {
11
+ /** Thinkwise subject identifier (e.g. `"Employee"`). */
2
12
  subject: string;
13
+ /** Optional variant discriminator when the same subject has multiple variants (e.g. `"Editable1"`). */
3
14
  variant?: string;
15
+ /** Screen type context — `"Main"`, `"Popup"`, `"Zoom"`, or `"Detail"`. */
4
16
  screen_type: string;
5
17
  }
@@ -0,0 +1,16 @@
1
+ import type { IProperty } from './IProperty.js';
2
+ /**
3
+ * Represents a subject as it is built from the Indicium API before properties
4
+ * are fully populated. `properties` is optional here because it is assigned
5
+ * after the initial object is constructed during the build phase.
6
+ *
7
+ * Once written to `subjects.json` and read back via `DataRetriever`, the data
8
+ * is typed as the narrower `ISubject` (which requires `properties`).
9
+ */
10
+ export interface ISeedSubjectDraft {
11
+ subject: string;
12
+ variant: string;
13
+ screentype_context: string;
14
+ screentype_id: string;
15
+ properties?: IProperty[];
16
+ }
@@ -0,0 +1,2 @@
1
+ export {};
2
+ //# sourceMappingURL=ISeedSubjectDraft.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ISeedSubjectDraft.js","sourceRoot":"","sources":["../../interfaces/ISeedSubjectDraft.ts"],"names":[],"mappings":""}