branchproof 0.2.0 → 0.4.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.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: c5027104f6aeb6181f75ccc463ef93d6cf78489ba28e8c6824308d13546a5586
4
- data.tar.gz: 442f07bf0dc87e1f3ed5bcc371d130da1612afd91f69837f8869b81fdf7c95f6
3
+ metadata.gz: a76f20e6504affb4e614eeca901b0ef515f8bbb0785a641cf437263cac2df418
4
+ data.tar.gz: 87373206990831eeba3c1a2317049a4679343b4e4770015fb3e322710c7035e9
5
5
  SHA512:
6
- metadata.gz: 707ca0fff8681d36f7a0e635513c3914ed403ddaf0e96c1ddec646574abee54daf50e60f05c16a79d2b522a7f568a09ee99da3807161dd471646291442f80323
7
- data.tar.gz: 3c446a3c71dd5a89cc0f12fa77ef61ef96a339a81bffd744dad86db4d2d7044f28c34a294342b29868b2ed848be1892892d8e28eff29f4e55f9b72a4ee57be62
6
+ metadata.gz: 97b1aca56ec2e2ed60f683e7647ce91ec85f3b8a2bbe457cf6844b0bd7db9b6117a126bce8ec74f04e4805dc147beef6b58fa003f74d73bd6e18884973115833
7
+ data.tar.gz: 1aac59c7cc767f9ef805cdcfecbe8e5e6628e25ea09cc8d862b32b0518f9aad89f6f8204b69d4183c75af1938e94a61e3ba980f6fa396bbff542b464bf371896
data/CHANGELOG.md CHANGED
@@ -1,5 +1,23 @@
1
1
  ## [Unreleased]
2
2
 
3
+ ## [0.4.0] - 2026-09-10
4
+
5
+ - Added `branchproof` as the primary CLI command while retaining `mcdc` as a
6
+ compatibility alias.
7
+ - Added condition-focused and test-focused terminal views, including relative
8
+ source locations, evaluated and short-circuited observations, and analyzer
9
+ witness ownership.
10
+ - Added opt-in saved JSON reports, offline rendering, and exact-condition
11
+ comparisons with gained/lost proof and changed-source context.
12
+ - Added `--fail-on-regression` comparison status handling and documented the
13
+ local `.branchproof/` artifact directory and explicit baseline workflow.
14
+
15
+ ## [0.3.0] - 2026-09-10
16
+
17
+ - Add `--missing-only` to focus terminal reports on unproven conditions.
18
+ - Explain missing observations with required truth values and comparison tests.
19
+ - Fix incorrect `INFEASIBLE_IN_MODEL` results caused by missing source identifiers.
20
+
3
21
  ## [0.2.0] - 2026-09-09
4
22
 
5
23
  - Prepared the initial public-release candidate.
