Class OrderOnHoldIntegrationTest
java.lang.Object
de.hybris.platform.testframework.HybrisJUnit4Test
de.hybris.platform.servicelayer.ServicelayerBaseTest
de.hybris.platform.servicelayer.ServicelayerTest
de.hybris.platform.yacceleratorordermanagement.integration.BaseAcceleratorIntegrationTest
de.hybris.platform.yacceleratorordermanagement.integration.BaseAcceleratorSourcingIntegrationTest
de.hybris.platform.yacceleratorordermanagement.integration.OrderOnHoldIntegrationTest
- All Implemented Interfaces:
JaloSessionHolder
@IntegrationTest
public class OrderOnHoldIntegrationTest
extends BaseAcceleratorSourcingIntegrationTest
-
Field Summary
Fields inherited from class de.hybris.platform.yacceleratorordermanagement.integration.BaseAcceleratorSourcingIntegrationTest
atpFormulas, automatedWorkflowActionTemplates, baseStores, CAMERA_CODE, CAMERA_QTY, cancellationUtil, CODE_BOSTON, CODE_MEMORY_CARD, CODE_MONTREAL, CODE_MONTREAL_EXTERNAL, CODE_PARIS, CODE_TORONTO, commentTypes, commerceStockService, components, CONSIGNMENT_ACTION_EVENT_NAME, csAgentGroups, DECLINE_ENTRIES, declineUtil, deliveryMode, domains, emailAddresses, LEFTOVER_QTY, LENS_CODE, LENS_QTY, MEMORY_CARD_CODE, MEMORY_CARD_QTY, modelService, order, ORDER_ACTION_EVENT_NAME, orderBusinessProcessService, orders, pointsOfService, products, productService, RE_SOURCE_CHOICE, REALLOCATE_CONSIGNMENT_CHOICE, restockConfigs, returnUtil, sourcingBanService, sourcingConfigs, sourcingUtil, stockLevels, stockService, timeOut, users, warehouses, warehouseStockService, workflowActionTemplates, workflowService, workflowTemplates, workflowUtilFields inherited from class de.hybris.platform.yacceleratorordermanagement.integration.BaseAcceleratorIntegrationTest
flexibleSearchService, springCustomContextLoaderFields inherited from class de.hybris.platform.servicelayer.ServicelayerTest
importServiceFields inherited from class de.hybris.platform.testframework.HybrisJUnit4Test
jaloSession -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidcleanUp()voidsetUp()voidGiven an on hold order with 1 entries and cancel this order
entry 1 : {quantity: 3, product: product1}
Consignment 1 : {quantity: 3, product: product1, Cancelled}voidGiven an order with 1 entries and put this order on hold:
entry 1 : {quantity: 3, product: product1}
Consignment 1 : {quantity: 3, product: product1, Ready}voidGiven a partially cancelled order with 1 entries and put this order on hold:
entry 1 : {quantity: 3, product: product1}
Consignment 1 : {quantity: 3, product: product1, Cancelled}
Consignment 2 : {quantity: 2, product: product1, Ready}voidGiven a partially declined order with 1 entries and put this order on hold:
entry 1 : {quantity: 3, product: product1}
Consignment 1 : {quantity: 2, quantityDeclined: 1, product: product1, Ready}
Consignment 2 : {quantity: 1, product: product1, Ready}voidGiven an on hold order with 1 entries and re-source this order
entry 1 : {quantity: 3, product: product1}
Consignment 1 : {quantity: 3, product: product1, Cancelled}Methods inherited from class de.hybris.platform.yacceleratorordermanagement.integration.BaseAcceleratorSourcingIntegrationTest
buildAsnWorkflow, buildConsignmentWorkflow, cleanUpData, cleanUpModel, refreshConsignmentAndEntries, resetFactors, saveAll, setupMethods inherited from class de.hybris.platform.servicelayer.ServicelayerTest
createCoreData, createDefaultCatalog, createDefaultUsers, createHardwareCatalog, getApplicationContext, importCsv, importData, importData, importData, importStream, importStream, isPrefetchModeNoneMethods inherited from class de.hybris.platform.servicelayer.ServicelayerBaseTest
autowireProperties, getBeanName, prepareApplicationContextAndSessionMethods inherited from class de.hybris.platform.testframework.HybrisJUnit4Test
establishJaloSession, finish, getOrCreateCurrency, getOrCreateLanguage, init, intenseChecksActivated, takeJaloSession
-
Constructor Details
-
OrderOnHoldIntegrationTest
public OrderOnHoldIntegrationTest()
-
-
Method Details
-
setUp
- Throws:
Exception
-
cleanUp
public void cleanUp() -
shouldPutOrderOnHold
Given an order with 1 entries and put this order on hold:
entry 1 : {quantity: 3, product: product1}
Consignment 1 : {quantity: 3, product: product1, Ready}
Result:
1. Consignment 1 should be cancelled
Assert:
It verifies the cancelled consignment -
shouldPutPartiallyDeclinedOrderOnHold
public void shouldPutPartiallyDeclinedOrderOnHold() throws InterruptedException, OrderCancelExceptionGiven a partially declined order with 1 entries and put this order on hold:
entry 1 : {quantity: 3, product: product1}
Consignment 1 : {quantity: 2, quantityDeclined: 1, product: product1, Ready}
Consignment 2 : {quantity: 1, product: product1, Ready}
Result:
1. Consignment 1 should be cancelled
2. Consignment 2 should be cancelled
Assert:
It verifies the cancelled consignments -
shouldPutPartiallyCancelledOrderOnHoldAndCancelPartiallyAgain
public void shouldPutPartiallyCancelledOrderOnHoldAndCancelPartiallyAgain() throws InterruptedException, OrderCancelExceptionGiven a partially cancelled order with 1 entries and put this order on hold:
entry 1 : {quantity: 3, product: product1}
Consignment 1 : {quantity: 3, product: product1, Cancelled}
Consignment 2 : {quantity: 2, product: product1, Ready}
Result:
1. Consignment 1 should be cancelled
2. Consignment 2 should be cancelled
Assert:
It verifies the cancelled consignments -
shouldReSourceOnHoldOrder
Given an on hold order with 1 entries and re-source this order
entry 1 : {quantity: 3, product: product1}
Consignment 1 : {quantity: 3, product: product1, Cancelled}
Result:
1. Consignment 1 should be cancelled
2. Consignment 2 should be Ready
Assert:
It verifies the consignments -
shouldCancelOnHoldOrder
Given an on hold order with 1 entries and cancel this order
entry 1 : {quantity: 3, product: product1}
Consignment 1 : {quantity: 3, product: product1, Cancelled}
Result:
1. Consignment 1 should be cancelled
2. Order should be cancelled
Assert:
It verifies the cancelled order and consignment
-