Class CustomerTicketingFacadeTest
- java.lang.Object
-
- de.hybris.platform.customerticketingfacades.customerticket.CustomerTicketingFacadeTest
-
@UnitTest public class CustomerTicketingFacadeTest extends java.lang.Object
Test cases for CustomerTicketingFacade class.
-
-
Constructor Summary
Constructors Constructor Description CustomerTicketingFacadeTest()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidsetup()Test seutp.voidshouldReturnAssociatedObjectMapForCurrentUser()voidshouldReturnCsStatusClose()voidshouldReturnCsStatusNew()voidshouldReturnCsStatusOpen()voidshouldReturnListOfAttachments()voidshouldReturnNullIfNoMatchCsStatus()voidshouldReturnNullOfAttachments()voidshouldReturnNullOfAttachmentsIfIOException()voidshouldUpdateTicketStatusFromOpenToClose()voidshouldUpdateTicketStatusFromOpenToInProgress()voidshouldUpdateTicketWithNewNote()
-
-
-
Method Detail
-
setup
public void setup()
Test seutp.
-
shouldReturnAssociatedObjectMapForCurrentUser
public void shouldReturnAssociatedObjectMapForCurrentUser()
Test ofDefaultCustomerTicketingFacade.getAssociatedToObjects()should return the associate object map which contents 2 TicketAssociatedData.
-
shouldReturnCsStatusNew
public void shouldReturnCsStatusNew()
Test ofDefaultCustomerTicketingFacade.getCsStatus(TicketData)should return CsTicketStatus.NEW
-
shouldReturnCsStatusOpen
public void shouldReturnCsStatusOpen()
Test ofDefaultCustomerTicketingFacade.getCsStatus(TicketData)should return CsTicketStatus.OPEN
-
shouldReturnCsStatusClose
public void shouldReturnCsStatusClose()
Test ofDefaultCustomerTicketingFacade.getCsStatus(TicketData)should return CsTicketStatus.CLOSED
-
shouldReturnNullIfNoMatchCsStatus
public void shouldReturnNullIfNoMatchCsStatus()
Test ofDefaultCustomerTicketingFacade.getCsStatus(TicketData)should return NULL value if no match status found.
-
shouldReturnNullOfAttachments
public void shouldReturnNullOfAttachments()
Test ofDefaultCustomerTicketingFacade.getAttachments(TicketData)should return NULL value if no attachments in ticket data.
-
shouldReturnListOfAttachments
public void shouldReturnListOfAttachments() throws java.io.IOExceptionTest ofDefaultCustomerTicketingFacade.getAttachments(TicketData)should return list of attachments which contents 2 media models.
- Throws:
java.io.IOException
-
shouldReturnNullOfAttachmentsIfIOException
public void shouldReturnNullOfAttachmentsIfIOException() throws java.io.IOExceptionTest ofDefaultCustomerTicketingFacade.getAttachments(TicketData)should return NULL value if an IOException occurs
- Throws:
java.io.IOException
-
shouldUpdateTicketWithNewNote
public void shouldUpdateTicketWithNewNote()
Test ofDefaultCustomerTicketingFacade.updateTicket(TicketData)should invoke
TicketBusinessService.addNoteToTicket(CsTicketModel, CsInterventionType, CsEventReason, String, Collection)when ticket is NEW state and in OPEN status.
-
shouldUpdateTicketStatusFromOpenToClose
public void shouldUpdateTicketStatusFromOpenToClose() throws TicketExceptionTest ofDefaultCustomerTicketingFacade.updateTicket(TicketData)should invoke
TicketBusinessService.resolveTicket(CsTicketModel, CsInterventionType, CsResolutionType, String, Collection)when ticket status transit from OPEN to CLOSE- Throws:
TicketException
-
shouldUpdateTicketStatusFromOpenToInProgress
public void shouldUpdateTicketStatusFromOpenToInProgress() throws TicketExceptionTest ofDefaultCustomerTicketingFacade.updateTicket(TicketData)should invoke
TicketBusinessService.unResolveTicket(CsTicketModel, CsInterventionType, CsEventReason, String, Collection)when ticket status transit from NEW to INPROCESS- Throws:
TicketException
-
-