data/LICENSE ADDED
@@ -0,0 +1,201 @@
1
+ Apache License
2
+ Version 2.0, January 2004
3
+ http://www.apache.org/licenses/
4
+
5
+ TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
6
+
7
+ 1. Definitions.
8
+
9
+ "License" shall mean the terms and conditions for use, reproduction,
10
+ and distribution as defined by Sections 1 through 9 of this document.
11
+
12
+ "Licensor" shall mean the copyright owner or entity authorized by
13
+ the copyright owner that is granting the License.
14
+
15
+ "Legal Entity" shall mean the union of the acting entity and all
16
+ other entities that control, are controlled by, or are under common
17
+ control with that entity. For the purposes of this definition,
18
+ "control" means (i) the power, direct or indirect, to cause the
19
+ direction or management of such entity, whether by contract or
20
+ otherwise, or (ii) ownership of fifty percent (50%) or more of the
21
+ outstanding shares, or (iii) beneficial ownership of such entity.
22
+
23
+ "You" (or "Your") shall mean an individual or Legal Entity
24
+ exercising permissions granted by this License.
25
+
26
+ "Source" form shall mean the preferred form for making modifications,
27
+ including but not limited to software source code, documentation
28
+ source, and configuration files.
29
+
30
+ "Object" form shall mean any form resulting from mechanical
31
+ transformation or translation of a Source form, including but
32
+ not limited to compiled object code, generated documentation,
33
+ and conversions to other media types.
34
+
35
+ "Work" shall mean the work of authorship, whether in Source or
36
+ Object form, made available under the License, as indicated by a
37
+ copyright notice that is included in or attached to the work
38
+ (an example is provided in the Appendix below).
39
+
40
+ "Derivative Works" shall mean any work, whether in Source or Object
41
+ form, that is based on (or derived from) the Work and for which the
42
+ editorial revisions, annotations, elaborations, or other modifications
43
+ represent, as a whole, an original work of authorship. For the purposes
44
+ of this License, Derivative Works shall not include works that remain
45
+ separable from, or merely link (or bind by name) to the interfaces of,
46
+ the Work and Derivative Works thereof.
47
+
48
+ "Contribution" shall mean any work of authorship, including
49
+ the original version of the Work and any modifications or additions
50
+ to that Work or Derivative Works thereof, that is intentionally
51
+ submitted to Licensor for inclusion in the Work by the copyright owner
52
+ or by an individual or Legal Entity authorized to submit on behalf of
53
+ the copyright owner. For the purposes of this definition, "submitted"
54
+ means any form of electronic, verbal, or written communication sent
55
+ to the Licensor or its representatives, including but not limited to
56
+ communication on electronic mailing lists, source code control systems,
57
+ and issue tracking systems that are managed by, or on behalf of, the
58
+ Licensor for the purpose of discussing and improving the Work, but
59
+ excluding communication that is conspicuously marked or otherwise
60
+ designated in writing by the copyright owner as "Not a Contribution."
61
+
62
+ "Contributor" shall mean Licensor and any individual or Legal Entity
63
+ on behalf of whom a Contribution has been received by Licensor and
64
+ subsequently incorporated within the Work.
65
+
66
+ 2. Grant of Copyright License. Subject to the terms and conditions of
67
+ this License, each Contributor hereby grants to You a perpetual,
68
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
69
+ copyright license to reproduce, prepare Derivative Works of,
70
+ publicly display, publicly perform, sublicense, and distribute the
71
+ Work and such Derivative Works in Source or Object form.
72
+
73
+ 3. Grant of Patent License. Subject to the terms and conditions of
74
+ this License, each Contributor hereby grants to You a perpetual,
75
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
76
+ (except as stated in this section) patent license to make, have made,
77
+ use, offer to sell, sell, import, and otherwise transfer the Work,
78
+ where such license applies only to those patent claims licensable
79
+ by such Contributor that are necessarily infringed by their
80
+ Contribution(s) alone or by combination of their Contribution(s)
81
+ with the Work to which such Contribution(s) was submitted. If You
82
+ institute patent litigation against any entity (including a
83
+ cross-claim or counterclaim in a lawsuit) alleging that the Work
84
+ or a Contribution incorporated within the Work constitutes direct
85
+ or contributory patent infringement, then any patent licenses
86
+ granted to You under this License for that Work shall terminate
87
+ as of the date such litigation is filed.
88
+
89
+ 4. Redistribution. You may reproduce and distribute copies of the
90
+ Work or Derivative Works thereof in any medium, with or without
91
+ modifications, and in Source or Object form, provided that You
92
+ meet the following conditions:
93
+
94
+ (a) You must give any other recipients of the Work or
95
+ Derivative Works a copy of this License; and
96
+
97
+ (b) You must cause any modified files to carry prominent notices
98
+ stating that You changed the files; and
99
+
100
+ (c) You must retain, in the Source form of any Derivative Works
101
+ that You distribute, all copyright, patent, trademark, and
102
+ attribution notices from the Source form of the Work,
103
+ excluding those notices that do not pertain to any part of
104
+ the Derivative Works; and
105
+
106
+ (d) If the Work includes a "NOTICE" text file as part of its
107
+ distribution, then any Derivative Works that You distribute must
108
+ include a readable copy of the attribution notices contained
109
+ within such NOTICE file, excluding those notices that do not
110
+ pertain to any part of the Derivative Works, in at least one
111
+ of the following places: within a NOTICE text file distributed
112
+ as part of the Derivative Works; within the Source form or
113
+ documentation, if provided along with the Derivative Works; or,
114
+ within a display generated by the Derivative Works, if and
115
+ wherever such third-party notices normally appear. The contents
116
+ of the NOTICE file are for informational purposes only and
117
+ do not modify the License. You may add Your own attribution
118
+ notices within Derivative Works that You distribute, alongside
119
+ or as an addendum to the NOTICE text from the Work, provided
120
+ that such additional attribution notices cannot be construed
121
+ as modifying the License.
122
+
123
+ You may add Your own copyright statement to Your modifications and
124
+ may provide additional or different license terms and conditions
125
+ for use, reproduction, or distribution of Your modifications, or
126
+ for any such Derivative Works as a whole, provided Your use,
127
+ reproduction, and distribution of the Work otherwise complies with
128
+ the conditions stated in this License.
129
+
130
+ 5. Submission of Contributions. Unless You explicitly state otherwise,
131
+ any Contribution intentionally submitted for inclusion in the Work
132
+ by You to the Licensor shall be under the terms and conditions of
133
+ this License, without any additional terms or conditions.
134
+ Notwithstanding the above, nothing herein shall supersede or modify
135
+ the terms of any separate license agreement you may have executed
136
+ with Licensor regarding such Contributions.
137
+
138
+ 6. Trademarks. This License does not grant permission to use the trade
139
+ names, trademarks, service marks, or product names of the Licensor,
140
+ except as required for reasonable and customary use in describing the
141
+ origin of the Work and reproducing the content of the NOTICE file.
142
+
143
+ 7. Disclaimer of Warranty. Unless required by applicable law or
144
+ agreed to in writing, Licensor provides the Work (and each
145
+ Contributor provides its Contributions) on an "AS IS" BASIS,
146
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
147
+ implied, including, without limitation, any warranties or conditions
148
+ of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
149
+ PARTICULAR PURPOSE. You are solely responsible for determining the
150
+ appropriateness of using or redistributing the Work and assume any
151
+ risks associated with Your exercise of permissions under this License.
152
+
153
+ 8. Limitation of Liability. In no event and under no legal theory,
154
+ whether in tort (including negligence), contract, or otherwise,
155
+ unless required by applicable law (such as deliberate and grossly
156
+ negligent acts) or agreed to in writing, shall any Contributor be
157
+ liable to You for damages, including any direct, indirect, special,
158
+ incidental, or consequential damages of any character arising as a
159
+ result of this License or out of the use or inability to use the
160
+ Work (including but not limited to damages for loss of goodwill,
161
+ work stoppage, computer failure or malfunction, or any and all
162
+ other commercial damages or losses), even if such Contributor
163
+ has been advised of the possibility of such damages.
164
+
165
+ 9. Accepting Warranty or Additional Liability. While redistributing
166
+ the Work or Derivative Works thereof, You may choose to offer,
167
+ and charge a fee for, acceptance of support, warranty, indemnity,
168
+ or other liability obligations and/or rights consistent with this
169
+ License. However, in accepting such obligations, You may act only
170
+ on Your own behalf and on Your sole responsibility, not on behalf
171
+ of any other Contributor, and only if You agree to indemnify,
172
+ defend, and hold each Contributor harmless for any liability
173
+ incurred by, or claims asserted against, such Contributor by reason
174
+ of your accepting any such warranty or additional liability.
175
+
176
+ END OF TERMS AND CONDITIONS
177
+
178
+ APPENDIX: How to apply the Apache License to your work.
179
+
180
+ To apply the Apache License to your work, attach the following
181
+ boilerplate notice, with the fields enclosed by brackets "[]"
182
+ replaced with your own identifying information. (Don't include
183
+ the brackets!) The text should be enclosed in the appropriate
184
+ comment syntax for the file format. We also recommend that a
185
+ file or class name and description of purpose be included on the
186
+ same "printed page" as the copyright notice for easier
187
+ identification within third-party archives.
188
+
189
+ Copyright [yyyy] [name of copyright owner]
190
+
191
+ Licensed under the Apache License, Version 2.0 (the "License");
192
+ you may not use this file except in compliance with the License.
193
+ You may obtain a copy of the License at
194
+
195
+ http://www.apache.org/licenses/LICENSE-2.0
196
+
197
+ Unless required by applicable law or agreed to in writing, software
198
+ distributed under the License is distributed on an "AS IS" BASIS,
199
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
200
+ See the License for the specific language governing permissions and
201
+ limitations under the License.
data/README.md CHANGED
@@ -6,8 +6,8 @@ modifier, and ordinary ternary (`?:`) decisions, records observed vectors,
6
6
  and reports independence evidence, missing counterpart constraints, and
