Skip to content

test(docs): stop leaning on README, CHANGELOG and guide prose; drop two unused modules - #4548

Merged
devswha merged 2 commits into
mainfrom
test/b3-prose-doc-pins
Nov 24, 2026
Merged

devswha merged 2 commits into
mainfrom
test/b3-prose-doc-pins

Conversation

@devswha

@devswha devswha commented Nov 23, 2026

Copy link
Copy Markdown
Owner

What

Test cleanup, bundle B3 of the test-suite plan: tests that leaned on prose and docs, and two modules nothing uses.

  • R1 scripts/install-ovis-command.test.ts: drop "does not promise that another ovis is never hidden". It only checked that CHANGELOG lacks a phrase and that the guide has a sentence; no code reads either. The guide's Uninstall command stays covered by running it (the test just above).
  • R2 src/lib/markdownHtml.test.ts: the parser test read the real README, so a README edit (logo path, width, links) could break a parser test. It now parses a README-shaped HTML header written in the test (centered logo with a width, <h1>, badges, a language row with a .md file link, a website link). Every parser assertion stays.
  • R3 src/lib/textPreview.test.ts: the "ordinary document of the load limit's size stays well under the Preview limit" check read the head of the real CHANGELOG, which changes every release. It now builds a changelog of the same size (release headings, wrapped list items with code and links). The first check (short list items past the limit) is unchanged.
  • R5 remove src/lib/koreanParticle.ts (and its test) and src/lib/account/deviceKey.ts: nothing imports them (registerSigningBytes lives in shared/account-records.ts, which src/lib/account/service.ts uses). src/lib/account/deviceKey.test.ts stays: it tests the account service path, not that file. The stale koreanParticle.test.ts entry leaves scripts/ci-test-timings.json.

No production behaviour or UI changes.

Evidence: the rewritten tests still fail when the parser breaks

Each mutation applied to the production file, the test file run, then the file restored byte for byte (git status clean afterwards).

Mutation Result
M1 shared/markdownHtml.ts:129 drops the image width reads a README's HTML header as centered markdown, never as tag text fails (1 fail, 5 pass)
M2 shared/markdownHtml.ts:86 reads .md links as plain text the README header test and links only to safe addresses and files fail (2 fail)
M3 src/lib/textPreview.ts counts one element per character of text puts a file of the load limit's short list items past what a Preview draws fails on the generated changelog (1 fail)

Validation

…sed modules

- install-ovis-command: drop the prose pin on CHANGELOG/guide wording
- markdownHtml: parse a README-shaped HTML header written in the test, not the real README
- textPreview: measure a same-size generated changelog, not the real CHANGELOG head
- remove src/lib/koreanParticle.ts (and its test) and src/lib/account/deviceKey.ts: nothing imports them
@coderabbitai

coderabbitai Bot commented Nov 23, 2026 •

Copy link
Copy Markdown

Explain Change →

Important

Review skipped

Auto incremental reviews are disabled on this repository.

Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

Run configuration

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • Trigger review

No actionable comments were generated in the recent review.

Summary

Summary by CodeRabbit

  • Tests
    • Updated content-parsing checks to use self-contained sample data rather than repository documents.
    • Removed checks for Korean particle selection and command-installation guidance.
  • Chores
    • No end-user-facing changes are described.

The PR removes two helper exports and related test content, removes an install-command documentation assertion, and changes parser tests to use inline or generated input instead of repository files.

Changes: Library helper removals

Layer / File(s) Summary
Remove device registration byte helper
src/lib/account/deviceKey.ts
Removes the registerSigningBytes export and its length-prefixed UTF-8 encoding.
Remove Korean particle helper
src/lib/koreanParticle.ts, src/lib/koreanParticle.test.ts, scripts/ci-test-timings.json
Removes objectParticle, its tests, and its timing entry.

Parser test inputs

Layer / File(s) Summary
Replace repository-file test input
src/lib/markdownHtml.test.ts, src/lib/textPreview.test.ts
The Markdown test uses an inline fixture. The text preview test generates changelog-like content and checks its parsed element estimate.

Install command test

