-
Notifications
You must be signed in to change notification settings - Fork 37.7k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Improve MediaTypeAssert to-string-equality assertions
This commit introduces a `isNotEqualTo(String)` assertion in order to avoid false negatives when using the default Object-based assertion. This is a risk since MediaTypeAssert has a `isEqualTo(String)` method that overrides the base object method and parses the provided String into a MediaType. Users may thus be tempted to use the reverse assertion and expect the same parsing behaviour. This commit also adds tests around the String parsing and the isNotEqual cases. Closes gh-32756
- Loading branch information
1 parent
60c5f44
commit 531da01
Showing
2 changed files
with
78 additions
and
7 deletions.
There are no files selected for viewing
This file contains 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
This file contains 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