7
7
  smaller supporting test sets.
8
8
 
9
- The gem is named `branchproof`; its command and compatibility namespace are
10
- `mcdc` and `MCDC`.
9
+ The gem and primary command are named `branchproof`. The `mcdc` command and
10
+ `MCDC` namespace remain compatibility aliases with the same behavior.
11
11
 
12
12
  ## Installation
13
13
 
@@ -30,12 +30,12 @@ instead of being counted as coverage.
30
30
 
31
31
  ## Analyze a test run
32
32
 
33
- Run `mcdc analyze` with the source files or globs to inspect, followed by
33
+ Run `branchproof analyze` with the source files or globs to inspect, followed by
34
34
  options. A second `--` separates Branchproof options from arguments passed to
35
35
  Minitest unchanged:
36
36
 
37
37
  ```sh
38
- mcdc analyze 'lib/**/*.rb' --test 'test/**/*_test.rb' \
38
+ branchproof analyze 'lib/**/*.rb' --test 'test/**/*_test.rb' \
39
39
  --level 3 \
40
40
  --format terminal \
41
41
  --output tmp/branchproof.txt \
@@ -47,14 +47,14 @@ For a plain Ruby application, select the project policy explicitly when
47
47
  running from the application root:
48
48
 
49
49
  ```sh
