public void MapModelToBO() { var mapper = new BOLTicketMapper(); ApiTicketRequestModel model = new ApiTicketRequestModel(); model.SetProperties("A", 1); BOTicket response = mapper.MapModelToBO(1, model); response.PublicId.Should().Be("A"); response.TicketStatusId.Should().Be(1); }
public void MapBOToModel() { var mapper = new BOLTicketMapper(); BOTicket bo = new BOTicket(); bo.SetProperties(1, "A", 1); ApiTicketResponseModel response = mapper.MapBOToModel(bo); response.Id.Should().Be(1); response.PublicId.Should().Be("A"); response.TicketStatusId.Should().Be(1); }
public void MapEFToBO() { var mapper = new DALTicketMapper(); Ticket entity = new Ticket(); entity.SetProperties(1, "A", 1); BOTicket response = mapper.MapEFToBO(entity); response.Id.Should().Be(1); response.PublicId.Should().Be("A"); response.TicketStatusId.Should().Be(1); }
public void MapBOToEF() { var mapper = new DALTicketMapper(); var bo = new BOTicket(); bo.SetProperties(1, "A", 1); Ticket response = mapper.MapBOToEF(bo); response.Id.Should().Be(1); response.PublicId.Should().Be("A"); response.TicketStatusId.Should().Be(1); }
public void MapBOToModelList() { var mapper = new BOLTicketMapper(); BOTicket bo = new BOTicket(); bo.SetProperties(1, "A", 1); List <ApiTicketResponseModel> response = mapper.MapBOToModel(new List <BOTicket>() { { bo } }); response.Count.Should().Be(1); }