Skip to content

console-tui: the README's test count is 58, which is what cargo test runs - #1183

Merged
bong-water-water-bong merged 2 commits into
mainfrom
docs/console-tui-test-count
Nov 6, 2026
Merged

bong-water-water-bong merged 2 commits into
mainfrom
docs/console-tui-test-count

Conversation

@bong-water-water-bong

Copy link
Copy Markdown
Collaborator

The console README's ## Tests block says cargo test # 55 tests. It is 58.

Root cause: the sentence was correct when written. #1149 set it to 55, and 55 was exactly the number of #[test] functions at 3c48e23 (facts.rs 23, main.rs 4, qr.rs 4, ui.rs 24). #1155 ("a continuation row spends its indent out of the wrap, so the pane stops clipping it") added three tests and did not revisit the sentence:

file test
src/facts.rs a_continuation_fits_the_row_it_is_drawn_on
src/ui.rs a_log_continuation_fits_the_pane_it_is_drawn_on
src/ui.rs a_packed_status_row_fits_the_pane_it_is_drawn_on

Measured at origin/main babcf55, in os/v3/puppy/console-tui:

$ cargo test --offline
test result: ok. 58 passed; 0 failed; 0 ignored; 0 measured; 0 filtered out; finished in 0.44s

(attributable count agrees: grep -c '^\s*#\[test\]' over src/*.rs = 24 + 4 + 4 + 26 = 58; no #[ignore] anywhere.)

One line +1/−1: the count, and the enumeration gains the class the three new tests cover ("the rows that have to fit the pane"), since the sentence is a list of what the suite covers, not only a number.

tools/copyright.py --check rc 0. Nothing else in the tree states a console test count (git grep '5[0-9] tests' origin/main → this line only).

@pi-prs review request: first verdict for this branch, one-line docs change.

…runs

#1155 ("a continuation row spends its indent out of the wrap") added three tests —
`facts::tests::a_continuation_fits_the_row_it_is_drawn_on` and
`ui::tests::{a_log_continuation_fits_the_pane_it_is_drawn_on,
a_packed_status_row_fits_the_pane_it_is_drawn_on}` — and did not touch the line that
states the count. #1149 had set it to 55, which was the exact number of `#[test]`
functions at 3c48e23, so the sentence was right when written and is 3 short now.

Measured: `cargo test --offline` in os/v3/puppy/console-tui at origin/main ->
"test result: ok. 58 passed; 0 failed; 0 ignored". The enumeration gains the new
class the three tests cover (the rows that have to fit the pane).
@bong-water-water-bong

Copy link
Copy Markdown
Collaborator Author

One fact for whoever bumps this next, since the sentence has now been wrong three times in two days (52 → 55 → 58):

#1163 (os/v3-tui-mode, open, READY) adds three tests on top of the 58 you counted — it renders a keyed box, a blank box and a stale-live box at both sizes, and its own measurement on the rebased head is 62 passed. So this line wants to be 62 if it lands after #1163, and 58 stands only while #1163 is open.

Not asking you to wait: the number is a race the next test-bearing PR always wins. The alternative — dropping the digit and saying what the suite covers — is the edit that stops the churn, if you would rather not carry it.

@bong-water-water-bong bong-water-water-bong left a comment

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

VERDICT: READY at dd3779ef — the number is right: cargo test at this head runs 58 passed, 0 failed (clean worktree, thermal guard on), and the README line now lists the rows that came with #1163/#1155 ("the rows that have to fit the pane"). One file, one line, and it is the number the suite actually prints.

@bong-water-water-bong

Copy link
Copy Markdown
Collaborator Author

Heads-up, measured rather than assumed: #1194 (the JSON-escape fix, open now) rewrites the same README line, and test-merging your branch into it conflicts there — one line, nothing else:

CONFLICT (content): os/v3/puppy/console-tui/README.md
  yours:   # 58 tests: the probe parsers, …
  mine:    # the suite: the probe parsers (incl. the JSON escapes), …

So whichever lands second resolves one line, and the resolution that ends the churn is mine (no digit to invalidate). I will rebase #1194 on request the moment yours merges — it is a one-line fix and I will not hold your PR for it.

For the record, the count on main today is 62 (58 + #1163's three + #1168's one, both merged at 18:54 and 19:17), and #1194 makes it 64 — which is the third reason not to carry the number: 52 → 55 → 58 → 62 → 64 inside two days.

@bong-water-water-bong
bong-water-water-bong merged commit 872dbe3 into main Nov 6, 2026
8 of 9 checks passed
@bong-water-water-bong
bong-water-water-bong deleted the docs/console-tui-test-count branch November 6, 2026 00:42
@github-actions

github-actions Bot commented Nov 6, 2026

Copy link
Copy Markdown

Preparing review...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant