nukadoko 0.5.0 → 0.7.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (203) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGELOG.md +553 -3
  3. data/README.ja.md +22 -6
  4. data/README.md +13 -7
  5. data/docs/ci.ja.md +542 -0
  6. data/docs/ci.md +635 -0
  7. data/docs/commands.ja.md +1524 -0
  8. data/docs/commands.md +1281 -0
  9. data/docs/engines.json +19 -0
  10. data/docs/execution-events.ja.md +336 -0
  11. data/docs/execution-events.md +423 -0
  12. data/docs/glossary.json +1348 -0
  13. data/docs/guide.ja.md +733 -0
  14. data/docs/guide.md +815 -0
  15. data/docs/intent.ja.md +133 -0
  16. data/docs/intent.md +156 -0
  17. data/docs/layout.ja.md +442 -0
  18. data/docs/layout.md +399 -0
  19. data/docs/releasing.ja.md +186 -0
  20. data/docs/releasing.md +237 -0
  21. data/docs/ruby/reference.ja.md +302 -0
  22. data/docs/ruby/reference.md +368 -0
  23. data/docs/spec.ja.md +8916 -0
  24. data/docs/spec.md +11250 -0
  25. data/docs/tutorial.ja.md +451 -0
  26. data/docs/tutorial.md +458 -0
  27. data/docs/typescript/adopting.ja.md +231 -0
  28. data/docs/typescript/adopting.md +251 -0
  29. data/docs/typescript/doors.ja.md +301 -0
  30. data/docs/typescript/doors.md +329 -0
  31. data/docs/typescript/migration-playwright-test.ja.md +189 -0
  32. data/docs/typescript/migration-playwright-test.md +212 -0
  33. data/docs/typescript/migration.ja.md +391 -0
  34. data/docs/typescript/migration.md +505 -0
  35. data/docs/typescript/reference.ja.md +176 -0
  36. data/docs/typescript/reference.md +197 -0
  37. data/docs/typescript/upgrading.ja.md +1774 -0
  38. data/docs/typescript/upgrading.md +2224 -0
  39. data/docs/web-app.ja.md +627 -0
  40. data/docs/web-app.md +659 -0
  41. data/docs/writing-scenarios.ja.md +544 -0
  42. data/docs/writing-scenarios.md +563 -0
  43. data/lib/nukadoko/base.rb +12 -5
  44. data/lib/nukadoko/changed_files.rb +95 -0
  45. data/lib/nukadoko/check.rb +459 -51
  46. data/lib/nukadoko/claim_drops.rb +271 -0
  47. data/lib/nukadoko/claim_line.rb +24 -4
  48. data/lib/nukadoko/claim_rules.rb +143 -1
  49. data/lib/nukadoko/claim_sides.rb +157 -9
  50. data/lib/nukadoko/cli.rb +403 -50
  51. data/lib/nukadoko/codes.json +246 -21
  52. data/lib/nukadoko/codes.rb +21 -4
  53. data/lib/nukadoko/command.rb +120 -13
  54. data/lib/nukadoko/command_help.rb +128 -0
  55. data/lib/nukadoko/compat.rb +469 -0
  56. data/lib/nukadoko/criteria.rb +1 -1
  57. data/lib/nukadoko/definition.rb +157 -7
  58. data/lib/nukadoko/error_frames.rb +6 -3
  59. data/lib/nukadoko/events/count.rb +146 -0
  60. data/lib/nukadoko/events/counted.rb +114 -0
  61. data/lib/nukadoko/events/format.rb +257 -0
  62. data/lib/nukadoko/events/lists.rb +154 -0
  63. data/lib/nukadoko/events/path.rb +285 -0
  64. data/lib/nukadoko/events/read.rb +284 -0
  65. data/lib/nukadoko/events/reader.rb +490 -0
  66. data/lib/nukadoko/events/selection.rb +252 -0
  67. data/lib/nukadoko/events/tally.rb +438 -0
  68. data/lib/nukadoko/features.rb +2 -2
  69. data/lib/nukadoko/fixtures.rb +160 -35
  70. data/lib/nukadoko/http_recording.rb +6 -2
  71. data/lib/nukadoko/intent.rb +364 -0
  72. data/lib/nukadoko/intent_file.rb +81 -0
  73. data/lib/nukadoko/intent_view.rb +190 -0
  74. data/lib/nukadoko/js_json.rb +2 -1
  75. data/lib/nukadoko/judge.rb +2 -2
  76. data/lib/nukadoko/judgment_file.rb +22 -1
  77. data/lib/nukadoko/judgments.rb +33 -3
  78. data/lib/nukadoko/measure_mcp.rb +202 -0
  79. data/lib/nukadoko/parts.rb +8 -2
  80. data/lib/nukadoko/path_view.rb +252 -0
  81. data/lib/nukadoko/place_rows.rb +161 -0
  82. data/lib/nukadoko/program.rb +1265 -51
  83. data/lib/nukadoko/program_log.rb +122 -0
  84. data/lib/nukadoko/program_shape.rb +385 -0
  85. data/lib/nukadoko/project_fixtures.rb +43 -10
  86. data/lib/nukadoko/project_program.rb +5 -4
  87. data/lib/nukadoko/repeated_prefix.rb +310 -0
  88. data/lib/nukadoko/report_run.rb +3 -3
  89. data/lib/nukadoko/run.rb +1156 -159
  90. data/lib/nukadoko/run_record.rb +70 -46
  91. data/lib/nukadoko/scaffold.rb +24 -6
  92. data/lib/nukadoko/schema.rb +15 -2
  93. data/lib/nukadoko/secrets.rb +55 -5
  94. data/lib/nukadoko/states.rb +478 -0
  95. data/lib/nukadoko/step.rb +71 -2
  96. data/lib/nukadoko/step_fixtures.rb +52 -3
  97. data/lib/nukadoko/summary.rb +803 -30
  98. data/lib/nukadoko/table.rb +4 -2
  99. data/lib/nukadoko/text_fit.rb +20 -7
  100. data/lib/nukadoko/trace.rb +152 -45
  101. data/lib/nukadoko/tree_passes.rb +95 -33
  102. data/lib/nukadoko/underneath.rb +311 -0
  103. data/lib/nukadoko/verdict.rb +18 -1
  104. data/lib/nukadoko/version.rb +1 -1
  105. data/lib/nukadoko/vocabulary.rb +166 -23
  106. data/lib/nukadoko/walk.rb +2 -2
  107. data/lib/nukadoko/walk_step.rb +1 -1
  108. data/lib/nukadoko.rb +23 -0
  109. data/llms.txt +42 -35
  110. data/sig/generated/nukadoko/base.rbs +4 -4
  111. data/sig/generated/nukadoko/changed_files.rbs +42 -0
  112. data/sig/generated/nukadoko/check.rbs +147 -10
  113. data/sig/generated/nukadoko/claim_drops.rbs +135 -0
  114. data/sig/generated/nukadoko/claim_line.rbs +11 -0
  115. data/sig/generated/nukadoko/claim_rules.rbs +49 -4
  116. data/sig/generated/nukadoko/claim_sides.rbs +63 -12
  117. data/sig/generated/nukadoko/cli.rbs +80 -7
  118. data/sig/generated/nukadoko/codes.rbs +19 -4
  119. data/sig/generated/nukadoko/command.rbs +68 -1
  120. data/sig/generated/nukadoko/command_help.rbs +18 -0
  121. data/sig/generated/nukadoko/compat.rbs +392 -0
  122. data/sig/generated/nukadoko/criteria.rbs +1 -1
  123. data/sig/generated/nukadoko/definition.rbs +50 -0
  124. data/sig/generated/nukadoko/error_frames.rbs +1 -1
  125. data/sig/generated/nukadoko/events/count.rbs +69 -0
  126. data/sig/generated/nukadoko/events/counted.rbs +70 -0
  127. data/sig/generated/nukadoko/events/format.rbs +163 -0
  128. data/sig/generated/nukadoko/events/lists.rbs +47 -0
  129. data/sig/generated/nukadoko/events/path.rbs +161 -0
  130. data/sig/generated/nukadoko/events/read.rbs +109 -0
  131. data/sig/generated/nukadoko/events/reader.rbs +226 -0
  132. data/sig/generated/nukadoko/events/selection.rbs +100 -0
  133. data/sig/generated/nukadoko/events/tally.rbs +227 -0
  134. data/sig/generated/nukadoko/features.rbs +6 -4
  135. data/sig/generated/nukadoko/fixtures.rbs +67 -11
  136. data/sig/generated/nukadoko/http_recording.rbs +1 -1
  137. data/sig/generated/nukadoko/intent.rbs +132 -0
  138. data/sig/generated/nukadoko/intent_file.rbs +46 -0
  139. data/sig/generated/nukadoko/intent_view.rbs +69 -0
  140. data/sig/generated/nukadoko/judgment_file.rbs +7 -1
  141. data/sig/generated/nukadoko/judgments.rbs +10 -0
  142. data/sig/generated/nukadoko/measure_mcp.rbs +104 -0
  143. data/sig/generated/nukadoko/parts.rbs +2 -2
  144. data/sig/generated/nukadoko/path_view.rbs +105 -0
  145. data/sig/generated/nukadoko/place_rows.rbs +43 -0
  146. data/sig/generated/nukadoko/program.rbs +627 -23
  147. data/sig/generated/nukadoko/program_log.rbs +67 -0
  148. data/sig/generated/nukadoko/program_shape.rbs +147 -0
  149. data/sig/generated/nukadoko/project_fixtures.rbs +16 -3
  150. data/sig/generated/nukadoko/project_program.rbs +2 -1
  151. data/sig/generated/nukadoko/repeated_prefix.rbs +172 -0
  152. data/sig/generated/nukadoko/report_run.rbs +1 -1
  153. data/sig/generated/nukadoko/run.rbs +286 -41
  154. data/sig/generated/nukadoko/run_record.rbs +20 -12
  155. data/sig/generated/nukadoko/scaffold.rbs +3 -0
  156. data/sig/generated/nukadoko/schema.rbs +5 -0
  157. data/sig/generated/nukadoko/secrets.rbs +26 -3
  158. data/sig/generated/nukadoko/states.rbs +214 -0
  159. data/sig/generated/nukadoko/step.rbs +58 -1
  160. data/sig/generated/nukadoko/step_fixtures.rbs +39 -0
  161. data/sig/generated/nukadoko/summary.rbs +256 -2
  162. data/sig/generated/nukadoko/table.rbs +3 -2
  163. data/sig/generated/nukadoko/trace.rbs +108 -33
  164. data/sig/generated/nukadoko/tree_passes.rbs +36 -8
  165. data/sig/generated/nukadoko/underneath.rbs +141 -0
  166. data/sig/generated/nukadoko/verdict.rbs +8 -0
  167. data/sig/generated/nukadoko/vocabulary.rbs +45 -6
  168. data/skills/nukadoko/SKILL.md +18 -18
  169. data/skills/nukadoko/references/checking-steps.md +16 -83
  170. data/skills/nukadoko/references/diagnosing.md +6 -6
  171. data/skills/nukadoko/references/done.md +22 -0
  172. data/skills/nukadoko/references/evidence.md +19 -6
  173. data/skills/nukadoko/references/exploring.md +22 -7
  174. data/skills/nukadoko/references/fixtures.md +12 -32
  175. data/skills/nukadoko/references/judgments.md +18 -0
  176. data/skills/nukadoko/references/maintenance.md +1 -1
  177. data/skills/nukadoko/references/merge-risk.md +1 -1
  178. data/skills/nukadoko/references/parts.md +46 -23
  179. data/skills/nukadoko/references/{perturbed-worlds.md → perturbed-systems.md} +30 -12
  180. data/skills/nukadoko/references/program.md +168 -169
  181. data/skills/nukadoko/references/reviewing.md +20 -20
  182. data/skills/nukadoko/references/ruby/checking-steps.md +106 -0
  183. data/skills/nukadoko/references/ruby/examples/cli.md +212 -0
  184. data/skills/nukadoko/references/ruby/fixtures.md +34 -0
  185. data/skills/nukadoko/references/ruby/program.md +112 -0
  186. data/skills/nukadoko/references/ruby/step-files.md +115 -0
  187. data/skills/nukadoko/references/running.md +34 -34
  188. data/skills/nukadoko/references/scenario-rules.md +7 -6
  189. data/skills/nukadoko/references/states.md +7 -1
  190. data/skills/nukadoko/references/step-files.md +41 -120
  191. data/skills/nukadoko/references/typescript/checking-steps.md +129 -0
  192. data/skills/nukadoko/references/{examples → typescript/examples}/cli.md +1 -1
  193. data/skills/nukadoko/references/{examples → typescript/examples}/http-api.md +6 -6
  194. data/skills/nukadoko/references/{examples → typescript/examples}/workflow.md +1 -1
  195. data/skills/nukadoko/references/typescript/fixtures.md +56 -0
  196. data/skills/nukadoko/references/typescript/program.md +111 -0
  197. data/skills/nukadoko/references/typescript/step-files.md +104 -0
  198. data/skills/nukadoko/references/verdicts.md +10 -10
  199. data/skills/nukadoko/references/writing-steps.md +67 -67
  200. data/skills/nukadoko/references/writing-the-feature.md +1 -1
  201. data/skills/nukadoko-verification/SKILL.md +13 -8
  202. metadata +103 -7
  203. data/skills/nukadoko/references/ruby.md +0 -80
