public void BuildTicketAckDtoFromTicketAckTest() { var ticket = new TicketAck(SR.S1000, SR.I1000, TicketAckStatus.Rejected, SR.I100, SR.S1000); var dto = new TicketAckMapper().Map(ticket); var json = dto.ToJson(); var newDto = TicketAckDTO.FromJson(json); TicketCompareHelper.Compare(ticket, dto); TicketCompareHelper.Compare(ticket, newDto); }
public void TicketAckToJsonTest() { var ticket = TicketBuilderHelper.GetTicketAck(); var dto = new TicketAckMapper().Map(ticket); var ticketJson = ticket.ToJson(); var dtoJson = dto.ToJson(); CheckMandatoryFields(ticketJson); CheckMandatoryFields(dtoJson); Assert.AreEqual(ticketJson, dtoJson); }