示例#1
0
        public void MapEFToBOList()
        {
            var    mapper = new DALBadgesMapper();
            Badges entity = new Badges();

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

            List <BOBadges> response = mapper.MapEFToBO(new List <Badges>()
            {
                entity
            });

            response.Count.Should().Be(1);
        }
示例#2
0
        public void MapEFToBO()
        {
            var    mapper = new DALBadgesMapper();
            Badges entity = new Badges();

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

            BOBadges response = mapper.MapEFToBO(entity);

            response.Date.Should().Be(DateTime.Parse("1/1/1987 12:00:00 AM"));
            response.Id.Should().Be(1);
            response.Name.Should().Be("A");
            response.UserId.Should().Be(1);
        }