50
- bundle exec mcdc analyze 'lib/**/*.rb' --project ruby --test 'test/**/*_test.rb'
50
+ bundle exec branchproof analyze 'lib/**/*.rb' --project ruby --test 'test/**/*_test.rb'
51
51
  ```
52
52
 
53
53
  For a Rails application, run the same command from the application root so
54
54
  the application's bundle and Rails version remain in effect:
55
55
 
56
56
  ```sh
57
- bundle exec mcdc analyze 'app/**/*.rb' --project rails --test 'test/**/*_test.rb'
57
+ bundle exec branchproof analyze 'app/**/*.rb' --project rails --test 'test/**/*_test.rb'
58
58
  ```
59
59
 
60
60
  For a project rooted at the current directory, `--project auto` is the
@@ -97,7 +97,7 @@ For example, running the contents of the small `decision.rb` /
97
97
  with the terminal format produces a summary like this:
98
98
 
99
99
  ```text
100
- Branchproof 0.2.0
100
+ Branchproof 0.4.0
101
101
  Tests: PASSED (3 tests, 0 failed, 0 skipped)
102
102
  MC/DC: 100.0% (2/2 conditions proven)
103
103
  Analysis: COMPLETE
@@ -126,6 +126,53 @@ Additional tests outside this MC/DC evidence set may improve coverage.
126
126
  The test execution still runs once for the selected level. Use `--format
127
127
  json` when a consumer needs the complete identifiers and versioned schema.
128
128
 
129
+ ### Find missing cases
130
+
131
+ Use `--missing-only` to focus the terminal report on conditions that still
132
+ lack independence evidence:
133
+
134
+ ```sh
135
+ bundle exec branchproof analyze 'lib/**/*.rb' --missing-only
136
+ ```
137
+
138
+ This keeps the overall summary and diagnostics, hides proven conditions and
139
+ supporting-set lists, and shows missing scenarios using the source expressions.
140
+ It works with levels 2 and 3 (the default). JSON remains the complete report;
141
+ `--missing-only` cannot be combined with `--format json` or `--level 1`.
142
+
143
+ For example, given this decision:
144
+
145
+ ```ruby
146
+ content && Instruction.installed?(content)
147
+ ```
148
+
149
+ Observing `[TT]` and `[F-]` proves the effect of `content`, but does not prove
150
+ the effect of `Instruction.installed?(content)`. The missing case is `[TF]`:
151
+ `content` must be truthy and `Instruction.installed?(content)` must be falsey,
152
+ making the decision false. The missing condition is presented as:
153
+
154
+ ```text
155
+ Condition 1: Instruction.installed?(content)
156
+ NOT_PROVEN — missing observation
157
+ Need an observation where:
158
+ content is truthy
159
+ Instruction.installed?(content) is falsey
160
+ Expected decision: false [TF]
161
+ ```
162
+
163
+ An existing file without the instruction block
164
+ may produce this case; the test must reach the reported line. The report
165
+ describes required truth values, not application inputs or guaranteed
166
+ reachable paths. In Ruby, only `false` and `nil` are falsey; an empty string
167
+ is truthy.
168
+
169
+ `NOT_PROVEN` means analysis ran but did not find the required pair of
170
+ observations. `NOT CALCULATED` means analysis was not available or was not
171
+ requested; check the test status and diagnostics before adding tests.
172
+ `Analysis: COMPLETE` means the analysis finished, not that every condition
173
+ was proven. Missing conditions may require new tests or changes to existing
174
+ test inputs; they do not by themselves prove a bug in the application.
175
+
129
176
  The levels select how much of the one-run result is displayed:
130
177
 
131
178
  * Level 1 reports observed vectors grouped by their raw decision outcomes.
