A tutorial showing how to create a custom AssertJ assertion class for testing Bean Validation ConstraintValidators in Java. The post presents a ConstraintViolationSetAssert class that extends AbstractAssert, providing fluent methods like hasViolationOnPath and hasNoViolations to make unit tests for custom validators more readable and expressive.

1m read timeFrom wimdeblauwe.com
Post cover image

Sort: