You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The problem is, that as soon a Validator is added to the binding or the bound field has a validator that fails for the emptyValue of the field, the field isn't marked asRequired anymore. The current Unit tests are just covering the @NotNull annotation, but not the NotEmpty annotation. This is in my eyes wrong behavior and could create trouble, as soon as vaadin/flow-components#3406 is implemented.
Issue for current implementation: vaadin/framework#9000 (comment)
Expected behavior
A field that is bound to a with @NotEmpty property should be marked as required, regardless if a Validator is present or not.
Description of the bug
The problem is, that as soon a Validator is added to the binding or the bound field has a validator that fails for the emptyValue of the field, the field isn't marked asRequired anymore. The current Unit tests are just covering the
@NotNull
annotation, but not the NotEmpty annotation. This is in my eyes wrong behavior and could create trouble, as soon as vaadin/flow-components#3406 is implemented.Issue for current implementation: vaadin/framework#9000 (comment)
Expected behavior
A field that is bound to a with
@NotEmpty
property should be marked as required, regardless if a Validator is present or not.Minimal reproducible example
Result:
![image](https://user-images.githubusercontent.com/15174076/178256456-5de88ae0-83b2-4844-b87f-956089a78ef8.png)
Versions
Credits to @mcollovati for finding the related issues and validating the found behavior.
The text was updated successfully, but these errors were encountered: