public virtual ApiLocationResponseModel MapBOToModel( BOLocation boLocation) { var model = new ApiLocationResponseModel(); model.SetProperties(boLocation.LocationID, boLocation.Availability, boLocation.CostRate, boLocation.ModifiedDate, boLocation.Name); return(model); }
public virtual ApiLocationResponseModel MapBOToModel( BOLocation boLocation) { var model = new ApiLocationResponseModel(); model.SetProperties(boLocation.LocationId, boLocation.GpsLat, boLocation.GpsLong, boLocation.LocationName); return(model); }
public void MapResponseToRequest() { var mapper = new ApiLocationModelMapper(); var model = new ApiLocationResponseModel(); model.SetProperties(1, 1, 1, "A"); ApiLocationRequestModel response = mapper.MapResponseToRequest(model); response.GpsLat.Should().Be(1); response.GpsLong.Should().Be(1); response.LocationName.Should().Be("A"); }
public void MapResponseToRequest() { var mapper = new ApiLocationModelMapper(); var model = new ApiLocationResponseModel(); model.SetProperties(1, 1, 1m, DateTime.Parse("1/1/1987 12:00:00 AM"), "A"); ApiLocationRequestModel response = mapper.MapResponseToRequest(model); response.Availability.Should().Be(1); response.CostRate.Should().Be(1m); response.ModifiedDate.Should().Be(DateTime.Parse("1/1/1987 12:00:00 AM")); response.Name.Should().Be("A"); }