@@ -138,6 +185,95 @@ test suite. A failed, unsupported, or incomplete run is reported with its
138
185
  status and diagnostics and cannot become a successful coverage result by
139
186
  changing the display level.
140
187
 
188
+ ### Focused condition and test views
189
+
190
+ Use `--view conditions` to group the report by condition. Each condition shows
191
+ its expression, decision, and project-relative source location with the
192
+ condition's own 1-based start line. The view separates tests that evaluated
193
+ the condition true or false from tests where it was short-circuited. Level 3
194
+ also shows the canonical witness observations selected by the analyzer and
195
+ their owning tests.
196
+
197
+ ```sh
198
+ bundle exec branchproof analyze 'lib/**/*.rb' --view conditions
199
+ bundle exec branchproof analyze 'lib/**/*.rb' --view conditions --missing-only
200
+ ```
201
+
202
+ Use `--view tests` to group the same evidence by test. Rows include each
203
+ exercised condition, its relative source location, observed values, and the
204
+ recorded `setup`, `body`, or `teardown` phases. Tests with no completed
205
+ condition observation remain visible, as do unattributed and unexecuted
206
+ conditions. A test that evaluates both Boolean values is evidence of execution;
207
+ it is a proof contributor only when the analyzer's independent witness pair
208
+ uses its observations.
209
+
210
+ `--view` changes terminal grouping and does not change instrumentation or test
211
+ execution. JSON output always contains the complete evidence document, so an
212
+ explicit view cannot be combined with `--format json`. The `mcdc` executable
213
+ accepts the same arguments for existing scripts.
214
+
215
+ ### Saved reports and offline comparison
216
+
217
+ Reports are saved only when requested. Create a local artifact directory and
218
+ write a complete JSON baseline with the existing atomic `--output` option:
219
+
220
+ ```sh
221
+ mkdir -p .branchproof
222
+ bundle exec branchproof analyze 'lib/**/*.rb' --format json \
223
+ --output .branchproof/baseline.json
224
+ bundle exec branchproof report .branchproof/baseline.json --view conditions
225
+ bundle exec branchproof report .branchproof/baseline.json --view tests
226
+ ```
227
+
228
+ The output's parent directory must already exist. Replacing a baseline is an
229
+ explicit `analyze --format json --output` operation; keep CI snapshots as
230
+ artifacts when you need to retain multiple runs.
231
+
232
+ The `report` command reads the saved document without loading the application
233
+ or running tests. It uses locations and metadata captured in the report, so
234
+ rendering remains useful after the original checkout has moved or been
235
+ removed. Level 1 reports observations; levels 2 and 3 require corresponding
236
+ analysis in the saved report. The repository ignores `.branchproof/`; choose a
237
+ different path and CI artifact policy when a project needs to retain reports.
238
+ Saved JSON includes existing raw metadata such as test names and expressions;
239
+ relative terminal labels do not mean every legacy JSON field is sanitized.
240
+
241
+ To compare two explicitly saved runs:
242
+
243
+ ```sh
244
+ bundle exec branchproof analyze 'lib/**/*.rb' --format json \
245
+ --output .branchproof/current.json
246
+ bundle exec branchproof compare .branchproof/baseline.json \
247
+ .branchproof/current.json
248
+ bundle exec branchproof compare .branchproof/baseline.json \
249
+ .branchproof/current.json --fail-on-regression
250
+ ```
251
+
252
+ Comparison matches exact condition identities from unchanged source files.
253
+ Changed source files, changed selection or runtime context, incomplete runs,
254
+ and legacy reports missing comparison metadata are reported as partial or
255
+ incomplete context rather than guessed regressions. The output distinguishes
256
+ gained proof, lost proof, changed sources, newly selected files, and files no
257
+ longer present in a report. Previous witness values and owner names are shown
258
+ for lost proof; an absent owner is described as `not observed in current run`,
259
+ not as a deleted test. A different test population under unchanged discovery
260
+ patterns is valid comparison context, and seed differences are disclosed.
261
+
262
+ `compare` exits 0 for a complete comparison, including one with coverage
263
+ changes; `--fail-on-regression` exits 1 when a complete comparable run loses
264
+ proof. Invalid input or an incomplete comparison exits 2, which takes
265
+ precedence. Reports are explicit snapshots: comparison never creates history,
266
+ promotes a baseline, or overwrites either input.
267
+
268
+ MC/DC has two related questions. Evaluation asks whether a condition was
269
+ observed with a value, including short-circuiting. Independent proof asks
270
+ whether the analyzer found a pair of observations where that condition changes
271
+ the decision outcome under the masking criterion. Other conditions may be
272
+ short-circuited or masked rather than fixed to the same observed values. For example,
273
+ `left && right` observed as `[TT]` and `[F-]` evaluates `right` once and
274
+ short-circuits it once, but does not prove `right`; `[TF]` is also required.
275
+ The condition and test views preserve that distinction.
276
+
141
277
  ### Supported conditional forms
