public virtual ApiReleaseResponseModel MapBOToModel( BORelease boRelease) { var model = new ApiReleaseResponseModel(); model.SetProperties(boRelease.Id, boRelease.Assembled, boRelease.ChannelId, boRelease.JSON, boRelease.ProjectDeploymentProcessSnapshotId, boRelease.ProjectId, boRelease.ProjectVariableSetSnapshotId, boRelease.Version); return(model); }
public void MapResponseToRequest() { var mapper = new ApiReleaseModelMapper(); var model = new ApiReleaseResponseModel(); model.SetProperties("A", DateTimeOffset.Parse("1/1/1987 12:00:00 AM"), "A", "A", "A", "A", "A", "A"); ApiReleaseRequestModel response = mapper.MapResponseToRequest(model); response.Assembled.Should().Be(DateTimeOffset.Parse("1/1/1987 12:00:00 AM")); response.ChannelId.Should().Be("A"); response.JSON.Should().Be("A"); response.ProjectDeploymentProcessSnapshotId.Should().Be("A"); response.ProjectId.Should().Be("A"); response.ProjectVariableSetSnapshotId.Should().Be("A"); response.Version.Should().Be("A"); }