Skip to content

feat(extensions): mirror DocxReview as IDocxReview - #375

Merged
Ank-KhoaHo merged 2 commits into
mainfrom
feat/docx-review-di-mirror
Aug 24, 2026
Merged

feat(extensions): mirror DocxReview as IDocxReview#375
Ank-KhoaHo merged 2 commits into
mainfrom
feat/docx-review-di-mirror

Conversation

@Ank-KhoaHo

Copy link
Copy Markdown
Owner

Closes the structural lag the same day it opened. DocxReview reached nuget.org in 0.36.1, so the
extensions package can finally wrap it — that gap has gone stale nine times, and this is the first
time it was paid in a day.

IDocxReview and DocxReviewService mirror all four operations 1:1, byte[] for byte[] and
Stream for Stream. The Ank.DocToolkit floor moves to [0.36.1, ).

A third guard the project split had quietly narrowed

CLAUDE.md prescribes a 1:1 mirror check, and it read src/DocToolkit/{core}.cs — which after the
split matched nothing for DocxEditor, PdfEditor, WorkbookEditor, PresentationEditor or
DocxReview. Five of thirteen pairs. It is a glob now, and the new pair was added in the same
change as the interface
, which is what that section requires.

That is the third: StreamOverloadTests' inventory, check-readme-coverage.py, and now this.

Tests that discriminate

Nine, each asserting something a passthrough would fail — the standard the DI suite already sets,
because these services are pure delegation and the real risk is a member wired to the wrong thing:

  • Inspect reads a document that has review state, so a stub returning an empty report fails
    where a clean-document test would pass
  • accept and reject are asserted on opposite outcomes, so one implementation cannot satisfy both
  • RemoveComments is asserted to have removed them
  • every guard is asserted to throw, which a member doing nothing would not

Fixtures are raw OpenXml, available transitively through Ank.DocToolkitno new dependency.
They have to be: TrackChanges records nothing for the library's own edits, and there is no
comment-authoring API, so a fixture built through DocxEditor would assert against empty sets
forever while looking green.

Verified by sabotage, not by reading

sabotage tests failed
RejectRevisions wired to AcceptRevisions 1
Inspect wired to a clean document 3
RemoveComments returns its input 2

DI coverage back to 100%/100%, the floor it is held at because an uncovered member here is a
member nobody checked was wired to anything.

One number removed

The extensions README said "fifteen injectable interfaces" while listing sixteen, and seventeen are
registered — stale by two before this change touched it. The list is what check-readme-coverage.py
verifies; the count was a claim nothing did, so it is gone rather than corrected.

Closes A66.

@Ank-KhoaHo
Ank-KhoaHo merged commit 8bcfacf into main Aug 24, 2026
29 checks passed
@Ank-KhoaHo
Ank-KhoaHo deleted the feat/docx-review-di-mirror branch August 24, 2026 13:57
Ank-KhoaHo added a commit that referenced this pull request Aug 24, 2026
🤖 I have created a release *beep* *boop*
---


##
[0.37.0](v0.36.1...v0.37.0)
(2026-08-24)


### Added

* **extensions:** mirror DocxReview as IDocxReview
([#375](#375))
([8bcfacf](8bcfacf))


### Fixed

* **ci:** remove the duplicate ignore entries that broke the Dependabot
config ([#374](#374))
([cab06a2](cab06a2))
* **core:** restore the samples to the floating version
([#371](#371))
([51a66eb](51a66eb))


### Changed

* **deps:** bump OfficeIMO to 3.2.6, AngleSharp to 1.7.2 and PdfPig to
0.1.16 ([#366](#366))
([df1dc03](df1dc03))

---
This PR was generated with [Release
Please](https://github.com/googleapis/release-please). See
[documentation](https://github.com/googleapis/release-please#release-please).
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.

2 participants