142
278
 
143
279
  Ordinary Ruby ternaries use the same predicate instrumentation and `&&`/`||`
@@ -183,7 +319,7 @@ Everything after the argument separator is passed as individual arguments to
183
319
  the serial Minitest runner. This is useful for seeds and name filters:
184
320
 
185
321
  ```sh
186
- mcdc analyze 'lib/**/*.rb' --level 1 -- --seed 9001 -n /checkout/
322
+ branchproof analyze 'lib/**/*.rb' --level 1 -- --seed 9001 -n /checkout/
187
323
  ```
188
324
 
189
325
  The 0.2 release supports serial Minitest execution in plain Ruby projects and
@@ -0,0 +1,26 @@
1
+ # Class Branchproof::Comparison <a id="class-Branchproof-Comparison"></a>
2
+
3
+ | | |
4
+ | --- | --- |
5
+ | **Inherits** | Object |
6
+ | **Defined in** | lib/branchproof/comparison.rb |
7
+
8
+ Compares two complete report documents without loading or executing the
9
+ project.
10
+
11
+ ## Constants
12
+ ### `CRITERION_VERSION` <a id="constant-CRITERION_VERSION"></a> <a id="CRITERION_VERSION-constant"></a>
13
+ Not documented.
14
+
15
+ ### `SCHEMA_VERSION` <a id="constant-SCHEMA_VERSION"></a> <a id="SCHEMA_VERSION-constant"></a>
16
+ Not documented.
17
+
18
+ ### `SUPPORTED_REPORT_SCHEMAS` <a id="constant-SUPPORTED_REPORT_SCHEMAS"></a> <a id="SUPPORTED_REPORT_SCHEMAS-constant"></a>
19
+ Not documented.
20
+
21
+ ## Public Instance Methods
22
+ ### `call()` <a id="method-i-call"></a> <a id="call-instance_method"></a>
23
+ Not documented.
24
+
25
+ ### `initialize(before:, after:)` <a id="method-i-initialize"></a> <a id="initialize-instance_method"></a>
26
+ - **@return** [Comparison] a new instance of Comparison
@@ -0,0 +1,19 @@
1
+ # Class Branchproof::ComparisonReport <a id="class-Branchproof-ComparisonReport"></a>
2
+
3
+ | | |
4
+ | --- | --- |
5
+ | **Inherits** | Object |
6
+ | **Defined in** | lib/branchproof/comparison_report.rb |
7
+
8
+ Renders the offline document returned by Comparison.
9
+
10
+ ## Public Instance Methods
11
+ ### `exit_code(fail_on_regression: = false)` <a id="method-i-exit_code"></a> <a id="exit_code-instance_method"></a>
12
+ Not documented.
13
+
14
+ ### `initialize(document:)` <a id="method-i-initialize"></a> <a id="initialize-instance_method"></a>
15
+ - **@raise** [ArgumentError]
16
+ - **@return** [ComparisonReport] a new instance of ComparisonReport
17
+
18
+ ### `write(io:, format:)` <a id="method-i-write"></a> <a id="write-instance_method"></a>
19
+ - **@raise** [ArgumentError]
@@ -0,0 +1,19 @@
1
+ # Class Branchproof::CoverageIndex <a id="class-Branchproof-CoverageIndex"></a>
2
+
3
+ | | |
4
+ | --- | --- |
5
+ | **Inherits** | Object |
6
+ | **Defined in** | lib/branchproof/coverage_index.rb |
7
+
8
+ Derives condition- and test-oriented rows from one report document.
9
+
10
+ ## Attributes
11
+ ### `conditions` [R] <a id="attribute-i-conditions"></a> <a id="conditions-instance_method"></a>
12
+ Returns the value of attribute conditions.
13
+
14
+ ### `tests` [R] <a id="attribute-i-tests"></a> <a id="tests-instance_method"></a>
15
+ Returns the value of attribute tests.
16
+
17
+ ## Public Instance Methods
18
+ ### `initialize(document:)` <a id="method-i-initialize"></a> <a id="initialize-instance_method"></a>
19
+ - **@return** [CoverageIndex] a new instance of CoverageIndex
@@ -0,0 +1,16 @@
1
+ # Class Branchproof::FocusedReport <a id="class-Branchproof-FocusedReport"></a>
2
+
3
+ | | |
4
+ | --- | --- |
5
+ | **Inherits** | Object |
6
+ | **Defined in** | lib/branchproof/focused_report.rb |
7
+
8
+ Terminal renderings grouped around conditions or tests.
9
+
10
+ ## Public Instance Methods
11
+ ### `initialize(document:, view:, level:, missing_only: = false)` <a id="method-i-initialize"></a> <a id="initialize-instance_method"></a>
12
+ - **@raise** [ArgumentError]
13
+ - **@return** [FocusedReport] a new instance of FocusedReport
14
+
15
+ ### `render()` <a id="method-i-render"></a> <a id="render-instance_method"></a>
16
+ Not documented.
@@ -14,11 +14,18 @@ Not documented.
14
14
  ### `SCHEMA_VERSION` <a id="constant-SCHEMA_VERSION"></a> <a id="SCHEMA_VERSION-constant"></a>
