public void MapEntityToModel() { var mapper = new DALPersonTypeMapper(); PersonType item = new PersonType(); item.SetProperties(1, "A"); ApiPersonTypeServerResponseModel response = mapper.MapEntityToModel(item); response.Id.Should().Be(1); response.Name.Should().Be("A"); }
public void MapEntityToModelList() { var mapper = new DALPersonTypeMapper(); PersonType item = new PersonType(); item.SetProperties(1, "A"); List <ApiPersonTypeServerResponseModel> response = mapper.MapEntityToModel(new List <PersonType>() { { item } }); response.Count.Should().Be(1); }