Class InterceptorContextModelRegistrationTest
java.lang.Object
de.hybris.platform.testframework.HybrisJUnit4Test
de.hybris.platform.servicelayer.ServicelayerBaseTest
de.hybris.platform.servicelayer.interceptor.InterceptorContextModelRegistrationTest
- All Implemented Interfaces:
JaloSessionHolder
Tests PLA-10368.
Test uses test implementation of
This test service knows only a simple
Test uses test implementation of
ModelService :
de.hybris.platform.servicelayer.interceptor.InterceptorTestModelService.This test service knows only a simple
InterceptorRegistry, which is registered only for the purpose of
this test. It maps only one test PrepareInterceptors for the types under test.-
Field Summary
Fields inherited from class de.hybris.platform.testframework.HybrisJUnit4Test
jaloSession -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidsetUp()voidvoidvoidvoidvoidvoidtearDown()voidIn the test scenario an order is created.
Test interceptors mapping creates a new paymentAddress per each new model creation.
Moreover, each new address triggers new Country creation via prepare interceptor.
The test checks if every new model registered in the interceptor context is really persisted.Methods inherited from class de.hybris.platform.servicelayer.ServicelayerBaseTest
autowireProperties, getApplicationContext, getBeanName, prepareApplicationContextAndSessionMethods inherited from class de.hybris.platform.testframework.HybrisJUnit4Test
establishJaloSession, finish, getOrCreateCurrency, getOrCreateLanguage, init, intenseChecksActivated, takeJaloSession
-
Constructor Details
-
InterceptorContextModelRegistrationTest
public InterceptorContextModelRegistrationTest()
-
-
Method Details
-
setUp
- Throws:
Exception
-
tearDown
- Throws:
Exception
-
testPersistModelsRegisteredInPrepareInterceptor
public void testPersistModelsRegisteredInPrepareInterceptor()In the test scenario an order is created.
Test interceptors mapping creates a new paymentAddress per each new model creation.
Moreover, each new address triggers new Country creation via prepare interceptor.
The test checks if every new model registered in the interceptor context is really persisted. -
shouldCreateNewModelRegisteredForSaveInRemoveInterceptor
public void shouldCreateNewModelRegisteredForSaveInRemoveInterceptor() -
shouldUpdateExistingModelRegisteredForSaveInRemoveInterceptor
public void shouldUpdateExistingModelRegisteredForSaveInRemoveInterceptor() -
shouldRemoveExistingModelRegisteredForRemovalInPrepareInterceptor
public void shouldRemoveExistingModelRegisteredForRemovalInPrepareInterceptor() -
shouldCreateAndDeleteTheSameItemRegisteredForBothCreationAndDeletion
public void shouldCreateAndDeleteTheSameItemRegisteredForBothCreationAndDeletion() -
shouldSkipRegisteringMappingWithNoInterceptorWithoutException
public void shouldSkipRegisteringMappingWithNoInterceptorWithoutException()
-