Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Improve Assert.That error text message #4702

Merged
merged 2 commits into from May 2, 2024

Conversation

iamdmitrij
Copy link
Contributor

@iamdmitrij iamdmitrij commented May 2, 2024

Fixes #3767.

Assert.That for collections, error text changes to:

  Message: 
      Expected: exactly one item equal to "boop"
      But was:  **0 matching items** < "no-store, no-cache" >

by adding x matching item/s to the message text.

  • Add matching keyword to error message
  • Unit tests
  • Unit test for no matching items missing use-case

Copy link
Member

@OsirisTerje OsirisTerje left a comment

Choose a reason for hiding this comment

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

lgtm

@OsirisTerje OsirisTerje merged commit db4a99f into nunit:master May 2, 2024
5 checks passed
@iamdmitrij iamdmitrij deleted the 3767-improve-message branch May 3, 2024 13:02
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.

Incorrect number of items listed in failure message
2 participants