Remove EqualTo alias documentation#6396
Merged
Merged
Conversation
Up to standards ✅🟢 Issues
|
Contributor
There was a problem hiding this comment.
Review
Verified the claim in the PR description against the actual assertion library source, since it's the kind of thing that's easy to get backwards in docs:
EqualTo(...)is a generic extension method onIAssertionSource<TValue>(TUnit.Assertions/Extensions/AssertionExtensions.cs:53)..Count()on a collection returnsCollectionCountSource<TCollection, TItem>(TUnit.Assertions/Conditions/CollectionCountSource.cs:11), which is a standalone class that does not implementIAssertionSource<int>— it only exposes its ownIsEqualTo/IsNotEqualTo/IsGreaterThan/etc. members directly.
So the removed example (Count().EqualTo(3)) genuinely would not compile — the PR's stated root cause is correct, not just plausible-sounding. Good catch.
Also checked:
- No other doc page links to the
#equalto-aliasanchor or referencesUsing_EqualTo_Alias, so nothing is left dangling by the removal. IsEqualTo/IsNotEqualToremain documented directly above the removed section, so basic equality coverage is unaffected.- The generic scalar
EqualToalias (which is valid on non-collection sources) isn't otherwise documented elsewhere, but that's out of scope for this PR — it's a deletion of an incorrect example, not a claim that the alias doesn't exist anywhere.
No architectural or design concerns — this is a minimal, correctly-scoped documentation fix with no code changes. Nothing to change here.
This was referenced Jul 13, 2026
This was referenced Jul 15, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
EqualToalias section from equality documentationIsEqualToas the natural documented assertion syntaxRoot cause
The alias section described
EqualTo, but its count-chaining example correctly usedCount().IsEqualTo(...). Replacing that call withEqualTo(...)would be invalid becauseCollectionCountSourceonly exposesIsEqualTo(int).Impact
Users no longer see a confusing alias section whose example cannot naturally demonstrate the alias.
Validation
yarn buildfromdocsgit diff --checkCloses #6360