@fyuld/pano 0.1.9 → 0.2.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 (286) hide show
  1. package/dist/compile-principle.d.ts +3 -0
  2. package/dist/compile-principle.d.ts.map +1 -0
  3. package/dist/compile-principle.js +44 -0
  4. package/dist/compile-principle.js.map +1 -0
  5. package/dist/config-error.d.ts +6 -0
  6. package/dist/config-error.d.ts.map +1 -0
  7. package/dist/config-error.js +14 -0
  8. package/dist/config-error.js.map +1 -0
  9. package/dist/finding-error.d.ts +6 -0
  10. package/dist/finding-error.d.ts.map +1 -0
  11. package/dist/finding-error.js +14 -0
  12. package/dist/finding-error.js.map +1 -0
  13. package/dist/format.d.ts +1 -0
  14. package/dist/format.d.ts.map +1 -1
  15. package/dist/format.js +2 -1
  16. package/dist/format.js.map +1 -1
  17. package/dist/pano.d.ts +1 -1
  18. package/dist/pano.d.ts.map +1 -1
  19. package/dist/pano.js +253 -150
  20. package/dist/pano.js.map +1 -1
  21. package/dist/principles-compile.d.ts +6 -0
  22. package/dist/principles-compile.d.ts.map +1 -0
  23. package/dist/principles-compile.js +57 -0
  24. package/dist/principles-compile.js.map +1 -0
  25. package/dist/principles-verify.d.ts +7 -0
  26. package/dist/principles-verify.d.ts.map +1 -0
  27. package/dist/principles-verify.js +63 -0
  28. package/dist/principles-verify.js.map +1 -0
  29. package/dist/render-markdown-ansi.d.ts +2 -0
  30. package/dist/render-markdown-ansi.d.ts.map +1 -0
  31. package/dist/render-markdown-ansi.js +114 -0
  32. package/dist/render-markdown-ansi.js.map +1 -0
  33. package/dist/render-run-report.d.ts +3 -0
  34. package/dist/render-run-report.d.ts.map +1 -0
  35. package/dist/render-run-report.js +101 -0
  36. package/dist/render-run-report.js.map +1 -0
  37. package/dist/write-findings.d.ts +4 -0
  38. package/dist/write-findings.d.ts.map +1 -0
  39. package/dist/write-findings.js +58 -0
  40. package/dist/write-findings.js.map +1 -0
  41. package/dist/write-remarks.d.ts +3 -0
  42. package/dist/write-remarks.d.ts.map +1 -0
  43. package/dist/write-remarks.js +47 -0
  44. package/dist/write-remarks.js.map +1 -0
  45. package/node_modules/@fyuld/pano-bdd/dist/generate-bdd-steps-for-ux.d.ts +2 -0
  46. package/node_modules/@fyuld/pano-bdd/dist/generate-bdd-steps-for-ux.d.ts.map +1 -0
  47. package/node_modules/@fyuld/pano-bdd/dist/generate-bdd-steps-for-ux.js +40 -0
  48. package/node_modules/@fyuld/pano-bdd/dist/generate-bdd-steps-for-ux.js.map +1 -0
  49. package/node_modules/@fyuld/pano-bdd/dist/index.d.ts +2 -0
  50. package/node_modules/@fyuld/pano-bdd/dist/index.d.ts.map +1 -0
  51. package/node_modules/@fyuld/pano-bdd/dist/index.js +6 -0
  52. package/node_modules/@fyuld/pano-bdd/dist/index.js.map +1 -0
  53. package/node_modules/@fyuld/pano-bdd/package.json +36 -0
  54. package/node_modules/@fyuld/pano-dm/dist/config/PanOpticumConfig.d.ts +11 -0
  55. package/node_modules/@fyuld/pano-dm/dist/config/PanOpticumConfig.d.ts.map +1 -0
  56. package/node_modules/@fyuld/pano-dm/dist/config/PanOpticumConfig.js +3 -0
  57. package/node_modules/@fyuld/pano-dm/dist/config/PanOpticumConfig.js.map +1 -0
  58. package/node_modules/@fyuld/pano-dm/dist/config/index.d.ts +2 -0
  59. package/node_modules/@fyuld/pano-dm/dist/config/index.d.ts.map +1 -0
  60. package/node_modules/@fyuld/pano-dm/dist/config/index.js +3 -0
  61. package/node_modules/@fyuld/pano-dm/dist/config/index.js.map +1 -0
  62. package/node_modules/@fyuld/pano-dm/dist/entities/common.d.ts +3 -0
  63. package/node_modules/@fyuld/pano-dm/dist/entities/common.d.ts.map +1 -0
  64. package/node_modules/@fyuld/pano-dm/dist/entities/common.js +5 -0
  65. package/node_modules/@fyuld/pano-dm/dist/entities/common.js.map +1 -0
  66. package/node_modules/@fyuld/pano-dm/dist/entities/file-extension.d.ts +5 -0
  67. package/node_modules/@fyuld/pano-dm/dist/entities/file-extension.d.ts.map +1 -0
  68. package/node_modules/@fyuld/pano-dm/dist/entities/file-extension.js +9 -0
  69. package/node_modules/@fyuld/pano-dm/dist/entities/file-extension.js.map +1 -0
  70. package/node_modules/@fyuld/pano-dm/dist/entities/finding.d.ts +11 -0
  71. package/node_modules/@fyuld/pano-dm/dist/entities/finding.d.ts.map +1 -0
  72. package/node_modules/@fyuld/pano-dm/dist/entities/finding.js +3 -0
  73. package/node_modules/@fyuld/pano-dm/dist/entities/finding.js.map +1 -0
  74. package/node_modules/@fyuld/pano-dm/dist/entities/index.d.ts +7 -0
  75. package/node_modules/@fyuld/pano-dm/dist/entities/index.d.ts.map +1 -0
  76. package/node_modules/@fyuld/pano-dm/dist/entities/index.js +23 -0
  77. package/node_modules/@fyuld/pano-dm/dist/entities/index.js.map +1 -0
  78. package/node_modules/@fyuld/pano-dm/dist/entities/occurrence.d.ts +10 -0
  79. package/node_modules/@fyuld/pano-dm/dist/entities/occurrence.d.ts.map +1 -0
  80. package/node_modules/@fyuld/pano-dm/dist/entities/occurrence.js +3 -0
  81. package/node_modules/@fyuld/pano-dm/dist/entities/occurrence.js.map +1 -0
  82. package/node_modules/@fyuld/pano-dm/dist/entities/principle.d.ts +15 -0
  83. package/node_modules/@fyuld/pano-dm/dist/entities/principle.d.ts.map +1 -0
  84. package/node_modules/@fyuld/pano-dm/dist/entities/principle.js +3 -0
  85. package/node_modules/@fyuld/pano-dm/dist/entities/principle.js.map +1 -0
  86. package/node_modules/@fyuld/pano-dm/dist/entities/remark.d.ts +13 -0
  87. package/node_modules/@fyuld/pano-dm/dist/entities/remark.d.ts.map +1 -0
  88. package/node_modules/@fyuld/pano-dm/dist/entities/remark.js +3 -0
  89. package/node_modules/@fyuld/pano-dm/dist/entities/remark.js.map +1 -0
  90. package/node_modules/@fyuld/pano-dm/dist/index.d.ts +3 -0
  91. package/node_modules/@fyuld/pano-dm/dist/index.d.ts.map +1 -0
  92. package/node_modules/@fyuld/pano-dm/dist/index.js +19 -0
  93. package/node_modules/@fyuld/pano-dm/dist/index.js.map +1 -0
  94. package/node_modules/@fyuld/pano-dm/package.json +40 -0
  95. package/node_modules/@fyuld/pano-engine/dist/assessments/collect-findings.d.ts +9 -0
  96. package/node_modules/@fyuld/pano-engine/dist/assessments/collect-findings.d.ts.map +1 -0
  97. package/node_modules/@fyuld/pano-engine/dist/assessments/collect-findings.js +29 -0
  98. package/node_modules/@fyuld/pano-engine/dist/assessments/collect-findings.js.map +1 -0
  99. package/node_modules/@fyuld/pano-engine/dist/assessments/collect-occurrences.d.ts +8 -0
  100. package/node_modules/@fyuld/pano-engine/dist/assessments/collect-occurrences.d.ts.map +1 -0
  101. package/node_modules/@fyuld/pano-engine/dist/assessments/collect-occurrences.js +116 -0
  102. package/node_modules/@fyuld/pano-engine/dist/assessments/collect-occurrences.js.map +1 -0
  103. package/node_modules/@fyuld/pano-engine/dist/assessments/conditional-expressions/find-complex-conditional-expressions.d.ts +3 -0
  104. package/node_modules/@fyuld/pano-engine/dist/assessments/conditional-expressions/find-complex-conditional-expressions.d.ts.map +1 -0
  105. package/node_modules/@fyuld/pano-engine/dist/assessments/conditional-expressions/find-complex-conditional-expressions.js +6 -0
  106. package/node_modules/@fyuld/pano-engine/dist/assessments/conditional-expressions/find-complex-conditional-expressions.js.map +1 -0
  107. package/node_modules/@fyuld/pano-engine/dist/assessments/conditional-expressions/index.d.ts +3 -0
  108. package/node_modules/@fyuld/pano-engine/dist/assessments/conditional-expressions/index.d.ts.map +1 -0
  109. package/node_modules/@fyuld/pano-engine/dist/assessments/conditional-expressions/index.js +8 -0
  110. package/node_modules/@fyuld/pano-engine/dist/assessments/conditional-expressions/index.js.map +1 -0
  111. package/node_modules/@fyuld/pano-engine/dist/assessments/conditional-expressions/scan-conditional-expressions.d.ts +3 -0
  112. package/node_modules/@fyuld/pano-engine/dist/assessments/conditional-expressions/scan-conditional-expressions.d.ts.map +1 -0
  113. package/node_modules/@fyuld/pano-engine/dist/assessments/conditional-expressions/scan-conditional-expressions.js +94 -0
  114. package/node_modules/@fyuld/pano-engine/dist/assessments/conditional-expressions/scan-conditional-expressions.js.map +1 -0
  115. package/node_modules/@fyuld/pano-engine/dist/assessments/duplicate-declarations/find-duplicate-declarations.d.ts +3 -0
  116. package/node_modules/@fyuld/pano-engine/dist/assessments/duplicate-declarations/find-duplicate-declarations.d.ts.map +1 -0
  117. package/node_modules/@fyuld/pano-engine/dist/assessments/duplicate-declarations/find-duplicate-declarations.js +19 -0
  118. package/node_modules/@fyuld/pano-engine/dist/assessments/duplicate-declarations/find-duplicate-declarations.js.map +1 -0
  119. package/node_modules/@fyuld/pano-engine/dist/assessments/duplicate-declarations/index.d.ts +3 -0
  120. package/node_modules/@fyuld/pano-engine/dist/assessments/duplicate-declarations/index.d.ts.map +1 -0
  121. package/node_modules/@fyuld/pano-engine/dist/assessments/duplicate-declarations/index.js +8 -0
  122. package/node_modules/@fyuld/pano-engine/dist/assessments/duplicate-declarations/index.js.map +1 -0
  123. package/node_modules/@fyuld/pano-engine/dist/assessments/duplicate-declarations/scan-declarations.d.ts +3 -0
  124. package/node_modules/@fyuld/pano-engine/dist/assessments/duplicate-declarations/scan-declarations.d.ts.map +1 -0
  125. package/node_modules/@fyuld/pano-engine/dist/assessments/duplicate-declarations/scan-declarations.js +97 -0
  126. package/node_modules/@fyuld/pano-engine/dist/assessments/duplicate-declarations/scan-declarations.js.map +1 -0
  127. package/node_modules/@fyuld/pano-engine/dist/assessments/fixture-files/index.d.ts +2 -0
  128. package/node_modules/@fyuld/pano-engine/dist/assessments/fixture-files/index.d.ts.map +1 -0
  129. package/node_modules/@fyuld/pano-engine/dist/assessments/fixture-files/index.js +6 -0
  130. package/node_modules/@fyuld/pano-engine/dist/assessments/fixture-files/index.js.map +1 -0
  131. package/node_modules/@fyuld/pano-engine/dist/assessments/fixture-files/scan-fixture-files.d.ts +3 -0
  132. package/node_modules/@fyuld/pano-engine/dist/assessments/fixture-files/scan-fixture-files.d.ts.map +1 -0
  133. package/node_modules/@fyuld/pano-engine/dist/assessments/fixture-files/scan-fixture-files.js +15 -0
  134. package/node_modules/@fyuld/pano-engine/dist/assessments/fixture-files/scan-fixture-files.js.map +1 -0
  135. package/node_modules/@fyuld/pano-engine/dist/assessments/index-files/index.d.ts +2 -0
  136. package/node_modules/@fyuld/pano-engine/dist/assessments/index-files/index.d.ts.map +1 -0
  137. package/node_modules/@fyuld/pano-engine/dist/assessments/index-files/index.js +6 -0
  138. package/node_modules/@fyuld/pano-engine/dist/assessments/index-files/index.js.map +1 -0
  139. package/node_modules/@fyuld/pano-engine/dist/assessments/index-files/scan-index-files.d.ts +3 -0
  140. package/node_modules/@fyuld/pano-engine/dist/assessments/index-files/scan-index-files.d.ts.map +1 -0
  141. package/{dist/assessments/index-files/index.js → node_modules/@fyuld/pano-engine/dist/assessments/index-files/scan-index-files.js} +38 -43
  142. package/node_modules/@fyuld/pano-engine/dist/assessments/index-files/scan-index-files.js.map +1 -0
  143. package/node_modules/@fyuld/pano-engine/dist/assessments/scanned-row.d.ts +7 -0
  144. package/node_modules/@fyuld/pano-engine/dist/assessments/scanned-row.d.ts.map +1 -0
  145. package/node_modules/@fyuld/pano-engine/dist/assessments/scanned-row.js +3 -0
  146. package/node_modules/@fyuld/pano-engine/dist/assessments/scanned-row.js.map +1 -0
  147. package/node_modules/@fyuld/pano-engine/dist/assessments/string-literals/find-duplicate-string-literals.d.ts +3 -0
  148. package/node_modules/@fyuld/pano-engine/dist/assessments/string-literals/find-duplicate-string-literals.d.ts.map +1 -0
  149. package/node_modules/@fyuld/pano-engine/dist/assessments/string-literals/find-duplicate-string-literals.js +16 -0
  150. package/node_modules/@fyuld/pano-engine/dist/assessments/string-literals/find-duplicate-string-literals.js.map +1 -0
  151. package/node_modules/@fyuld/pano-engine/dist/assessments/string-literals/index.d.ts +3 -0
  152. package/node_modules/@fyuld/pano-engine/dist/assessments/string-literals/index.d.ts.map +1 -0
  153. package/node_modules/@fyuld/pano-engine/dist/assessments/string-literals/index.js +8 -0
  154. package/node_modules/@fyuld/pano-engine/dist/assessments/string-literals/index.js.map +1 -0
  155. package/node_modules/@fyuld/pano-engine/dist/assessments/string-literals/scan-string-literals.d.ts +3 -0
  156. package/node_modules/@fyuld/pano-engine/dist/assessments/string-literals/scan-string-literals.d.ts.map +1 -0
  157. package/node_modules/@fyuld/pano-engine/dist/assessments/string-literals/scan-string-literals.js +131 -0
  158. package/node_modules/@fyuld/pano-engine/dist/assessments/string-literals/scan-string-literals.js.map +1 -0
  159. package/node_modules/@fyuld/pano-engine/dist/index.d.ts +11 -0
  160. package/node_modules/@fyuld/pano-engine/dist/index.d.ts.map +1 -0
  161. package/node_modules/@fyuld/pano-engine/dist/index.js +27 -0
  162. package/node_modules/@fyuld/pano-engine/dist/index.js.map +1 -0
  163. package/node_modules/@fyuld/pano-engine/dist/languages/terraform/index.d.ts +3 -0
  164. package/node_modules/@fyuld/pano-engine/dist/languages/terraform/index.d.ts.map +1 -0
  165. package/node_modules/@fyuld/pano-engine/dist/languages/terraform/index.js +7 -0
  166. package/node_modules/@fyuld/pano-engine/dist/languages/terraform/index.js.map +1 -0
  167. package/node_modules/@fyuld/pano-engine/dist/languages/terraform/parser.d.ts +15 -0
  168. package/node_modules/@fyuld/pano-engine/dist/languages/terraform/parser.d.ts.map +1 -0
  169. package/node_modules/@fyuld/pano-engine/dist/languages/terraform/parser.js +58 -0
  170. package/node_modules/@fyuld/pano-engine/dist/languages/terraform/parser.js.map +1 -0
  171. package/node_modules/@fyuld/pano-engine/dist/languages/typescript/index.d.ts +3 -0
  172. package/{dist → node_modules/@fyuld/pano-engine/dist}/languages/typescript/index.d.ts.map +1 -1
  173. package/{dist → node_modules/@fyuld/pano-engine/dist}/languages/typescript/index.js +0 -1
  174. package/{dist → node_modules/@fyuld/pano-engine/dist}/languages/typescript/index.js.map +1 -1
  175. package/{dist → node_modules/@fyuld/pano-engine/dist}/languages/typescript/parser.d.ts +1 -0
  176. package/{dist → node_modules/@fyuld/pano-engine/dist}/languages/typescript/parser.d.ts.map +1 -1
  177. package/{dist → node_modules/@fyuld/pano-engine/dist}/languages/typescript/parser.js +25 -1
  178. package/node_modules/@fyuld/pano-engine/dist/languages/typescript/parser.js.map +1 -0
  179. package/node_modules/@fyuld/pano-engine/dist/principles/evaluate-constraint.d.ts +2 -0
  180. package/node_modules/@fyuld/pano-engine/dist/principles/evaluate-constraint.d.ts.map +1 -0
  181. package/node_modules/@fyuld/pano-engine/dist/principles/evaluate-constraint.js +11 -0
  182. package/node_modules/@fyuld/pano-engine/dist/principles/evaluate-constraint.js.map +1 -0
  183. package/node_modules/@fyuld/pano-engine/dist/principles/render-remarks.d.ts +4 -0
  184. package/node_modules/@fyuld/pano-engine/dist/principles/render-remarks.d.ts.map +1 -0
  185. package/node_modules/@fyuld/pano-engine/dist/principles/render-remarks.js +11 -0
  186. package/node_modules/@fyuld/pano-engine/dist/principles/render-remarks.js.map +1 -0
  187. package/node_modules/@fyuld/pano-engine/dist/principles/run-principles.d.ts +9 -0
  188. package/node_modules/@fyuld/pano-engine/dist/principles/run-principles.d.ts.map +1 -0
  189. package/node_modules/@fyuld/pano-engine/dist/principles/run-principles.js +22 -0
  190. package/node_modules/@fyuld/pano-engine/dist/principles/run-principles.js.map +1 -0
  191. package/node_modules/@fyuld/pano-engine/dist/principles/violation-to-be-renamed-to-remark.d.ts +3 -0
  192. package/node_modules/@fyuld/pano-engine/dist/principles/violation-to-be-renamed-to-remark.d.ts.map +1 -0
  193. package/node_modules/@fyuld/pano-engine/dist/principles/violation-to-be-renamed-to-remark.js +3 -0
  194. package/node_modules/@fyuld/pano-engine/dist/principles/violation-to-be-renamed-to-remark.js.map +1 -0
  195. package/node_modules/@fyuld/pano-engine/dist/render/index.d.ts +4 -0
  196. package/node_modules/@fyuld/pano-engine/dist/render/index.d.ts.map +1 -0
  197. package/node_modules/@fyuld/pano-engine/dist/render/index.js +10 -0
  198. package/node_modules/@fyuld/pano-engine/dist/render/index.js.map +1 -0
  199. package/node_modules/@fyuld/pano-engine/dist/render/render-csv.d.ts +3 -0
  200. package/node_modules/@fyuld/pano-engine/dist/render/render-csv.d.ts.map +1 -0
  201. package/node_modules/@fyuld/pano-engine/dist/render/render-csv.js +13 -0
  202. package/node_modules/@fyuld/pano-engine/dist/render/render-csv.js.map +1 -0
  203. package/node_modules/@fyuld/pano-engine/dist/render/render-helpers.d.ts +4 -0
  204. package/node_modules/@fyuld/pano-engine/dist/render/render-helpers.d.ts.map +1 -0
  205. package/node_modules/@fyuld/pano-engine/dist/render/render-helpers.js +24 -0
  206. package/node_modules/@fyuld/pano-engine/dist/render/render-helpers.js.map +1 -0
  207. package/node_modules/@fyuld/pano-engine/dist/render/render-json.d.ts +3 -0
  208. package/node_modules/@fyuld/pano-engine/dist/render/render-json.d.ts.map +1 -0
  209. package/node_modules/@fyuld/pano-engine/dist/render/render-json.js +6 -0
  210. package/node_modules/@fyuld/pano-engine/dist/render/render-json.js.map +1 -0
  211. package/node_modules/@fyuld/pano-engine/dist/render/render-md.d.ts +3 -0
  212. package/node_modules/@fyuld/pano-engine/dist/render/render-md.d.ts.map +1 -0
  213. package/node_modules/@fyuld/pano-engine/dist/render/render-md.js +14 -0
  214. package/node_modules/@fyuld/pano-engine/dist/render/render-md.js.map +1 -0
  215. package/node_modules/@fyuld/pano-engine/package.json +51 -0
  216. package/node_modules/@fyuld/pano-errors/dist/aggregateErrors.d.ts +3 -0
  217. package/node_modules/@fyuld/pano-errors/dist/aggregateErrors.d.ts.map +1 -0
  218. package/node_modules/@fyuld/pano-errors/dist/aggregateErrors.js +15 -0
  219. package/node_modules/@fyuld/pano-errors/dist/aggregateErrors.js.map +1 -0
  220. package/node_modules/@fyuld/pano-errors/dist/aggregateThrows.d.ts +3 -0
  221. package/node_modules/@fyuld/pano-errors/dist/aggregateThrows.d.ts.map +1 -0
  222. package/node_modules/@fyuld/pano-errors/dist/aggregateThrows.js +13 -0
  223. package/node_modules/@fyuld/pano-errors/dist/aggregateThrows.js.map +1 -0
  224. package/node_modules/@fyuld/pano-errors/dist/error-declarations.d.ts +10 -0
  225. package/node_modules/@fyuld/pano-errors/dist/error-declarations.d.ts.map +1 -0
  226. package/node_modules/@fyuld/pano-errors/dist/error-declarations.js +63 -0
  227. package/node_modules/@fyuld/pano-errors/dist/error-declarations.js.map +1 -0
  228. package/node_modules/@fyuld/pano-errors/dist/errors.d.ts +21 -0
  229. package/node_modules/@fyuld/pano-errors/dist/errors.d.ts.map +1 -0
  230. package/node_modules/@fyuld/pano-errors/dist/errors.js +179 -0
  231. package/node_modules/@fyuld/pano-errors/dist/errors.js.map +1 -0
  232. package/node_modules/@fyuld/pano-errors/dist/index.d.ts +3 -0
  233. package/node_modules/@fyuld/pano-errors/dist/index.d.ts.map +1 -0
  234. package/node_modules/@fyuld/pano-errors/dist/index.js +8 -0
  235. package/node_modules/@fyuld/pano-errors/dist/index.js.map +1 -0
  236. package/node_modules/@fyuld/pano-errors/package.json +41 -0
  237. package/package.json +23 -12
  238. package/dist/assessments/classes/index.d.ts +0 -15
  239. package/dist/assessments/classes/index.d.ts.map +0 -1
  240. package/dist/assessments/classes/index.js +0 -112
  241. package/dist/assessments/classes/index.js.map +0 -1
  242. package/dist/assessments/index-files/index.d.ts +0 -13
  243. package/dist/assessments/index-files/index.d.ts.map +0 -1
  244. package/dist/assessments/index-files/index.js.map +0 -1
  245. package/dist/assessments/throws/index.d.ts +0 -16
  246. package/dist/assessments/throws/index.d.ts.map +0 -1
  247. package/dist/assessments/throws/index.js +0 -110
  248. package/dist/assessments/throws/index.js.map +0 -1
  249. package/dist/assessments/types/index.d.ts +0 -14
  250. package/dist/assessments/types/index.d.ts.map +0 -1
  251. package/dist/assessments/types/index.js +0 -96
  252. package/dist/assessments/types/index.js.map +0 -1
  253. package/dist/fitness-tests/barrel-purity/index.d.ts +0 -11
  254. package/dist/fitness-tests/barrel-purity/index.d.ts.map +0 -1
  255. package/dist/fitness-tests/barrel-purity/index.js +0 -84
  256. package/dist/fitness-tests/barrel-purity/index.js.map +0 -1
  257. package/dist/fitness-tests/datamodel-encapsulation/index.d.ts +0 -10
  258. package/dist/fitness-tests/datamodel-encapsulation/index.d.ts.map +0 -1
  259. package/dist/fitness-tests/datamodel-encapsulation/index.js +0 -99
  260. package/dist/fitness-tests/datamodel-encapsulation/index.js.map +0 -1
  261. package/dist/fitness-tests/error-factories/index.d.ts +0 -17
  262. package/dist/fitness-tests/error-factories/index.d.ts.map +0 -1
  263. package/dist/fitness-tests/error-factories/index.js +0 -97
  264. package/dist/fitness-tests/error-factories/index.js.map +0 -1
  265. package/dist/fitness-tests/unhelpful-errors/index.d.ts +0 -11
  266. package/dist/fitness-tests/unhelpful-errors/index.d.ts.map +0 -1
  267. package/dist/fitness-tests/unhelpful-errors/index.js +0 -87
  268. package/dist/fitness-tests/unhelpful-errors/index.js.map +0 -1
  269. package/dist/languages/typescript/comment-classification.d.ts +0 -8
  270. package/dist/languages/typescript/comment-classification.d.ts.map +0 -1
  271. package/dist/languages/typescript/comment-classification.js +0 -45
  272. package/dist/languages/typescript/comment-classification.js.map +0 -1
  273. package/dist/languages/typescript/index.d.ts +0 -4
  274. package/dist/languages/typescript/parser.js.map +0 -1
  275. /package/{dist → node_modules/@fyuld/pano-engine/dist}/languages/gherkin/index.d.ts +0 -0
  276. /package/{dist → node_modules/@fyuld/pano-engine/dist}/languages/gherkin/index.d.ts.map +0 -0
  277. /package/{dist → node_modules/@fyuld/pano-engine/dist}/languages/gherkin/index.js +0 -0
  278. /package/{dist → node_modules/@fyuld/pano-engine/dist}/languages/gherkin/index.js.map +0 -0
  279. /package/{dist → node_modules/@fyuld/pano-engine/dist}/languages/gherkin/parser.d.ts +0 -0
  280. /package/{dist → node_modules/@fyuld/pano-engine/dist}/languages/gherkin/parser.d.ts.map +0 -0
  281. /package/{dist → node_modules/@fyuld/pano-engine/dist}/languages/gherkin/parser.js +0 -0
  282. /package/{dist → node_modules/@fyuld/pano-engine/dist}/languages/gherkin/parser.js.map +0 -0
  283. /package/{dist → node_modules/@fyuld/pano-engine/dist}/languages/typescript/comments.d.ts +0 -0
  284. /package/{dist → node_modules/@fyuld/pano-engine/dist}/languages/typescript/comments.d.ts.map +0 -0
  285. /package/{dist → node_modules/@fyuld/pano-engine/dist}/languages/typescript/comments.js +0 -0
  286. /package/{dist → node_modules/@fyuld/pano-engine/dist}/languages/typescript/comments.js.map +0 -0
