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