public void MapModelToBO() { var mapper = new BOLCompositePrimaryKeyMapper(); ApiCompositePrimaryKeyRequestModel model = new ApiCompositePrimaryKeyRequestModel(); model.SetProperties(1); BOCompositePrimaryKey response = mapper.MapModelToBO(1, model); response.Id2.Should().Be(1); }
public void MapBOToModel() { var mapper = new BOLCompositePrimaryKeyMapper(); BOCompositePrimaryKey bo = new BOCompositePrimaryKey(); bo.SetProperties(1, 1); ApiCompositePrimaryKeyResponseModel response = mapper.MapBOToModel(bo); response.Id.Should().Be(1); response.Id2.Should().Be(1); }
public void MapEFToBO() { var mapper = new DALCompositePrimaryKeyMapper(); CompositePrimaryKey entity = new CompositePrimaryKey(); entity.SetProperties(1, 1); BOCompositePrimaryKey response = mapper.MapEFToBO(entity); response.Id.Should().Be(1); response.Id2.Should().Be(1); }
public void MapBOToEF() { var mapper = new DALCompositePrimaryKeyMapper(); var bo = new BOCompositePrimaryKey(); bo.SetProperties(1, 1); CompositePrimaryKey response = mapper.MapBOToEF(bo); response.Id.Should().Be(1); response.Id2.Should().Be(1); }
public void MapBOToModelList() { var mapper = new BOLCompositePrimaryKeyMapper(); BOCompositePrimaryKey bo = new BOCompositePrimaryKey(); bo.SetProperties(1, 1); List <ApiCompositePrimaryKeyResponseModel> response = mapper.MapBOToModel(new List <BOCompositePrimaryKey>() { { bo } }); response.Count.Should().Be(1); }