Exemplo n.º 1
0
        public void MapModelToBO()
        {
            var mapper = new BOLProxyMapper();
            ApiProxyRequestModel model = new ApiProxyRequestModel();

            model.SetProperties("A", "A");
            BOProxy response = mapper.MapModelToBO("A", model);

            response.JSON.Should().Be("A");
            response.Name.Should().Be("A");
        }
Exemplo n.º 2
0
        public void MapBOToModel()
        {
            var     mapper = new BOLProxyMapper();
            BOProxy bo     = new BOProxy();

            bo.SetProperties("A", "A", "A");
            ApiProxyResponseModel response = mapper.MapBOToModel(bo);

            response.Id.Should().Be("A");
            response.JSON.Should().Be("A");
            response.Name.Should().Be("A");
        }
Exemplo n.º 3
0
        public void MapBOToModelList()
        {
            var     mapper = new BOLProxyMapper();
            BOProxy bo     = new BOProxy();

            bo.SetProperties("A", "A", "A");
            List <ApiProxyResponseModel> response = mapper.MapBOToModel(new List <BOProxy>()
            {
                { bo }
            });

            response.Count.Should().Be(1);
        }