You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@bval.apache.org by "Matt Benson (JIRA)" <ji...@apache.org> on 2018/11/07 15:33:00 UTC
[jira] [Resolved] (BVAL-168) CharSequence @NotEmpty validation not
according to spec
[ https://issues.apache.org/jira/browse/BVAL-168?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Matt Benson resolved BVAL-168.
------------------------------
Resolution: Fixed
Fix Version/s: 2.0.1
> CharSequence @NotEmpty validation not according to spec
> -------------------------------------------------------
>
> Key: BVAL-168
> URL: https://issues.apache.org/jira/browse/BVAL-168
> Project: BVal
> Issue Type: Bug
> Components: jsr303
> Affects Versions: 2.0.0
> Reporter: Pavel Arnošt
> Assignee: Matt Benson
> Priority: Major
> Fix For: 2.0.1
>
>
> Hi,
> it looks like that CharSequence @NotEmpty validation is not according to spec. Compare:
> [https://github.com/apache/bval/blob/master/bval-jsr/src/main/java/org/apache/bval/constraints/NotEmptyValidatorForCharSequence.java]
> with:
> [https://github.com/hibernate/hibernate-validator/blob/master/engine/src/main/java/org/hibernate/validator/internal/constraintvalidators/bv/notempty/NotEmptyValidatorForCharSequence.java]
> @NotEmpty javadoc says that "{{The annotated element must not be null nor empty." but NotEmptyValidatorForCharSequence#isValid returns true for null values.}}
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)