Beispiel #1
0
        public virtual MachineRefTeam MapBOToEF(
            BOMachineRefTeam bo)
        {
            MachineRefTeam efMachineRefTeam = new MachineRefTeam();

            efMachineRefTeam.SetProperties(
                bo.Id,
                bo.MachineId,
                bo.TeamId);
            return(efMachineRefTeam);
        }
        public void MapEFToBO()
        {
            var            mapper = new DALMachineRefTeamMapper();
            MachineRefTeam entity = new MachineRefTeam();

            entity.SetProperties(1, 1, 1);

            BOMachineRefTeam response = mapper.MapEFToBO(entity);

            response.Id.Should().Be(1);
            response.MachineId.Should().Be(1);
            response.TeamId.Should().Be(1);
        }
        public void MapEFToBOList()
        {
            var            mapper = new DALMachineRefTeamMapper();
            MachineRefTeam entity = new MachineRefTeam();

            entity.SetProperties(1, 1, 1);

            List <BOMachineRefTeam> response = mapper.MapEFToBO(new List <MachineRefTeam>()
            {
                entity
            });

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