Exemplo n.º 1
0
        public void MapEFToBOList()
        {
            var        mapper = new DALCreditCardMapper();
            CreditCard entity = new CreditCard();

            entity.SetProperties("A", "A", 1, 1, 1, DateTime.Parse("1/1/1987 12:00:00 AM"));

            List <BOCreditCard> response = mapper.MapEFToBO(new List <CreditCard>()
            {
                entity
            });

            response.Count.Should().Be(1);
        }
Exemplo n.º 2
0
        public void MapEFToBO()
        {
            var        mapper = new DALCreditCardMapper();
            CreditCard entity = new CreditCard();

            entity.SetProperties("A", "A", 1, 1, 1, DateTime.Parse("1/1/1987 12:00:00 AM"));

            BOCreditCard response = mapper.MapEFToBO(entity);

            response.CardNumber.Should().Be("A");
            response.CardType.Should().Be("A");
            response.CreditCardID.Should().Be(1);
            response.ExpMonth.Should().Be(1);
            response.ExpYear.Should().Be(1);
            response.ModifiedDate.Should().Be(DateTime.Parse("1/1/1987 12:00:00 AM"));
        }