@@ -0,0 +1 @@
1
+ {"version":3,"file":"find-duplicate-declarations.js","sourceRoot":"","sources":["../../../src/assessments/duplicate-declarations/find-duplicate-declarations.ts"],"names":[],"mappings":";;;AAEO,MAAM,yBAAyB,GAAG,CACvC,WAAyB,EACd,EAAE;IACb,MAAM,MAAM,GAAG,IAAI,GAAG,EAAkB,CAAA;IAExC,IAAI,CAAC,KAAK,CAAC,IAAI,CAAC,KAAK,CAAC,EAAE,CAAC;QACvB,OAAO,CAAC,GAAG,CAAC,aAAa,CAAC,CAAA;IAC5B,CAAC;IAED,KAAK,MAAM,CAAC,IAAI,WAAW,EAAE,CAAC;QAC5B,MAAM,CAAC,GAAG,CAAC,CAAC,IAAc,CAAA;QAC1B,MAAM,CAAC,GAAG,CAAC,CAAC,EAAE,CAAC,MAAM,CAAC,GAAG,CAAC,CAAC,CAAC,IAAI,CAAC,CAAC,GAAG,CAAC,CAAC,CAAA;IACzC,CAAC;IAED,OAAO,WAAW;SACf,MAAM,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,MAAM,CAAC,GAAG,CAAC,CAAC,CAAC,IAAc,CAAC,IAAI,CAAC,CAAC,GAAG,CAAC,CAAC;SACtD,GAAG,CAAC,CAAC,CAAC,EAAW,EAAE,CAAC,CAAC,EAAE,GAAG,CAAC,EAAE,OAAO,EAAE,MAAM,CAAC,GAAG,CAAC,CAAC,CAAC,IAAc,CAAC,EAAE,CAAC,CAAC;SACtE,IAAI,CAAC,CAAC,CAAC,EAAE,CAAC,EAAE,EAAE,CAAE,CAAC,CAAC,IAAe,CAAC,aAAa,CAAC,CAAC,CAAC,IAAc,CAAC,CAAC,CAAA;AACvE,CAAC,CAAA;AAlBY,QAAA,yBAAyB,6BAkBrC"}
@@ -0,0 +1,3 @@
1
+ export { scanDeclarations } from './scan-declarations';
2
+ export { findDuplicateDeclarations } from './find-duplicate-declarations';
3
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/assessments/duplicate-declarations/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,gBAAgB,EAAE,MAAM,qBAAqB,CAAA;AACtD,OAAO,EAAE,yBAAyB,EAAE,MAAM,+BAA+B,CAAA"}
@@ -0,0 +1,8 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.findDuplicateDeclarations = exports.scanDeclarations = void 0;
4
+ var scan_declarations_1 = require("./scan-declarations");
5
+ Object.defineProperty(exports, "scanDeclarations", { enumerable: true, get: function () { return scan_declarations_1.scanDeclarations; } });
6
+ var find_duplicate_declarations_1 = require("./find-duplicate-declarations");
7
+ Object.defineProperty(exports, "findDuplicateDeclarations", { enumerable: true, get: function () { return find_duplicate_declarations_1.findDuplicateDeclarations; } });
8
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/assessments/duplicate-declarations/index.ts"],"names":[],"mappings":";;;AAAA,yDAAsD;AAA7C,qHAAA,gBAAgB,OAAA;AACzB,6EAAyE;AAAhE,wIAAA,yBAAyB,OAAA"}
@@ -0,0 +1,3 @@
1
+ import { ScannedRow } from '../scanned-row';
2
+ export declare const scanDeclarations: (files: string[]) => ScannedRow[];
3
+ //# sourceMappingURL=scan-declarations.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"scan-declarations.d.ts","sourceRoot":"","sources":["../../../src/assessments/duplicate-declarations/scan-declarations.ts"],"names":[],"mappings":"AAGA,OAAO,EAAE,UAAU,EAAE,MAAM,gBAAgB,CAAA;AAsB3C,eAAO,MAAM,gBAAgB,GAAI,OAAO,MAAM,EAAE,KAAG,UAAU,EAuD5D,CAAA"}
@@ -0,0 +1,97 @@
1
+ "use strict";
2
+ var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
3
+ if (k2 === undefined) k2 = k;
4
+ var desc = Object.getOwnPropertyDescriptor(m, k);
5
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
6
+ desc = { enumerable: true, get: function() { return m[k]; } };
7
+ }
8
+ Object.defineProperty(o, k2, desc);
9
+ }) : (function(o, m, k, k2) {
10
+ if (k2 === undefined) k2 = k;
11
+ o[k2] = m[k];
12
+ }));
13
+ var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
14
+ Object.defineProperty(o, "default", { enumerable: true, value: v });
15
+ }) : function(o, v) {
16
+ o["default"] = v;
17
+ });
18
+ var __importStar = (this && this.__importStar) || (function () {
19
+ var ownKeys = function(o) {
20
+ ownKeys = Object.getOwnPropertyNames || function (o) {
21
+ var ar = [];
22
+ for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
23
+ return ar;
24
+ };
25
+ return ownKeys(o);
26
+ };
27
+ return function (mod) {
28
+ if (mod && mod.__esModule) return mod;
29
+ var result = {};
30
+ if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
31
+ __setModuleDefault(result, mod);
32
+ return result;
33
+ };
34
+ })();
35
+ Object.defineProperty(exports, "__esModule", { value: true });
36
+ exports.scanDeclarations = void 0;
37
+ const fs = __importStar(require("fs"));
38
+ const ts = __importStar(require("typescript"));
39
+ const ldm_1 = require("@fyuld/ldm");
40
+ const typescript_1 = require("../../languages/typescript");
41
+ const terraform_1 = require("../../languages/terraform");
42
+ const lineOf = (node, sourceFile) => sourceFile.getLineAndCharacterOfPosition(node.getStart(sourceFile)).line + 1;
43
+ const codeAt = (line, lines) => (lines[line - 1] ?? '').trim();
44
+ const isAnonymousDeclaration = (declaration) => declaration.name === undefined;
45
+ const scanDeclarations = (files) => {
46
+ const occurrences = [];
47
+ for (const file of files) {
48
+ const source = fs.readFileSync(file, ldm_1.FileFormat.Utf8);
49
+ if (file.endsWith('.tf')) {
50
+ for (const decl of (0, terraform_1.parseTerraformDeclarations)(source)) {
51
+ occurrences.push({
52
+ name: decl.name,
53
+ kind: decl.kind,
54
+ file,
55
+ line: decl.line,
56
+ code: decl.code,
57
+ });
58
+ }
59
+ continue;
60
+ }
61
+ const sourceFile = (0, typescript_1.parseTypeScript)(source, file);
62
+ const lines = source.split('\n');
63
+ const push = (name, kind, node) => {
64
+ const line = lineOf(node, sourceFile);
65
+ occurrences.push({ name, kind, file, line, code: codeAt(line, lines) });
66
+ };
67
+ for (const declaration of sourceFile.statements) {
68
+ const isNamedFunctionDeclaration = ts.isFunctionDeclaration(declaration) &&
69
+ !isAnonymousDeclaration(declaration);
70
+ const isNamedClassDeclaration = ts.isClassDeclaration(declaration) &&
71
+ !isAnonymousDeclaration(declaration);
72
+ if (ts.isVariableStatement(declaration)) {
73
+ const isConst = (declaration.declarationList.flags & ts.NodeFlags.Const) !== 0;
74
+ for (const decl of declaration.declarationList.declarations) {
75
+ if (ts.isIdentifier(decl.name)) {
76
+ push(decl.name.text, isConst ? 'constant' : 'variable', decl);
77
+ }
78
+ }
79
+ }
80
+ else if (isNamedFunctionDeclaration) {
81
+ push(declaration.name.text, 'function', declaration);
82
+ }
83
+ else if (isNamedClassDeclaration) {
84
+ push(declaration.name.text, 'class', declaration);
85
+ }
86
+ else if (ts.isTypeAliasDeclaration(declaration)) {
87
+ push(declaration.name.text, 'type', declaration);
88
+ }
89
+ else if (ts.isInterfaceDeclaration(declaration)) {
90
+ push(declaration.name.text, 'interface', declaration);
91
+ }
92
+ }
93
+ }
94
+ return occurrences;
95
+ };
96
+ exports.scanDeclarations = scanDeclarations;
97
+ //# sourceMappingURL=scan-declarations.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"scan-declarations.js","sourceRoot":"","sources":["../../../src/assessments/duplicate-declarations/scan-declarations.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,uCAAwB;AACxB,+CAAgC;AAChC,oCAAuC;AAEvC,2DAA4D;AAC5D,yDAAsE;AAUtE,MAAM,MAAM,GAAG,CAAC,IAAa,EAAE,UAAyB,EAAU,EAAE,CAClE,UAAU,CAAC,6BAA6B,CAAC,IAAI,CAAC,QAAQ,CAAC,UAAU,CAAC,CAAC,CAAC,IAAI,GAAG,CAAC,CAAA;AAE9E,MAAM,MAAM,GAAG,CAAC,IAAY,EAAE,KAAe,EAAU,EAAE,CACvD,CAAC,KAAK,CAAC,IAAI,GAAG,CAAC,CAAC,IAAI,EAAE,CAAC,CAAC,IAAI,EAAE,CAAA;AAEhC,MAAM,sBAAsB,GAAG,CAC7B,WAAyD,EAChD,EAAE,CAAC,WAAW,CAAC,IAAI,KAAK,SAAS,CAAA;AAErC,MAAM,gBAAgB,GAAG,CAAC,KAAe,EAAgB,EAAE;IAChE,MAAM,WAAW,GAAiB,EAAE,CAAA;IAEpC,KAAK,MAAM,IAAI,IAAI,KAAK,EAAE,CAAC;QACzB,MAAM,MAAM,GAAG,EAAE,CAAC,YAAY,CAAC,IAAI,EAAE,gBAAU,CAAC,IAAI,CAAC,CAAA;QAErD,IAAI,IAAI,CAAC,QAAQ,CAAC,KAAK,CAAC,EAAE,CAAC;YACzB,KAAK,MAAM,IAAI,IAAI,IAAA,sCAA0B,EAAC,MAAM,CAAC,EAAE,CAAC;gBACtD,WAAW,CAAC,IAAI,CAAC;oBACf,IAAI,EAAE,IAAI,CAAC,IAAI;oBACf,IAAI,EAAE,IAAI,CAAC,IAAI;oBACf,IAAI;oBACJ,IAAI,EAAE,IAAI,CAAC,IAAI;oBACf,IAAI,EAAE,IAAI,CAAC,IAAI;iBAChB,CAAC,CAAA;YACJ,CAAC;YACD,SAAQ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AC;YACH,CAAC;iBAAM,IAAI,0BAA0B,EAAE,CAAC;gBACtC,IAAI,CAAC,WAAW,CAAC,IAAK,CAAC,IAAI,EAAE,UAAU,EAAE,WAAW,CAAC,CAAA;YACvD,CAAC;iBAAM,IAAI,uBAAuB,EAAE,CAAC;gBACnC,IAAI,CAAC,WAAW,CAAC,IAAK,CAAC,IAAI,EAAE,OAAO,EAAE,WAAW,CAAC,CAAA;YACpD,CAAC;iBAAM,IAAI,EAAE,CAAC,sBAAsB,CAAC,WAAW,CAAC,EAAE,CAAC;gBAClD,IAAI,CAAC,WAAW,CAAC,IAAI,CAAC,IAAI,EAAE,MAAM,EAAE,WAAW,CAAC,CAAA;YAClD,CAAC;iBAAM,IAAI,EAAE,CAAC,sBAAsB,CAAC,WAAW,CAAC,EAAE,CAAC;gBAClD,IAAI,CAAC,WAAW,CAAC,IAAI,CAAC,IAAI,EAAE,WAAW,EAAE,WAAW,CAAC,CAAA;YACvD,CAAC;QACH,CAAC;IACH,CAAC;IAED,OAAO,WAAW,CAAA;AACpB,CAAC,CAAA;AAvDY,QAAA,gBAAgB,oBAuD5B"}
@@ -0,0 +1,2 @@
1
+ export { scanFixtureFiles } from './scan-fixture-files';
2
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/assessments/fixture-files/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,gBAAgB,EAAE,MAAM,sBAAsB,CAAA"}
@@ -0,0 +1,6 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.scanFixtureFiles = void 0;
4
+ var scan_fixture_files_1 = require("./scan-fixture-files");
5
+ Object.defineProperty(exports, "scanFixtureFiles", { enumerable: true, get: function () { return scan_fixture_files_1.scanFixtureFiles; } });
6
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/assessments/fixture-files/index.ts"],"names":[],"mappings":";;;AAAA,2DAAuD;AAA9C,sHAAA,gBAAgB,OAAA"}
@@ -0,0 +1,3 @@
1
+ import { ScannedRow } from '../scanned-row';
2
+ export declare const scanFixtureFiles: (files: string[]) => ScannedRow[];
3
+ //# sourceMappingURL=scan-fixture-files.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"scan-fixture-files.d.ts","sourceRoot":"","sources":["../../../src/assessments/fixture-files/scan-fixture-files.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,UAAU,EAAE,MAAM,gBAAgB,CAAA;AAE3C,eAAO,MAAM,gBAAgB,GAAI,OAAO,MAAM,EAAE,KAAG,UAAU,EAO5D,CAAA"}
@@ -0,0 +1,15 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.scanFixtureFiles = void 0;
4
+ const pano_dm_1 = require("@fyuld/pano-dm");
5
+ const scanFixtureFiles = (files) => {
6
+ const occurrences = [];
7
+ for (const file of files) {
8
+ if (!file.toLowerCase().includes('fixture'))
9
+ continue;
10
+ occurrences.push({ file, line: pano_dm_1.NotApplicable });
11
+ }
12
+ return occurrences;
13
+ };
14
+ exports.scanFixtureFiles = scanFixtureFiles;
15
+ //# sourceMappingURL=scan-fixture-files.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"scan-fixture-files.js","sourceRoot":"","sources":["../../../src/assessments/fixture-files/scan-fixture-files.ts"],"names":[],"mappings":";;;AAAA,4CAA8C;AAGvC,MAAM,gBAAgB,GAAG,CAAC,KAAe,EAAgB,EAAE;IAChE,MAAM,WAAW,GAAiB,EAAE,CAAA;IACpC,KAAK,MAAM,IAAI,IAAI,KAAK,EAAE,CAAC;QACzB,IAAI,CAAC,IAAI,CAAC,WAAW,EAAE,CAAC,QAAQ,CAAC,SAAS,CAAC;YAAE,SAAQ;QACrD,WAAW,CAAC,IAAI,CAAC,EAAE,IAAI,EAAE,IAAI,EAAE,uBAAa,EAAE,CAAC,CAAA;IACjD,CAAC;IACD,OAAO,WAAW,CAAA;AACpB,CAAC,CAAA;AAPY,QAAA,gBAAgB,oBAO5B"}
@@ -0,0 +1,2 @@
1
+ export { scanIndexFiles } from './scan-index-files';
2
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/assessments/index-files/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,cAAc,EAAE,MAAM,oBAAoB,CAAA"}
@@ -0,0 +1,6 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.scanIndexFiles = void 0;
4
+ var scan_index_files_1 = require("./scan-index-files");
5
+ Object.defineProperty(exports, "scanIndexFiles", { enumerable: true, get: function () { return scan_index_files_1.scanIndexFiles; } });
6
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/assessments/index-files/index.ts"],"names":[],"mappings":";;;AAAA,uDAAmD;AAA1C,kHAAA,cAAc,OAAA"}
@@ -0,0 +1,3 @@
1
+ import { ScannedRow } from '../scanned-row';
2
+ export declare const scanIndexFiles: (files: string[]) => ScannedRow[];
3
+ //# sourceMappingURL=scan-index-files.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"scan-index-files.d.ts","sourceRoot":"","sources":["../../../src/assessments/index-files/scan-index-files.ts"],"names":[],"mappings":"AAMA,OAAO,EAAE,UAAU,EAAE,MAAM,gBAAgB,CAAA;AAoC3C,eAAO,MAAM,cAAc,GAAI,OAAO,MAAM,EAAE,KAAG,UAAU,EAa1D,CAAA"}
@@ -33,59 +33,54 @@ var __importStar = (this && this.__importStar) || (function () {
33
33
  };
34
34
  })();
