Class BundleAddToCartMethodHookTest
- java.lang.Object
-
- de.hybris.platform.configurablebundleservices.order.hook.BundleAddToCartMethodHookTest
-
@UnitTest public class BundleAddToCartMethodHookTest extends java.lang.Object
-
-
Field Summary
Fields Modifier and Type Field Description protected BundleCartHookHelperbundleCartHookHelperprotected BundleCartValidatorbundleCartValidatorprotected DefaultCartBundleComponentEditableCheckerbundleComponentEditableCheckerprotected BundleRuleServicebundleRuleServiceprotected BundleTemplateServicebundleTemplateServiceprotected CartServicecartServiceprotected DefaultCartBundleComponentEditableCheckereditableCheckerprotected EntryGroupServiceentryGroupServiceprotected BundleAddToCartMethodHookhookprotected L10NServicel10NServiceprotected ModelServicemodelServiceorg.junit.rules.ExpectedExceptionthrown
-
Constructor Summary
Constructors Constructor Description BundleAddToCartMethodHookTest()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidsetup()voidshouldAssignBundleTemplate()voidshouldCheckThatTheProductIsAllowed()voidshouldCheckTheComponentBelongToTheRightTemplate()voidshouldCheckTheComponentExists()voidshouldCreateBundleTreeInCart()voidshouldDenyAddingOfNonIndividualProducts()voidshouldNotAllowInvalidComponentNullEntryGroup()voidshouldNotAllowInvalidRequiredComponents()voidshouldNotCheckRequiredComponentNullEntryGroup()voidshouldSkipNotBundledCalls()voidshouldUpdateLeafComponentsErroneousStatus()
-
-
-
Field Detail
-
editableChecker
@Mock protected DefaultCartBundleComponentEditableChecker editableChecker
-
l10NService
@Mock protected L10NService l10NService
-
modelService
@Mock protected ModelService modelService
-
cartService
@Mock protected CartService cartService
-
bundleTemplateService
@Mock protected BundleTemplateService bundleTemplateService
-
bundleRuleService
@Mock protected BundleRuleService bundleRuleService
-
entryGroupService
@Mock protected EntryGroupService entryGroupService
-
bundleCartValidator
@Mock protected BundleCartValidator bundleCartValidator
-
bundleCartHookHelper
@Mock protected BundleCartHookHelper bundleCartHookHelper
-
bundleComponentEditableChecker
@Mock protected DefaultCartBundleComponentEditableChecker bundleComponentEditableChecker
-
hook
@InjectMocks protected BundleAddToCartMethodHook hook
-
thrown
public org.junit.rules.ExpectedException thrown
-
-
Method Detail
-
setup
public void setup()
-
shouldSkipNotBundledCalls
public void shouldSkipNotBundledCalls() throws CommerceCartModificationException
-
shouldDenyAddingOfNonIndividualProducts
public void shouldDenyAddingOfNonIndividualProducts() throws CommerceCartModificationException
-
shouldCheckTheComponentExists
public void shouldCheckTheComponentExists() throws CommerceCartModificationException
-
shouldCheckTheComponentBelongToTheRightTemplate
public void shouldCheckTheComponentBelongToTheRightTemplate() throws CommerceCartModificationException
-
shouldAssignBundleTemplate
public void shouldAssignBundleTemplate() throws CommerceCartModificationException
-
shouldNotCheckRequiredComponentNullEntryGroup
public void shouldNotCheckRequiredComponentNullEntryGroup() throws CommerceCartModificationException
-
shouldNotAllowInvalidComponentNullEntryGroup
public void shouldNotAllowInvalidComponentNullEntryGroup() throws CommerceCartModificationException
-
shouldNotAllowInvalidRequiredComponents
public void shouldNotAllowInvalidRequiredComponents() throws CommerceCartModificationException
-
shouldCheckThatTheProductIsAllowed
public void shouldCheckThatTheProductIsAllowed() throws CommerceCartModificationException
-
shouldCreateBundleTreeInCart
public void shouldCreateBundleTreeInCart() throws CommerceCartModificationException
-
shouldUpdateLeafComponentsErroneousStatus
public void shouldUpdateLeafComponentsErroneousStatus() throws java.lang.Exception- Throws:
java.lang.Exception
-
-