15
15
  Not documented.
16
16
 
17
+ ## Public Class Methods
18
+ ### `from_document(document:, level: = nil, view: = :decisions, missing_only: = false)` <a id="method-c-from_document"></a> <a id="from_document-class_method"></a>
19
+ Not documented.
20
+
17
21
  ## Public Instance Methods
22
+ ### `condition_explanation(decision_id:, condition_id:)` <a id="method-i-condition_explanation"></a> <a id="condition_explanation-instance_method"></a>
23
+ Shares the existing missing-case wording with focused terminal views.
24
+
18
25
  ### `exit_code()` <a id="method-i-exit_code"></a> <a id="exit_code-instance_method"></a>
19
26
  Not documented.
20
27
 
21
- ### `initialize(inventory:, evidence:, analysis:, minima:, baseline:, diagnostics:, level: = 3)` <a id="method-i-initialize"></a> <a id="initialize-instance_method"></a>
28
+ ### `initialize(inventory:, evidence:, analysis:, minima:, baseline:, diagnostics:, level: = 3, missing_only: = false, view: = :decisions, run_metadata: = {}, saved_document: = nil)` <a id="method-i-initialize"></a> <a id="initialize-instance_method"></a>
22
29
  - **@raise** [ArgumentError]
23
30
  - **@return** [Report] a new instance of Report
24
31
 
@@ -0,0 +1,32 @@
1
+ # Class Branchproof::SavedReport <a id="class-Branchproof-SavedReport"></a>
2
+
3
+ | | |
4
+ | --- | --- |
5
+ | **Inherits** | Object |
6
+ | **Defined in** | lib/branchproof/saved_report.rb |
7
+
8
+ Reads and validates a persisted JSON report without loading the project.
9
+
10
+ ## Constants
11
+ ### `COMPLETENESS_FIELDS` <a id="constant-COMPLETENESS_FIELDS"></a> <a id="COMPLETENESS_FIELDS-constant"></a>
12
+ Not documented.
13
+
14
+ ### `CRITERION_VERSION` <a id="constant-CRITERION_VERSION"></a> <a id="CRITERION_VERSION-constant"></a>
15
+ Not documented.
16
+
17
+ ### `REQUIRED_FIELDS` <a id="constant-REQUIRED_FIELDS"></a> <a id="REQUIRED_FIELDS-constant"></a>
18
+ Not documented.
19
+
20
+ ### `SUPPORTED_SCHEMAS` <a id="constant-SUPPORTED_SCHEMAS"></a> <a id="SUPPORTED_SCHEMAS-constant"></a>
21
+ Not documented.
22
+
23
+ ## Public Class Methods
24
+ ### `read(path)` <a id="method-c-read"></a> <a id="read-class_method"></a>
25
+ Not documented.
26
+
27
+ ## Public Instance Methods
28
+ ### `initialize(document)` <a id="method-i-initialize"></a> <a id="initialize-instance_method"></a>
29
+ - **@return** [SavedReport] a new instance of SavedReport
30
+
31
+ ### `validate!()` <a id="method-i-validate-21"></a> <a id="validate!-instance_method"></a>
32
+ Not documented.
data/doc/Branchproof.md CHANGED
@@ -2,7 +2,7 @@
2
2
 
3
3
  | | |
4
4
  | --- | --- |
