Class DynamicConstraintTest
- java.lang.Object
-
- de.hybris.platform.testframework.HybrisJUnit4Test
-
- de.hybris.platform.servicelayer.ServicelayerBaseTest
-
- de.hybris.platform.servicelayer.ServicelayerTest
-
- de.hybris.platform.servicelayer.ServicelayerTransactionalTest
-
- de.hybris.platform.validation.model.constraints.jsr303.AbstractConstraintTest
-
- de.hybris.platform.validation.model.constraints.DynamicConstraintTest
-
- All Implemented Interfaces:
JaloSessionHolder
@IntegrationTest public class DynamicConstraintTest extends AbstractConstraintTest
Test for presenting set of required attributes for storingDynamicConstraintModel
.
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class de.hybris.platform.validation.model.constraints.jsr303.AbstractConstraintTest
AbstractConstraintTest.Constraint
-
-
Field Summary
-
Fields inherited from class de.hybris.platform.validation.model.constraints.jsr303.AbstractConstraintTest
constraintDao, flexibleSearchService, i18nService, modelService, typeService, validationService
-
Fields inherited from class de.hybris.platform.servicelayer.ServicelayerTest
importService
-
Fields inherited from class de.hybris.platform.testframework.HybrisJUnit4Test
jaloSession
-
-
Constructor Summary
Constructors Constructor Description DynamicConstraintTest()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
testCheckBSHRuntimeException()
runtime exception are not affecting validation flagvoid
testCheckInvalidBSH()
inappropriate BSH script syntaxvoid
testCreateDynamicModelConstraint()
simple example of valid bsh script assigned for aProductModel
classvoid
testCreateDynamicNoExpressionConstraint()
not allowed creation of the dynamic constraint withoutDynamicConstraintModel.EXPRESSION
void
testCreateDynamicNoTargetConstraint()
not allowed creation of the constraint for a model withoutAbstractConstraintModel.TARGET
orAbstractConstraintModel.TYPE
void
testCreateDynamicPojoConstraint()
simple example of valid bsh script assigned for a pojo classvoid
testCreateDynamicWithTargetConstraint()
not allowed creation of the constraint for a model viaAbstractConstraintModel.TARGET
-
Methods inherited from class de.hybris.platform.validation.model.constraints.jsr303.AbstractConstraintTest
assertModelSavingExceptionWithEvaluatedMessage, assertModelSavingExceptionWithEvaluatedMessage, assertModelSavingExceptionWithMessageKey, assertModelSavingExceptionWithMessageKey, assertTrimmedException, calculateFractionPrecision, checkException, checkException, checkException, getDefaultMessage, resetConstraints, unloadEngine
-
Methods inherited from class de.hybris.platform.servicelayer.ServicelayerTest
createCoreData, createDefaultCatalog, createDefaultUsers, createHardwareCatalog, getApplicationContext, importCsv, importData, importData, importData, importStream, importStream, isPrefetchModeNone
-
Methods inherited from class de.hybris.platform.servicelayer.ServicelayerBaseTest
autowireProperties, getBeanName, prepareApplicationContextAndSession
-
Methods inherited from class de.hybris.platform.testframework.HybrisJUnit4Test
establishJaloSession, finish, getOrCreateCurrency, getOrCreateLanguage, init, intenseChecksActivated, takeJaloSession
-
-
-
-
Method Detail
-
testCreateDynamicPojoConstraint
public void testCreateDynamicPojoConstraint()
simple example of valid bsh script assigned for a pojo classout.print("some data");
-
testCreateDynamicModelConstraint
public void testCreateDynamicModelConstraint()
simple example of valid bsh script assigned for aProductModel
classout.print("some data");
-
testCreateDynamicWithTargetConstraint
public void testCreateDynamicWithTargetConstraint()
not allowed creation of the constraint for a model viaAbstractConstraintModel.TARGET
-
testCreateDynamicNoTargetConstraint
public void testCreateDynamicNoTargetConstraint()
not allowed creation of the constraint for a model withoutAbstractConstraintModel.TARGET
orAbstractConstraintModel.TYPE
-
testCreateDynamicNoExpressionConstraint
public void testCreateDynamicNoExpressionConstraint()
not allowed creation of the dynamic constraint withoutDynamicConstraintModel.EXPRESSION
-
testCheckInvalidBSH
public void testCheckInvalidBSH() throws java.lang.Exception
inappropriate BSH script syntax- Throws:
java.lang.Exception
-
testCheckBSHRuntimeException
public void testCheckBSHRuntimeException() throws java.lang.Exception
runtime exception are not affecting validation flag- Throws:
java.lang.Exception
-
-