Example #1
0
        public void MapEFToBO()
        {
            var    mapper = new DALTenantMapper();
            Tenant entity = new Tenant();

            entity.SetProperties(1, "A");

            BOTenant response = mapper.MapEFToBO(entity);

            response.Id.Should().Be(1);
            response.Name.Should().Be("A");
        }
Example #2
0
        public void MapEFToBOList()
        {
            var    mapper = new DALTenantMapper();
            Tenant entity = new Tenant();

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

            List <BOTenant> response = mapper.MapEFToBO(new List <Tenant>()
            {
                entity
            });

            response.Count.Should().Be(1);
        }
Example #3
0
        public void MapEFToBO()
        {
            var    mapper = new DALTenantMapper();
            Tenant entity = new Tenant();

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

            BOTenant response = mapper.MapEFToBO(entity);

            response.DataVersion.Should().BeEquivalentTo(BitConverter.GetBytes(1));
            response.Id.Should().Be("A");
            response.JSON.Should().Be("A");
            response.Name.Should().Be("A");
            response.ProjectIds.Should().Be("A");
            response.TenantTags.Should().Be("A");
        }