@@ -0,0 +1,105 @@
1
+ # Generated from lib/nukadoko/path_view.rb with RBS::Inline
2
+
3
+ # Responsibility: run.json's `paths` (docs/spec.md "Execution events"):
4
+ # for each pair of sides the run can compare, what each criterion's steps
5
+ # did differently on one side than on the other, as their paths say
6
+ # (events/path.rb), so a person about to turn a change on for everyone
7
+ # reads what changed in what the program did. Pure: it reads run.json's
8
+ # own fields and nothing else. Boundary: a path, and the range a count on
9
+ # it lies in, are events/path.rb's; the cells and their outcomes are the
10
+ # table's; this module adds no verdict.
11
+ #
12
+ # A pair is two sides of one criterion. Under `nuka run --base`, each
13
+ # environment's base system is paired with its head system, for the rows
14
+ # whose head cell there is required and ran. Otherwise it is two head
15
+ # environments whose declared `conditions` differ in exactly one
16
+ # condition. Steps align by their line in head's feature file, and a
17
+ # criterion whose two step lists differ is not compared. A side is read
18
+ # from its cell's first execution, since repeats and proof runs add more.
19
+ #
20
+ # Two counts are the same when both are exact and equal, changed when
21
+ # their ranges cannot meet, and open otherwise: a count a side's missing
22
+ # lines could still reach never reads as a change. A criterion whose every
23
+ # open count reads the same on both sides, under the same gap words, is
24
+ # `same_so_far`. In a pair of environments, a flag's side differing is the
25
+ # switch the pair was made to compare, so a kind PATH_KINDS marks as the
26
+ # premise is never among what changed. Against the base, it is compared as
27
+ # any kind is.
28
+ #
29
+ # A write to a table the tables list marks is compared too, and its
30
+ # difference carries what the table holds. A criterion's `result` reads
31
+ # the other differences alone, and one whose only differences are on
32
+ # marked tables is `marked_only`, never `same`: something did differ.
33
+ #
34
+ # Against the base, a changed criterion says what accounts for it: on a
35
+ # new or changed criterion, the new sentences a person approves; on an
36
+ # unchanged one, nothing in the feature files, which is the one a reader
37
+ # is sent to first.
38
+ module Nukadoko
39
+ module Engine
40
+ module PathView
41
+ RESULTS: untyped
42
+
43
+ # One comparison per pair of sides the run can compare: each base
44
+ # pair, then each pair of environments, in the run's order of
45
+ # environments; [] when there is none.
46
+ # : (Hash[Symbol, untyped]) -> Array[Hash[Symbol, untyped]]
47
+ def self?.compare: (Hash[Symbol, untyped]) -> Array[Hash[Symbol, untyped]]
48
+
49
+ # : (Hash[Symbol, untyped]) -> Array[Hash[Symbol, untyped]]
50
+ def self?.base_pairs: (Hash[Symbol, untyped]) -> Array[Hash[Symbol, untyped]]
51
+
52
+ # Every two environments whose declared conditions differ in exactly
53
+ # one: side `a` holds false or no value where `b` holds true, and
54
+ # otherwise the earlier environment.
55
+ # : (Array[Hash[Symbol, untyped]]) -> Array[Hash[Symbol, untyped]]
56
+ def self?.condition_pairs: (Array[Hash[Symbol, untyped]]) -> Array[Hash[Symbol, untyped]]
57
+
58
+ # Whether a side's system read its events: "read", "none" when no
59
+ # base system started in the environment, or why it gave no paths.
60
+ # : (Hash[Symbol, untyped], Hash[Symbol, untyped]) -> (String | Hash[Symbol, String])
61
+ def self?.reading_of: (Hash[Symbol, untyped], Hash[Symbol, untyped]) -> (String | Hash[Symbol, String])
62
+
63
+ # : (Hash[Symbol, untyped], Hash[Symbol, untyped]) -> String
64
+ def self?.side_where: (Hash[Symbol, untyped], Hash[Symbol, untyped]) -> String
65
+
66
+ # A side's first execution of a row, with what its cell came to, or
67
+ # what it came to itself when the base ran it for paths alone.
68
+ # : (Hash[Symbol, untyped], Hash[Symbol, untyped], Hash[Symbol, untyped]) -> Hash[Symbol, untyped]?
69
+ def self?.side_of: (Hash[Symbol, untyped], Hash[Symbol, untyped], Hash[Symbol, untyped]) -> Hash[Symbol, untyped]?
70
+
71
+ # : (Hash[Symbol, untyped], Hash[Symbol, untyped]) -> bool
72
+ def self?.pair_compares?: (Hash[Symbol, untyped], Hash[Symbol, untyped]) -> bool
73
+
74
+ # : (Hash[Symbol, untyped]) -> bool
75
+ def self?.exact?: (Hash[Symbol, untyped]) -> bool
76
+
77
+ # : (Hash[Symbol, untyped], Hash[Symbol, untyped]) -> bool
78
+ def self?.apart?: (Hash[Symbol, untyped], Hash[Symbol, untyped]) -> bool
79
+
80
+ # : (Array[Hash[Symbol, untyped]]) -> Array[String]
81
+ def self?.gap_words: (Array[Hash[Symbol, untyped]]) -> Array[String]
82
+
83
+ # : (Array[Hash[Symbol, untyped]]) -> Array[Hash[Symbol, untyped]]
84
+ def self?.unmarked: (Array[Hash[Symbol, untyped]]) -> Array[Hash[Symbol, untyped]]
85
+
86
+ # : (Hash[Symbol, untyped]) -> bool
87
+ def self?.same_so_far?: (Hash[Symbol, untyped]) -> bool
88
+
89
+ # A path as events/path.rb reads it, from run.json's own shape or
90
+ # from one read back with symbol keys: entries and requests keyed by
91
+ # strings, gaps by symbols.
92
+ # : (Hash[Symbol, untyped]) -> Hash[Symbol, untyped]
93
+ def self?.path_of: (Hash[Symbol, untyped]) -> Hash[Symbol, untyped]
94
+
95
+ # : (Hash[Symbol, untyped], Hash[Symbol, untyped], ^(String) -> bool) -> Hash[Symbol, untyped]
96
+ def self?.step_difference: (Hash[Symbol, untyped], Hash[Symbol, untyped], ^(String) -> bool) -> Hash[Symbol, untyped]
97
+
98
+ # : (Hash[Symbol, untyped], Hash[Symbol, untyped], Array[Hash[Symbol, untyped]], ^(String) -> bool) -> Hash[Symbol, untyped]
99
+ def self?.compare_criterion: (Hash[Symbol, untyped], Hash[Symbol, untyped], Array[Hash[Symbol, untyped]], ^(String) -> bool) -> Hash[Symbol, untyped]
100
+
101
+ # : (Hash[Symbol, untyped], Hash[Symbol, untyped]) -> Hash[Symbol, untyped]?
102
+ def self?.compare_pair: (Hash[Symbol, untyped], Hash[Symbol, untyped]) -> Hash[Symbol, untyped]?
103
+ end
104
+ end
105
+ end
@@ -0,0 +1,43 @@
1
+ # Generated from lib/nukadoko/place_rows.rb with RBS::Inline
2
+
3
+ module Nukadoko
4
+ module Engine
5
+ module PlaceRows
6
+ COUNTED: untyped
7
+
8
+ # Each place the head executions' visits reached, by key, in the order
9
+ # of its first visit: its criteria in the table's row order, each with
10
+ # its head cells there in the table's column order. `visits` gives an
11
+ # execution's visits as [key, place, detail]; `cell_of` what a cell
12
+ # holds beyond the table's fields, from its visits' details.
13
+ # : (Array[Hash[Symbol, untyped]], Array[Hash[Symbol, untyped]], ^(Hash[Symbol, untyped]) -> Array[[String, untyped, untyped]], ^(Array[untyped]) -> Hash[Symbol, untyped]) -> Hash[String, Hash[Symbol, untyped]]
14
+ def self?.criteria_by_place: (Array[Hash[Symbol, untyped]], Array[Hash[Symbol, untyped]], ^(Hash[Symbol, untyped]) -> Array[[ String, untyped, untyped ]], ^(Array[untyped]) -> Hash[Symbol, untyped]) -> Hash[String, Hash[Symbol, untyped]]
15
+
16
+ # : (Array[Hash[Symbol, untyped]]) -> Hash[Symbol, Integer]
17
+ def self?.counts_of: (Array[Hash[Symbol, untyped]]) -> Hash[Symbol, Integer]
18
+
19
+ # : (Hash[Symbol, untyped]) -> Array[Hash[String, untyped]]
20
+ def self?.paths_of: (Hash[Symbol, untyped]) -> Array[Hash[String, untyped]]
21
+
22
+ # : (String?, String, String) -> String
23
+ def self?.flag_key: (String?, String, String) -> String
24
+
25
+ # One row per service, flag, and side the head paths' flag entries
26
+ # name, and per side a read flags list declares, by service, then
27
+ # flag name, then side. Each service of the system evaluates its own
28
+ # flags, so a row is one (service, name, side): two services can hold
29
+ # a flag of the same name and decide it apart. A read flags list is
30
+ # the primary service's, so the sides it declares are rows of that
31
+ # service, which `listed` names beside each environment.
32
+ # : (Array[Hash[Symbol, untyped]], Array[Hash[Symbol, untyped]], ?Array[Hash[Symbol, untyped]]) -> Array[Hash[Symbol, untyped]]
33
+ def self?.flag_rows: (Array[Hash[Symbol, untyped]], Array[Hash[Symbol, untyped]], ?Array[Hash[Symbol, untyped]]) -> Array[Hash[Symbol, untyped]]
34
+
35
+ # One entry per method and route a head system's routes list or a head
36
+ # step's request line names, by route (a route no line matched last),
37
+ # then by method. `listed` is each environment whose routes list was
38
+ # read, in the run's order.
39
+ # : (Array[Hash[Symbol, untyped]], Array[Hash[Symbol, untyped]], Array[Hash[Symbol, untyped]]) -> Array[Hash[Symbol, untyped]]
40
+ def self?.route_rows: (Array[Hash[Symbol, untyped]], Array[Hash[Symbol, untyped]], Array[Hash[Symbol, untyped]]) -> Array[Hash[Symbol, untyped]]
41
+ end
42
+ end
43
+ end