Class CartRemovalJobTest
- 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.acceleratorservices.cronjob.CartRemovalJobTest
-
- All Implemented Interfaces:
JaloSessionHolder
@IntegrationTest public class CartRemovalJobTest extends ServicelayerTransactionalTest
Test class for testing the functionality of the CartRemovalJob. Attention: this class tests only the saved carts functionality of this job other functionalities can be enhanced
-
-
Field Summary
Fields Modifier and Type Field Description static java.lang.String
SESSION_CART_PARAMETER_NAME
-
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 CartRemovalJobTest()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
setUp()
void
testExpiredSavedCarts()
Test if expired saved carts exist will be removedvoid
testNonExpiredSavedCarts()
Test that saved carts will not be removed if they are not expiredvoid
testNoSavedCartsAtAll()
No saved carts exist and test that no error happensvoid
testSavedCartsWithExceededCartMaxAge()
Test that a non expired saved cart with exceeded max age date will not be removed-
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
-
-
-
-
Field Detail
-
SESSION_CART_PARAMETER_NAME
public static final java.lang.String SESSION_CART_PARAMETER_NAME
- See Also:
- Constant Field Values
-
-
Method Detail
-
setUp
public void setUp() throws java.lang.Exception
- Throws:
java.lang.Exception
-
testNoSavedCartsAtAll
public void testNoSavedCartsAtAll()
No saved carts exist and test that no error happens
-
testNonExpiredSavedCarts
public void testNonExpiredSavedCarts()
Test that saved carts will not be removed if they are not expired
-
testSavedCartsWithExceededCartMaxAge
public void testSavedCartsWithExceededCartMaxAge() throws java.lang.InterruptedException
Test that a non expired saved cart with exceeded max age date will not be removed- Throws:
java.lang.InterruptedException
-
testExpiredSavedCarts
public void testExpiredSavedCarts()
Test if expired saved carts exist will be removed
-
-