No validation performed with @Repeatable
annotations used more than once for the same element
#4831
Open
3 tasks done
Labels
Hi guys, I'm having issues when using
@Repeatable
constraint annotations withmicronaut-validation
. When I add more than one of the same annotation to a field/class, no validation is performed. In other validation frameworks, like hibernate validator, they work normally. I created a minimal project that reproduces the issue in the tests: https://github.com/racevedoo/micronaut-validation-testIn this project, there are 2 objects that are validated, one contains a field with a single
@Pattern
constraint (PatternValidation
), and other with multiple@Pattern
constraints for the same field (PatternValidationMultipleAnnotations
). I know the pattern annotation is not the best example, but for custom annotations it's quite common to annotate the same element multiple times with the same annotation (with different annotation parameters).Is this a bug?
Task List
Steps to Reproduce
Expected Behaviour
The test should pass, as the object has constraint violations.
Actual Behaviour
The test does not pass, because no validation is performed.
Environment Information
Example Application
https://github.com/racevedoo/micronaut-validation-test
The text was updated successfully, but these errors were encountered: