Package org.apache.bval.jsr
Class ConstraintCompositionTest
- java.lang.Object
-
- org.apache.bval.jsr.ValidationTestBase
-
- org.apache.bval.jsr.ConstraintCompositionTest
-
public class ConstraintCompositionTest extends ValidationTestBase
Checks that groups are correctly inherited from the root constraint to its compositing constraints.- Author:
- Carlos Vara
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classConstraintCompositionTest.Codestatic interfaceConstraintCompositionTest.ElevenDigitsCodestatic interfaceConstraintCompositionTest.Group1static interfaceConstraintCompositionTest.Group2static classConstraintCompositionTest.Manstatic interfaceConstraintCompositionTest.ManNamestatic classConstraintCompositionTest.Payload1static classConstraintCompositionTest.Payload2static classConstraintCompositionTest.Personstatic interfaceConstraintCompositionTest.PersonIdstatic interfaceConstraintCompositionTest.PersonName
-
Field Summary
-
Fields inherited from class org.apache.bval.jsr.ValidationTestBase
factory, validator
-
-
Constructor Summary
Constructors Constructor Description ConstraintCompositionTest()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidtest1LevelInheritance()Check correct group inheritance on constraint composition on a 1 level hierarchy.voidtest2LevelInheritance()Check correct group inheritance on constraint composition on a 2 level hierarchy.voidtestAnnotationGroupsAreInherited()Checks that the groups() value of the constraint annotations are correctly set to the inherited ones.voidtestAnnotationPayloadsAreInherited()Checks that the payload() value of the constraint annotations are correctly set to the inherited ones.voidtestIndexedOverridesAttributes()Checks thatOverridesAttribute.constraintIndex()parsing and applying works.voidtestReportAsAsingleViolation()Checks that errors are reported correctly when usingReportAsSingleViolation.-
Methods inherited from class org.apache.bval.jsr.ValidationTestBase
createValidator, setUp, setupValidatorFactory
-
-
-
-
Method Detail
-
test1LevelInheritance
public void test1LevelInheritance()
Check correct group inheritance on constraint composition on a 1 level hierarchy.
-
test2LevelInheritance
public void test2LevelInheritance()
Check correct group inheritance on constraint composition on a 2 level hierarchy.
-
testAnnotationGroupsAreInherited
public void testAnnotationGroupsAreInherited()
Checks that the groups() value of the constraint annotations are correctly set to the inherited ones.
-
testAnnotationPayloadsAreInherited
public void testAnnotationPayloadsAreInherited()
Checks that the payload() value of the constraint annotations are correctly set to the inherited ones.
-
testIndexedOverridesAttributes
public void testIndexedOverridesAttributes()
Checks thatOverridesAttribute.constraintIndex()parsing and applying works.
-
testReportAsAsingleViolation
public void testReportAsAsingleViolation()
Checks that errors are reported correctly when usingReportAsSingleViolation.
-
-