5
- | **Defined in** | lib/branchproof.rb, lib/branchproof/cli.rb, lib/branchproof/limits.rb, lib/branchproof/loader.rb, lib/branchproof/report.rb, lib/branchproof/source.rb, lib/branchproof/worker.rb, lib/branchproof/project.rb, lib/branchproof/records.rb, lib/branchproof/runtime.rb, lib/branchproof/version.rb, lib/branchproof/analyzer.rb, lib/branchproof/evidence.rb, lib/branchproof/minimizer.rb, lib/branchproof/instrumenter.rb, lib/branchproof/rails_support.rb, lib/branchproof/minitest_adapter.rb |
5
+ | **Defined in** | lib/branchproof.rb, lib/branchproof/cli.rb, lib/branchproof/limits.rb, lib/branchproof/loader.rb, lib/branchproof/report.rb, lib/branchproof/source.rb, lib/branchproof/worker.rb, lib/branchproof/project.rb, lib/branchproof/records.rb, lib/branchproof/runtime.rb, lib/branchproof/version.rb, lib/branchproof/analyzer.rb, lib/branchproof/evidence.rb, lib/branchproof/minimizer.rb, lib/branchproof/comparison.rb, lib/branchproof/instrumenter.rb, lib/branchproof/saved_report.rb, lib/branchproof/rails_support.rb, lib/branchproof/coverage_index.rb, lib/branchproof/focused_report.rb, lib/branchproof/minitest_adapter.rb, lib/branchproof/comparison_report.rb |
6
6
 
7
7
  Public namespace for source inventory and one-run MC/DC reporting.
8
8
 
@@ -14,8 +14,12 @@ Not documented.
14
14
 
15
15
  - [Branchproof/Analyzer.md](Branchproof/Analyzer.md)
16
16
  - [Branchproof/CLI.md](Branchproof/CLI.md)
17
+ - [Branchproof/Comparison.md](Branchproof/Comparison.md)
18
+ - [Branchproof/ComparisonReport.md](Branchproof/ComparisonReport.md)
19
+ - [Branchproof/CoverageIndex.md](Branchproof/CoverageIndex.md)
17
20
  - [Branchproof/Error.md](Branchproof/Error.md)
18
21
  - [Branchproof/Evidence.md](Branchproof/Evidence.md)
22
+ - [Branchproof/FocusedReport.md](Branchproof/FocusedReport.md)
19
23
  - [Branchproof/Instrumenter.md](Branchproof/Instrumenter.md)
20
24
  - [Branchproof/Limits.md](Branchproof/Limits.md)
21
25
  - [Branchproof/Loader.md](Branchproof/Loader.md)
@@ -27,6 +31,7 @@ Not documented.
27
31
  - [Branchproof/Records.md](Branchproof/Records.md)
28
32
  - [Branchproof/Report.md](Branchproof/Report.md)
29
33
  - [Branchproof/Runtime.md](Branchproof/Runtime.md)
34
+ - [Branchproof/SavedReport.md](Branchproof/SavedReport.md)
30
35
  - [Branchproof/Source.md](Branchproof/Source.md)
31
36
  - [Branchproof/Worker.md](Branchproof/Worker.md)
32
37
  - [CHANGELOG.md](CHANGELOG.md)
data/doc/CHANGELOG.md CHANGED
@@ -1,5 +1,23 @@
1
1
  ## [Unreleased]
2
2
 
3
+ ## [0.4.0] - 2026-09-10
4
+
5
+ - Added `branchproof` as the primary CLI command while retaining `mcdc` as a
6
+ compatibility alias.
7
+ - Added condition-focused and test-focused terminal views, including relative
8
+ source locations, evaluated and short-circuited observations, and analyzer
9
+ witness ownership.
10
+ - Added opt-in saved JSON reports, offline rendering, and exact-condition
11
+ comparisons with gained/lost proof and changed-source context.
12
+ - Added `--fail-on-regression` comparison status handling and documented the
13
+ local `.branchproof/` artifact directory and explicit baseline workflow.
14
+
15
+ ## [0.3.0] - 2026-09-10
16
+
17
+ - Add `--missing-only` to focus terminal reports on unproven conditions.
18
+ - Explain missing observations with required truth values and comparison tests.
19
+ - Fix incorrect `INFEASIBLE_IN_MODEL` results caused by missing source identifiers.
20
+
3
21
  ## [0.2.0] - 2026-09-09
4
22
 
5
23
  - Prepared the initial public-release candidate.