Class DefaultCMSPageServiceTest

java.lang.Object
de.hybris.platform.cms2.servicelayer.services.impl.DefaultCMSPageServiceTest

@UnitTest public class DefaultCMSPageServiceTest extends Object
  • Constructor Details

    • DefaultCMSPageServiceTest

      public DefaultCMSPageServiceTest()
  • Method Details

    • setUp

      public void setUp() throws Exception
      Throws:
      Exception
    • testShouldCallCmsContentSlotDaoAndFindAllContentPagesByCatalogVersion

      public void testShouldCallCmsContentSlotDaoAndFindAllContentPagesByCatalogVersion()
    • testShouldCallCmsContentSlotDaoAndGetOwnContentSlotsForPage

      public void testShouldCallCmsContentSlotDaoAndGetOwnContentSlotsForPage()
    • testShouldReturnFrontendTemplateName

      public void testShouldReturnFrontendTemplateName()
    • testShouldReturnPageForProductWhenOnlyOnePageWithoutRestrictionsFound

      public void testShouldReturnPageForProductWhenOnlyOnePageWithoutRestrictionsFound() throws Exception
      Throws:
      Exception
    • testShouldReturnLastProductPageByProductWhenThereAreMoreThenOnePage

      public void testShouldReturnLastProductPageByProductWhenThereAreMoreThenOnePage() throws Exception
      Throws:
      Exception
    • testShouldThrowExceptionWhenNoProductPageFound

      public void testShouldThrowExceptionWhenNoProductPageFound() throws Exception
      Throws:
      Exception
    • shouldReturnProductPageByProductCode

      public void shouldReturnProductPageByProductCode() throws Exception
      Throws:
      Exception
    • shouldThrowExceptionWhenProductCodeDoesNotExists

      public void shouldThrowExceptionWhenProductCodeDoesNotExists() throws Exception
      Throws:
      Exception
    • shouldReturnPageForCategoryWhenOnlyOnePageWithoutRestrictionsFound

      public void shouldReturnPageForCategoryWhenOnlyOnePageWithoutRestrictionsFound() throws Exception
      Throws:
      Exception
    • shouldReturnLastCategoryPageByCategoryWhenThereAreMoreThenOnePage

      public void shouldReturnLastCategoryPageByCategoryWhenThereAreMoreThenOnePage() throws Exception
      Throws:
      Exception
    • shouldThrowExceptionWhenNoCategoryPageFound

      public void shouldThrowExceptionWhenNoCategoryPageFound() throws Exception
      Throws:
      Exception
    • shouldReturnCategoryPageByCategoryCode

      public void shouldReturnCategoryPageByCategoryCode() throws Exception
      Throws:
      Exception
    • shouldThrowExceptionWhenCategoryPageIsNotFoundByCode

      public void shouldThrowExceptionWhenCategoryPageIsNotFoundByCode() throws Exception
      Throws:
      Exception
    • shouldReturnTheVersionedPageWhenAValidVersionUidIsPassedToGetPageForId

      public void shouldReturnTheVersionedPageWhenAValidVersionUidIsPassedToGetPageForId() throws Exception
      Throws:
      Exception
    • shouldThrowExceptionWhenAnInvalidVersionUidIsPassedToGetPageForVersionUid

      public void shouldThrowExceptionWhenAnInvalidVersionUidIsPassedToGetPageForVersionUid() throws Exception
      Throws:
      Exception
    • shouldReturnTheActualPageWhenAnInvalidVersionUidIsPassedToGetPageForId

      public void shouldReturnTheActualPageWhenAnInvalidVersionUidIsPassedToGetPageForId() throws Exception
      Throws:
      Exception
    • getPageForIdWithRestrictionsShouldReturnExpectedContentPage

      public void getPageForIdWithRestrictionsShouldReturnExpectedContentPage() throws Exception
      Throws:
      Exception
    • getPageForIdWithRestrictionsShouldReturnExpectedCategoryPage

      public void getPageForIdWithRestrictionsShouldReturnExpectedCategoryPage() throws Exception
      Throws:
      Exception
    • getPageForIdWithRestrictionsShouldReturnExpectedProductPage

      public void getPageForIdWithRestrictionsShouldReturnExpectedProductPage() throws Exception
      Throws:
      Exception
    • getPageForIdWithRestrictionsWithNotSupportedPageTypeShouldReturnExpectedPage

      public void getPageForIdWithRestrictionsWithNotSupportedPageTypeShouldReturnExpectedPage() throws Exception
      Throws:
      Exception
    • shouldThrowExceptionWhenPageNotFoundById

      public void shouldThrowExceptionWhenPageNotFoundById() throws Exception
      Throws:
      Exception
    • givenAValidVersionUidShouldReturnTheConentsSlotsForPageFromCachedSessionContextProvider

      public void givenAValidVersionUidShouldReturnTheConentsSlotsForPageFromCachedSessionContextProvider()
    • givenAValidVersionUidGetContentSlotForPageShouldReturnSlotFromSessionVersionContext

      public void givenAValidVersionUidGetContentSlotForPageShouldReturnSlotFromSessionVersionContext() throws Exception
      Throws:
      Exception
    • givenAValidVersionUidThenGetPageForCategoryShouldReturnPageForProvidedCategory

      public void givenAValidVersionUidThenGetPageForCategoryShouldReturnPageForProvidedCategory() throws Exception
      Throws:
      Exception
    • givenAValidVersionUidThenGetPageForCategoryCodeShouldReturnPageForProvidedCategoryCode

      public void givenAValidVersionUidThenGetPageForCategoryCodeShouldReturnPageForProvidedCategoryCode() throws Exception
      Throws:
      Exception
    • givenAValidVersionUidThenGetPageForProductShouldReturnPageForProvidedProduct

      public void givenAValidVersionUidThenGetPageForProductShouldReturnPageForProvidedProduct() throws Exception
      Throws:
      Exception
    • givenAValidVersionUidThenGetPageForProductCodeShouldReturnPageForProvidedProductCode

      public void givenAValidVersionUidThenGetPageForProductCodeShouldReturnPageForProvidedProductCode() throws Exception
      Throws:
      Exception
    • setupValidVersionUidMocks

      protected void setupValidVersionUidMocks()