Package org.apache.bval.jsr
Class ConstraintDefinitionsTest
- java.lang.Object
-
- org.apache.bval.jsr.ValidationTestBase
-
- org.apache.bval.jsr.ConstraintDefinitionsTest
-
public class ConstraintDefinitionsTest extends ValidationTestBase
Checks the correct parsing of constraint definitions.- Author:
- Carlos Vara
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
ConstraintDefinitionsTest.InvalidAttribute
static interface
ConstraintDefinitionsTest.InvalidAttributeConstraint
static class
ConstraintDefinitionsTest.InvalidGroups
static interface
ConstraintDefinitionsTest.InvalidGroupsConstraint
static class
ConstraintDefinitionsTest.InvalidMessage
static interface
ConstraintDefinitionsTest.InvalidMessageConstraint
static class
ConstraintDefinitionsTest.InvalidPayload
static interface
ConstraintDefinitionsTest.InvalidPayloadConstraint
static interface
ConstraintDefinitionsTest.MinList
static class
ConstraintDefinitionsTest.NoGroups
static interface
ConstraintDefinitionsTest.NoGroupsConstraint
static class
ConstraintDefinitionsTest.NoMessage
static interface
ConstraintDefinitionsTest.NoMessageConstraint
static class
ConstraintDefinitionsTest.NoPayload
static interface
ConstraintDefinitionsTest.NoPayloadConstraint
static class
ConstraintDefinitionsTest.Person
-
Field Summary
-
Fields inherited from class org.apache.bval.jsr.ValidationTestBase
factory, validator
-
-
Constructor Summary
Constructors Constructor Description ConstraintDefinitionsTest()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
testCustomAttributes()
Checks the correct parsing of a constraint with an array of constraints as attributes.void
testInvalidAttributeConstraint()
Checks that aConstraintDefinitionException
is thrown when parsing a constraint definition with a method starting with 'valid'.void
testInvalidDefaultGroupsConstraint()
Checks that aConstraintDefinitionException
is thrown when parsing a constraint definition with an invalidgroups()
method.void
testInvalidDefaultMessageConstraint()
Checks that aConstraintDefinitionException
is thrown when parsing a constraint definition with an invalidmessage()
method.void
testInvalidDefaultPayloadConstraint()
Checks that aConstraintDefinitionException
is thrown when parsing a constraint definition with an invalidpayload()
method.void
testNoGroupsConstraint()
Checks that aConstraintDefinitionException
is thrown when parsing a constraint definition with nogroups()
method.void
testNoMessageConstraint()
Checks that aConstraintDefinitionException
is thrown when parsing a constraint definition with nomessage()
method.void
testNoPayloadConstraint()
Checks that aConstraintDefinitionException
is thrown when parsing a constraint definition with nopayload()
method.-
Methods inherited from class org.apache.bval.jsr.ValidationTestBase
createValidator, setUp, setupValidatorFactory
-
-
-
-
Method Detail
-
testCustomAttributes
public void testCustomAttributes()
Checks the correct parsing of a constraint with an array of constraints as attributes.
-
testNoGroupsConstraint
public void testNoGroupsConstraint()
Checks that aConstraintDefinitionException
is thrown when parsing a constraint definition with nogroups()
method.
-
testInvalidDefaultGroupsConstraint
public void testInvalidDefaultGroupsConstraint()
Checks that aConstraintDefinitionException
is thrown when parsing a constraint definition with an invalidgroups()
method.
-
testNoPayloadConstraint
public void testNoPayloadConstraint()
Checks that aConstraintDefinitionException
is thrown when parsing a constraint definition with nopayload()
method.
-
testInvalidDefaultPayloadConstraint
public void testInvalidDefaultPayloadConstraint()
Checks that aConstraintDefinitionException
is thrown when parsing a constraint definition with an invalidpayload()
method.
-
testNoMessageConstraint
public void testNoMessageConstraint()
Checks that aConstraintDefinitionException
is thrown when parsing a constraint definition with nomessage()
method.
-
testInvalidDefaultMessageConstraint
public void testInvalidDefaultMessageConstraint()
Checks that aConstraintDefinitionException
is thrown when parsing a constraint definition with an invalidmessage()
method.
-
testInvalidAttributeConstraint
public void testInvalidAttributeConstraint()
Checks that aConstraintDefinitionException
is thrown when parsing a constraint definition with a method starting with 'valid'.
-
-