35
35
  Object.defineProperty(exports, "__esModule", { value: true });
36
- exports.runIndexFilesAssessment = void 0;
36
+ exports.scanIndexFiles = void 0;
37
37
  const fs = __importStar(require("fs"));
38
38
  const path = __importStar(require("path"));
39
39
  const ts = __importStar(require("typescript"));
40
+ const pano_dm_1 = require("@fyuld/pano-dm");
41
+ const ldm_1 = require("@fyuld/ldm");
40
42
  const typescript_1 = require("../../languages/typescript");
41
- const countImpureStatements = (sourceFile) => {
42
- let n = 0;
43
- for (const stmt of sourceFile.statements) {
44
- if (!ts.isExportDeclaration(stmt))
45
- n++;
46
- }
47
- return n;
43
+ const hasExportModifier = (stmt) => {
44
+ const mods = stmt.modifiers;
45
+ return mods?.some((m) => m.kind === ts.SyntaxKind.ExportKeyword) ?? false;
48
46
  };
49
- const renderJson = (report) => JSON.stringify(report, null, 2) + '\n';
50
- const renderCsv = (entries) => [
51
- 'file,impureStatementCount',
52
- ...entries.map((e) => `${e.file},${e.impureStatementCount}`),
53
- ].join('\n') + '\n';
54
- const writeReport = (report, formats, outDir) => {
55
- fs.mkdirSync(outDir, { recursive: true });
56
- for (const format of formats) {
57
- const f = format;
58
- if (f === 'Json') {
59
- fs.writeFileSync(path.join(outDir, 'index-files.json'), renderJson(report));
60
- }
61
- else if (f === 'Csv') {
62
- fs.writeFileSync(path.join(outDir, 'index-files.csv'), renderCsv(report.violations));
63
- }
64
- else {
65
- throw new Error(`Unknown assessment format: ${f}`);
66
- }
47
+ const isDefinition = (stmt) => ts.isClassDeclaration(stmt) ||
48
+ ts.isFunctionDeclaration(stmt) ||
49
+ ts.isInterfaceDeclaration(stmt) ||
50
+ ts.isTypeAliasDeclaration(stmt) ||
51
+ ts.isEnumDeclaration(stmt) ||
52
+ ts.isVariableStatement(stmt);
53
+ const countStatements = (sourceFile) => {
54
+ let imports = 0;
55
+ let reExports = 0;
56
+ let exports = 0;
57
+ let declarations = 0;
58
+ for (const stmt of sourceFile.statements) {
59
+ if (ts.isImportDeclaration(stmt))
60
+ imports++;
61
+ if (ts.isExportDeclaration(stmt))
62
+ reExports++;
63
+ if (hasExportModifier(stmt))
64
+ exports++;
65
+ if (isDefinition(stmt))
66
+ declarations++;
67
67
  }
68
+ return { imports, reExports, exports, declarations };
68
69
  };
69
- const runIndexFilesAssessment = (files, formats, outDir) => {
70
- const violations = [];
71
- let totalIndexFiles = 0;
70
+ const scanIndexFiles = (files) => {
71
+ const occurrences = [];
72
72
  for (const file of files) {
73
73
  if (path.basename(file) !== 'index.ts')
74
74
  continue;
75
- totalIndexFiles++;
76
- const source = fs.readFileSync(file, 'utf-8');
75
+ const source = fs.readFileSync(file, ldm_1.FileFormat.Utf8);
77
76
  const sourceFile = (0, typescript_1.parseTypeScript)(source, file);
78
- const impureStatementCount = countImpureStatements(sourceFile);
79
- if (impureStatementCount > 0) {
80
- violations.push({
81
- file: path.relative(process.cwd(), file),
82
- impureStatementCount,
83
- });
84
- }
77
+ occurrences.push({
78
+ file,
79
+ line: pano_dm_1.NotApplicable,
80
+ ...countStatements(sourceFile),
81
+ });
85
82
  }
86
- const report = { totalIndexFiles, violations };
87
- writeReport(report, formats, outDir);
88
- return { report };
83
+ return occurrences;
89
84
  };
90
- exports.runIndexFilesAssessment = runIndexFilesAssessment;
91
- //# sourceMappingURL=index.js.map
85
+ exports.scanIndexFiles = scanIndexFiles;
86
+ //# sourceMappingURL=scan-index-files.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"scan-index-files.js","sourceRoot":"","sources":["../../../src/assessments/index-files/scan-index-files.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,uCAAwB;AACxB,2CAA4B;AAC5B,+CAAgC;AAChC,4CAA8C;AAC9C,oCAAuC;AACvC,2DAA4D;AAG5D,MAAM,iBAAiB,GAAG,CAAC,IAAkB,EAAW,EAAE;IACxD,MAAM,IAAI,GAAI,IAAmD,CAAC,SAAS,CAAA;IAC3E,OAAO,IAAI,EAAE,IAAI,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC,IAAI,KAAK,EAAE,CAAC,UAAU,CAAC,aAAa,CAAC,IAAI,KAAK,CAAA;AAC3E,CAAC,CAAA;AAED,MAAM,YAAY,GAAG,CAAC,IAA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AAM,UAAU,GAAG,IAAA,4BAAe,EAAC,MAAM,EAAE,IAAI,CAAC,CAAA;QAChD,WAAW,CAAC,IAAI,CAAC;YACf,IAAI;YACJ,IAAI,EAAE,uBAAa;YACnB,GAAG,eAAe,CAAC,UAAU,CAAC;SAC/B,CAAC,CAAA;IACJ,CAAC;IACD,OAAO,WAAW,CAAA;AACpB,CAAC,CAAA;AAbY,QAAA,cAAc,kBAa1B"}
@@ -0,0 +1,7 @@
1
+ import { NotApplicable } from '@fyuld/pano-dm';
2
+ export type ScannedRow = {
3
+ file: string;
4
+ line: number | NotApplicable;
5
+ [key: string]: unknown;
6
+ };
7
+ //# sourceMappingURL=scanned-row.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"scanned-row.d.ts","sourceRoot":"","sources":["../../src/assessments/scanned-row.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAE,MAAM,gBAAgB,CAAA;AAE9C,MAAM,MAAM,UAAU,GAAG;IACvB,IAAI,EAAE,MAAM,CAAA;IACZ,IAAI,EAAE,MAAM,GAAG,aAAa,CAAA;IAC5B,CAAC,GAAG,EAAE,MAAM,GAAG,OAAO,CAAA;CACvB,CAAA"}
@@ -0,0 +1,3 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ //# sourceMappingURL=scanned-row.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"scanned-row.js","sourceRoot":"","sources":["../../src/assessments/scanned-row.ts"],"names":[],"mappings":""}
@@ -0,0 +1,3 @@
1
+ import { Occurrence, Finding } from '@fyuld/pano-dm';
2
+ export declare const findDuplicateStringLiterals: (occurrences: Occurrence[]) => Finding[];
3
+ //# sourceMappingURL=find-duplicate-string-literals.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"find-duplicate-string-literals.d.ts","sourceRoot":"","sources":["../../../src/assessments/string-literals/find-duplicate-string-literals.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,OAAO,EAAE,MAAM,gBAAgB,CAAA;AAEpD,eAAO,MAAM,2BAA2B,GACtC,aAAa,UAAU,EAAE,KACxB,OAAO,EAUT,CAAA"}
@@ -0,0 +1,16 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.findDuplicateStringLiterals = void 0;
4
+ const findDuplicateStringLiterals = (occurrences) => {
5
+ const counts = new Map();
6
+ for (const o of occurrences) {
7
+ const v = o.value;
8
+ counts.set(v, (counts.get(v) ?? 0) + 1);
9
+ }
10
+ return occurrences
11
+ .filter((o) => (counts.get(o.value) ?? 0) > 1)
12
+ .map((o) => ({ ...o, numUsed: counts.get(o.value) }))
13
+ .sort((a, b) => a.value.localeCompare(b.value));
14
+ };
15
+ exports.findDuplicateStringLiterals = findDuplicateStringLiterals;
16
+ //# sourceMappingURL=find-duplicate-string-literals.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"find-duplicate-string-literals.js","sourceRoot":"","sources":["../../../src/assessments/string-literals/find-duplicate-string-literals.ts"],"names":[],"mappings":";;;AAEO,MAAM,2BAA2B,GAAG,CACzC,WAAyB,EACd,EAAE;IACb,MAAM,MAAM,GAAG,IAAI,GAAG,EAAkB,CAAA;IACxC,KAAK,MAAM,CAAC,IAAI,WAAW,EAAE,CAAC;QAC5B,MAAM,CAAC,GAAG,CAAC,CAAC,KAAe,CAAA;QAC3B,MAAM,CAAC,GAAG,CAAC,CAAC,EAAE,CAAC,MAAM,CAAC,GAAG,CAAC,CAAC,CAAC,IAAI,CAAC,CAAC,GAAG,CAAC,CAAC,CAAA;IACzC,CAAC;IACD,OAAO,WAAW;SACf,MAAM,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,MAAM,CAAC,GAAG,CAAC,CAAC,CAAC,KAAe,CAAC,IAAI,CAAC,CAAC,GAAG,CAAC,CAAC;SACvD,GAAG,CAAC,CAAC,CAAC,EAAW,EAAE,CAAC,CAAC,EAAE,GAAG,CAAC,EAAE,OAAO,EAAE,MAAM,CAAC,GAAG,CAAC,CAAC,CAAC,KAAe,CAAC,EAAE,CAAC,CAAC;SACvE,IAAI,CAAC,CAAC,CAAC,EAAE,CAAC,EAAE,EAAE,CAAE,CAAC,CAAC,KAAgB,CAAC,aAAa,CAAC,CAAC,CAAC,KAAe,CAAC,CAAC,CAAA;AACzE,CAAC,CAAA;AAZY,QAAA,2BAA2B,+BAYvC"}
@@ -0,0 +1,3 @@
1
+ export { scanStringLiterals } from './scan-string-literals';
2
+ export { findDuplicateStringLiterals } from './find-duplicate-string-literals';
3
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/assessments/string-literals/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,kBAAkB,EAAE,MAAM,wBAAwB,CAAA;AAC3D,OAAO,EAAE,2BAA2B,EAAE,MAAM,kCAAkC,CAAA"}
@@ -0,0 +1,8 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.findDuplicateStringLiterals = exports.scanStringLiterals = void 0;
4
+ var scan_string_literals_1 = require("./scan-string-literals");
5
+ Object.defineProperty(exports, "scanStringLiterals", { enumerable: true, get: function () { return scan_string_literals_1.scanStringLiterals; } });
6
+ var find_duplicate_string_literals_1 = require("./find-duplicate-string-literals");
7
+ Object.defineProperty(exports, "findDuplicateStringLiterals", { enumerable: true, get: function () { return find_duplicate_string_literals_1.findDuplicateStringLiterals; } });
8
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/assessments/string-literals/index.ts"],"names":[],"mappings":";;;AAAA,+DAA2D;AAAlD,0HAAA,kBAAkB,OAAA;AAC3B,mFAA8E;AAArE,6IAAA,2BAA2B,OAAA"}
@@ -0,0 +1,3 @@
1
+ import { ScannedRow } from '../scanned-row';
2
+ export declare const scanStringLiterals: (files: string[]) => ScannedRow[];
3
+ //# sourceMappingURL=scan-string-literals.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"scan-string-literals.d.ts","sourceRoot":"","sources":["../../../src/assessments/string-literals/scan-string-literals.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,UAAU,EAAE,MAAM,gBAAgB,CAAA;AAgC3C,eAAO,MAAM,kBAAkB,GAAI,OAAO,MAAM,EAAE,KAAG,UAAU,EAqF9D,CAAA"}
@@ -0,0 +1,131 @@
1
+ "use strict";
2
+ var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
3
+ if (k2 === undefined) k2 = k;
4
+ var desc = Object.getOwnPropertyDescriptor(m, k);
5
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
6
+ desc = { enumerable: true, get: function() { return m[k]; } };
7
+ }
8
+ Object.defineProperty(o, k2, desc);
9
+ }) : (function(o, m, k, k2) {
10
+ if (k2 === undefined) k2 = k;
11
+ o[k2] = m[k];
12
+ }));
13
+ var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
14
+ Object.defineProperty(o, "default", { enumerable: true, value: v });
15
+ }) : function(o, v) {
16
+ o["default"] = v;
17
+ });
18
+ var __importStar = (this && this.__importStar) || (function () {
19
+ var ownKeys = function(o) {
20
+ ownKeys = Object.getOwnPropertyNames || function (o) {
21
+ var ar = [];
22
+ for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
23
+ return ar;
24
+ };
25
+ return ownKeys(o);
26
+ };
27
+ return function (mod) {
28
+ if (mod && mod.__esModule) return mod;
29
+ var result = {};
30
+ if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
31
+ __setModuleDefault(result, mod);
32
+ return result;
33
+ };
34
+ })();
35
+ Object.defineProperty(exports, "__esModule", { value: true });
36
+ exports.scanStringLiterals = void 0;
37
+ const fs = __importStar(require("fs"));
38
+ const ts = __importStar(require("typescript"));
39
+ const ldm_1 = require("@fyuld/ldm");
40
+ const typescript_1 = require("../../languages/typescript");
41
+ const terraform_1 = require("../../languages/terraform");
42
+ const BDD_PREDEFINED_EXCEPTIONS = new Set(['Given', 'When', 'Then', 'And']);
43
+ const UTILITARY_PREDEFINED_EXCEPTIONS = new Set(['\n', '\\n']);
44
+ const isLiteral = (node) => ts.isStringLiteral(node);
45
+ const isPredefinedException = (value) => value.length <= 1 ||
46
+ BDD_PREDEFINED_EXCEPTIONS.has(value) ||
47
+ UTILITARY_PREDEFINED_EXCEPTIONS.has(value);
48
+ const isDuplicableStringLiteral = (node) => isLiteral(node) && !isPredefinedException(node.text);
49
+ const isDuplicableNamedDeclaration = (node) => (ts.isVariableDeclaration(node) || ts.isParameter(node)) &&
50
+ ts.isIdentifier(node.name) &&
51
+ node.initializer !== undefined &&
52
+ isDuplicableStringLiteral(node.initializer);
53
+ const literalValue = (node) => `'${node.text}'`;
54
+ const scanStringLiterals = (files) => {
55
+ const occurrences = [];
56
+ const JS_EXTENSIONS = new Set(['.ts', '.tsx', '.js']);
57
+ for (const file of files) {
58
+ const ext = file.slice(file.lastIndexOf('.'));
59
+ const source = fs.readFileSync(file, ldm_1.FileFormat.Utf8);
60
+ if (ext === '.tf') {
61
+ for (const lit of (0, terraform_1.parseTerraformStringLiterals)(source)) {
62
+ if (!isPredefinedException(lit.value)) {
63
+ occurrences.push({
64
+ value: `'${lit.value}'`,
65
+ name: lit.name,
66
+ type: 'string',
67
+ length: lit.value.length,
68
+ usage: 'variable',
69
+ file,
70
+ line: lit.line,
71
+ code: lit.code,
72
+ });
73
+ }
74
+ }
75
+ continue;
76
+ }
77
+ if (!JS_EXTENSIONS.has(ext))
78
+ continue;
79
+ const sourceFile = (0, typescript_1.parseTypeScript)(source, file);
80
+ const lines = source.split('\n');
81
+ const lineOf = (node) => sourceFile.getLineAndCharacterOfPosition(node.getStart(sourceFile)).line +
82
+ 1;
83
+ const codeAt = (line) => (lines[line - 1] ?? '').trim();
84
+ const visit = (node) => {
85
+ if (isDuplicableNamedDeclaration(node)) {
86
+ const usage = ts.isParameter(node) ? 'default' : 'variable';
87
+ const line = lineOf(node.initializer);
88
+ occurrences.push({
89
+ value: literalValue(node.initializer),
90
+ name: node.name.text,
91
+ type: 'string',
92
+ length: node.initializer.text.length,
93
+ usage,
94
+ file,
95
+ line,
96
+ code: codeAt(line),
97
+ });
98
+ }
99
+ else if (ts.isCallExpression(node)) {
100
+ const callee = node.expression;
101
+ const name = ts.isPropertyAccessExpression(callee)
102
+ ? callee.name.text
103
+ : ts.isIdentifier(callee)
104
+ ? callee.text
105
+ : undefined;
106
+ if (name) {
107
+ for (const arg of node.arguments) {
108
+ if (isDuplicableStringLiteral(arg)) {
109
+ const line = lineOf(arg);
110
+ occurrences.push({
111
+ value: literalValue(arg),
112
+ name,
113
+ type: 'string',
114
+ length: arg.text.length,
115
+ usage: 'function',
116
+ file,
117
+ line,
118
+ code: codeAt(line),
119
+ });
120
+ }
121
+ }
122
+ }
123
+ }
124
+ ts.forEachChild(node, visit);
125
+ };
126
+ visit(sourceFile);
127
+ }
128
+ return occurrences;
129
+ };
130
+ exports.scanStringLiterals = scanStringLiterals;
131
+ //# sourceMappingURL=scan-string-literals.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"scan-string-literals.js","sourceRoot":"","sources":["../../../src/assessments/string-literals/scan-string-literals.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,uCAAwB;AACxB,+CAAgC;AAEhC,oCAAuC;AACvC,2DAA4D;AAC5D,yDAAwE;AAExE,MAAM,yBAAyB,GAAG,IAAI,GAAG,CAAC,CAAC,OAAO,EAAE,MAAM,EAAE,MAAM,EAAE,KAAK,CAAC,CAAC,CAAA;AAC3E,MAAM,+BAA+B,GAAG,IAAI,GAAG,CAAC,CAAC,IAAI,EAAE,KAAK,CAAC,CAAC,CAAA;AAE9D,MAAM,SAAS,GAAG,CAAC,IAAa,EAA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AC;oBACH,CAAC;gBACH,CAAC;YACH,CAAC;YAED,EAAE,CAAC,YAAY,CAAC,IAAI,EAAE,KAAK,CAAC,CAAA;QAC9B,CAAC,CAAA;QAED,KAAK,CAAC,UAAU,CAAC,CAAA;IACnB,CAAC;IAED,OAAO,WAAW,CAAA;AACpB,CAAC,CAAA;AArFY,QAAA,kBAAkB,sBAqF9B"}
@@ -0,0 +1,11 @@
1
+ export * from './languages/typescript';
2
+ export * from './languages/gherkin';
3
+ export * from './languages/terraform';
4
+ export * from './assessments/collect-occurrences';
5
+ export * from './assessments/collect-findings';
6
+ export * from './principles/evaluate-constraint';
7
+ export * from './principles/render-remarks';
8
+ export * from './principles/run-principles';
9
+ export * from './principles/violation-to-be-renamed-to-remark';
10
+ export * from './render';
11
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,cAAc,wBAAwB,CAAA;AACtC,cAAc,qBAAqB,CAAA;AACnC,cAAc,uBAAuB,CAAA;AACrC,cAAc,mCAAmC,CAAA;AACjD,cAAc,gCAAgC,CAAA;AAC9C,cAAc,kCAAkC,CAAA;AAChD,cAAc,6BAA6B,CAAA;AAC3C,cAAc,6BAA6B,CAAA;AAC3C,cAAc,gDAAgD,CAAA;AAC9D,cAAc,UAAU,CAAA"}
@@ -0,0 +1,27 @@
1
+ "use strict";
2
+ var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
3
+ if (k2 === undefined) k2 = k;
4
+ var desc = Object.getOwnPropertyDescriptor(m, k);
5
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
6
+ desc = { enumerable: true, get: function() { return m[k]; } };
7
+ }
8
+ Object.defineProperty(o, k2, desc);
9
+ }) : (function(o, m, k, k2) {
10
+ if (k2 === undefined) k2 = k;
11
+ o[k2] = m[k];
12
+ }));
13
+ var __exportStar = (this && this.__exportStar) || function(m, exports) {
14
+ for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
15
+ };
16
+ Object.defineProperty(exports, "__esModule", { value: true });
17
+ __exportStar(require("./languages/typescript"), exports);
18
+ __exportStar(require("./languages/gherkin"), exports);
19
+ __exportStar(require("./languages/terraform"), exports);
20
+ __exportStar(require("./assessments/collect-occurrences"), exports);
21
+ __exportStar(require("./assessments/collect-findings"), exports);
22
+ __exportStar(require("./principles/evaluate-constraint"), exports);
23
+ __exportStar(require("./principles/render-remarks"), exports);
24
+ __exportStar(require("./principles/run-principles"), exports);
25
+ __exportStar(require("./principles/violation-to-be-renamed-to-remark"), exports);
26
+ __exportStar(require("./render"), exports);
27
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,yDAAsC;AACtC,sDAAmC;AACnC,wDAAqC;AACrC,oEAAiD;AACjD,iEAA8C;AAC9C,mEAAgD;AAChD,8DAA2C;AAC3C,8DAA2C;AAC3C,iFAA8D;AAC9D,2CAAwB"}
@@ -0,0 +1,3 @@
1
+ export { parseTerraformDeclarations, parseTerraformStringLiterals, } from './parser';
2
+ export type { TerraformDeclaration, TerraformStringLiteral } from './parser';
3
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/languages/terraform/index.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,0BAA0B,EAC1B,4BAA4B,GAC7B,MAAM,UAAU,CAAA;AACjB,YAAY,EAAE,oBAAoB,EAAE,sBAAsB,EAAE,MAAM,UAAU,CAAA"}