Layer / File(s) Summary
Remove documentation assertion
scripts/install-ovis-command.test.ts
Removes the assertion about changelog wording and the guide’s ~/.local/bin PATH-order statement.

Estimated code review effort: 2 (Simple) | ~10 minutes

Change: Other

Possibly related PRs

  • devswha/ovis#3685: Changes the same changelog-based assertion in scripts/install-ovis-command.test.ts; the PR descriptions indicate that merge order determines whether the assertion remains.
Merge Risk: Minimal · previous review 60048

This cleanup changes tests and removes unused helpers without intended production behavior changes. No concrete merge-blocking risk was found. The pull request title should be updated to the required type(scope): summary format so the title check passes.

Pre-merge checks: Passed 4

Check name Status Explanation
Description check Passed The description follows the repository template's Change and Validation sections. The Change section describes the problem (tests reading README, CHANGELOG, and guide prose) and the resulting behavior…
Linked Issues check Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check Passed Check skipped because no linked issues were found for this pull request.
Title check Passed The title names test cleanup and removal of two unused modules. The changeset does that: it swaps README, CHANGELOG and guide dependencies for test fixtures and deletes koreanParticle and deviceKey. T…
Full details: Description check

Explanation

The description follows the repository template's Change and Validation sections. The Change section describes the problem (tests reading README, CHANGELOG, and guide prose) and the resulting behavior for each file, and it explains the module removals. The Validation section lists the commands run with results, mutation evidence, and the skipped lanes with reasons. The template asks for a linked issue for features only; this is a test cleanup, so no issue link is required. The template's changelog note (changelog.d/ entry) is not addressed. That is a minor gap, since the PR does not mention whether a changelog.d entry is needed for a test-only change.

Full details: Title check

Explanation

The title names test cleanup and removal of two unused modules. The changeset does that: it swaps README, CHANGELOG and guide dependencies for test fixtures and deletes koreanParticle and deviceKey. The title is specific and matches the main change, so it passes.

Finishing Touches

Generate unit tests (beta)

  • Commit to this branch
  • Create a new PR
Fix failing CI checks

  • Commit to this branch
  • Create a new PR
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

Share

Recent review info

Run configuration

Commits

Reviewing files that changed from the base of the PR and between 1d71a71 and 60048fa.

Files selected for processing: 7

  • scripts/ci-test-timings.json
  • scripts/install-ovis-command.test.ts
  • src/lib/account/deviceKey.ts
  • src/lib/koreanParticle.test.ts
  • src/lib/koreanParticle.ts
  • src/lib/markdownHtml.test.ts
  • src/lib/textPreview.test.ts
Files with no reviewable changes: 5

  • scripts/ci-test-timings.json
  • scripts/install-ovis-command.test.ts
  • src/lib/account/deviceKey.ts
  • src/lib/koreanParticle.test.ts
  • src/lib/koreanParticle.ts

Included review availability: This review used your included allowance. Your plan provides up to 8 included reviews per hour; 0 remain after this review.

@devswha devswha changed the title test: stop leaning on README, CHANGELOG and guide prose; drop two unused modules test(docs): stop leaning on README, CHANGELOG and guide prose; drop two unused modules Nov 23, 2026
@devswha
devswha merged commit b497f11 into main Nov 24, 2026
25 of 27 checks passed
@devswha

devswha commented Nov 24, 2026

Copy link
Copy Markdown
Owner Author

Merged through pr-merge at head 478f8827f. Seen before the merge was asked for: required checks green, no unresolved thread, no conflict, no hold, main not red, no release in progress. CodeRabbit said it did not review (a limit or a skip) since this head.

Test-only cleanup plus two unused modules removed. Reviews that ran: CodeRabbit reviewed the first head (no comments); a gate review by omo-native-gate-reviewer (APPROVE, re-ran the three parser mutations). The newest head adds only a merge of origin/main, which CodeRabbit skipped. The one Integration failure (server/relay/service.contract.test.ts handshake timing, not touched here) passed on rerun.

@devswha
devswha deleted the test/b3-prose-doc-pins branch November 24, 2026 00:51
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