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

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

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

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

            response.Id.Should().Be(1);
            response.Name.Should().Be("A");
        }
        public void MapEFToBO()
        {
            var mapper = new DALTransactionStatusMapper();
            TransactionStatus entity = new TransactionStatus();

            entity.SetProperties(1, "A");

            BOTransactionStatus response = mapper.MapEFToBO(entity);

            response.Id.Should().Be(1);
            response.Name.Should().Be("A");
        }
        public void MapBOToEF()
        {
            var mapper = new DALTransactionStatusMapper();
            var bo     = new BOTransactionStatus();

            bo.SetProperties(1, "A");

            TransactionStatus response = mapper.MapBOToEF(bo);

            response.Id.Should().Be(1);
            response.Name.Should().Be("A");
        }
Exemplo n.º 5
0
        public void MapBOToModelList()
        {
            var mapper             = new BOLTransactionStatusMapper();
            BOTransactionStatus bo = new BOTransactionStatus();

            bo.SetProperties(1, "A");
            List <ApiTransactionStatusResponseModel> response = mapper.MapBOToModel(new List <BOTransactionStatus>()
            {
                { bo }
            });

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