public void MapBOToModelList() { var mapper = new BOLDeploymentProcessMapper(); BODeploymentProcess bo = new BODeploymentProcess(); bo.SetProperties("A", true, "A", "A", "A", 1); List <ApiDeploymentProcessResponseModel> response = mapper.MapBOToModel(new List <BODeploymentProcess>() { { bo } }); response.Count.Should().Be(1); }
public void MapModelToBO() { var mapper = new BOLDeploymentProcessMapper(); ApiDeploymentProcessRequestModel model = new ApiDeploymentProcessRequestModel(); model.SetProperties(true, "A", "A", "A", 1); BODeploymentProcess response = mapper.MapModelToBO("A", model); response.IsFrozen.Should().Be(true); response.JSON.Should().Be("A"); response.OwnerId.Should().Be("A"); response.RelatedDocumentIds.Should().Be("A"); response.Version.Should().Be(1); }
public void MapBOToModel() { var mapper = new BOLDeploymentProcessMapper(); BODeploymentProcess bo = new BODeploymentProcess(); bo.SetProperties("A", true, "A", "A", "A", 1); ApiDeploymentProcessResponseModel response = mapper.MapBOToModel(bo); response.Id.Should().Be("A"); response.IsFrozen.Should().Be(true); response.JSON.Should().Be("A"); response.OwnerId.Should().Be("A"); response.RelatedDocumentIds.Should().Be("A"); response.Version.Should().Be(1); }
public void MapEFToBO() { var mapper = new DALDeploymentProcessMapper(); DeploymentProcess entity = new DeploymentProcess(); entity.SetProperties("A", true, "A", "A", "A", 1); BODeploymentProcess response = mapper.MapEFToBO(entity); response.Id.Should().Be("A"); response.IsFrozen.Should().Be(true); response.JSON.Should().Be("A"); response.OwnerId.Should().Be("A"); response.RelatedDocumentIds.Should().Be("A"); response.Version.Should().Be(1); }