Class AttributeConstraintTest

    • Constructor Detail

      • AttributeConstraintTest

        public AttributeConstraintTest()
    • Method Detail

      • testAttributeAssignmentForModelFillInFromDescriptor

        public void testAttributeAssignmentForModelFillInFromDescriptor()
                                                                 throws java.lang.ClassNotFoundException
        Throws:
        java.lang.ClassNotFoundException
      • testAttributeAssignmentEmptyDescriptor

        public void testAttributeAssignmentEmptyDescriptor()
      • testAttributeAssignmentNotCorrectAnnotationClass

        public void testAttributeAssignmentNotCorrectAnnotationClass()
        provided annotation class is not an annotation - case
      • testAttributeAssignmentForModel

        public void testAttributeAssignmentForModel()
                                             throws java.lang.ClassNotFoundException
        Throws:
        java.lang.ClassNotFoundException
      • testAttributeAssignmentIncompatibleQualifier

        public void testAttributeAssignmentIncompatibleQualifier()
      • testAttributeDescriptorOverridesType

        public void testAttributeDescriptorOverridesType()
      • testAttributeAssignmentIncompatibleDescriptorTargetClass

        public void testAttributeAssignmentIncompatibleDescriptorTargetClass()
      • testAttributeAssignmentIncompatibleTargetClassType

        public void testAttributeAssignmentIncompatibleTargetClassType()
      • testAttributeAssignmentInvalidModel

        public void testAttributeAssignmentInvalidModel()
      • testAttributeAssignmentForPojo

        public void testAttributeAssignmentForPojo()
      • testNullConstraintWithNonExistingDescriptor

        public void testNullConstraintWithNonExistingDescriptor()
      • testValidateAnnotationInPOJOok

        public void testValidateAnnotationInPOJOok()
        Testing annotation for BeanTwoModel. This bean contains 3 annotations which are not violated here. Expect no violation.
      • testValidateAnnotationInPOJOOneViolation

        public void testValidateAnnotationInPOJOOneViolation()
        Testing annotation for BeanTwoModel.test. The given value is greater than the decimalmax rule value but the digit rule is ok. Only the decimalmax violation is expected and this should not change after reloading the framework.
      • testAnnotationInPOJODifferentAttributes

        public void testAnnotationInPOJODifferentAttributes()
        Same as testValidateAnnotationInPOJO_OneViolation() but here an additional hybris constraint is created BUT FOR A DIFFERENT POJO. The violation has to be the same as before.
      • testValidateAnnotationInPOJOSameAttribute

        public void testValidateAnnotationInPOJOSameAttribute()
        Same as testValidateAnnotationInPOJO_OneViolation() BUT here an additional hybris constraint is created TO THE SAME POJO (different attribute, this doesn't matter here). The new constraint won't be violated. Therefore the same violation (decimalmax) should be thrown.
      • testNeedReloadAttributeTest

        public void testNeedReloadAttributeTest()
                                         throws java.lang.InterruptedException
        Throws:
        java.lang.InterruptedException
      • testAnnotationInPOJOTwoViolation

        public void testAnnotationInPOJOTwoViolation()
        Testing both class annotation for one attribute
      • testAnnotationInPOJOandConstraints

        public void testAnnotationInPOJOandConstraints()
        BeanTwoModel.value has one annotation and 2 additional hybris constraints are created. First only the annotation should report the violation, than the validation framework is reloaded and all THREE should report a violation!
      • testHOR969

        public void testHOR969()
      • typeConstraintWithoutAnnotationShouldNotThrowNPE

        public void typeConstraintWithoutAnnotationShouldNotThrowNPE()