예제 #1
0
        public void MapEFToBO()
        {
            var          mapper = new DALLessonStatusMapper();
            LessonStatus entity = new LessonStatus();

            entity.SetProperties(1, "A", 1);

            BOLessonStatus response = mapper.MapEFToBO(entity);

            response.Id.Should().Be(1);
            response.Name.Should().Be("A");
            response.StudioId.Should().Be(1);
        }
예제 #2
0
        public void MapBOToEF()
        {
            var mapper = new DALLessonStatusMapper();
            var bo     = new BOLessonStatus();

            bo.SetProperties(1, "A", 1);

            LessonStatus response = mapper.MapBOToEF(bo);

            response.Id.Should().Be(1);
            response.Name.Should().Be("A");
            response.StudioId.Should().Be(1);
        }
예제 #3
0
        public void MapEFToBOList()
        {
            var          mapper = new DALLessonStatusMapper();
            LessonStatus entity = new LessonStatus();

            entity.SetProperties(1, "A", 1);

            List <BOLessonStatus> response = mapper.MapEFToBO(new List <LessonStatus>()
            {
                entity
            });

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