Beispiel #1
0
        public void MapModelToBO()
        {
            var mapper = new BOLTeamMapper();
            ApiTeamRequestModel model = new ApiTeamRequestModel();

            model.SetProperties("A", 1);
            BOTeam response = mapper.MapModelToBO(1, model);

            response.Name.Should().Be("A");
            response.OrganizationId.Should().Be(1);
        }
Beispiel #2
0
        public void MapBOToModel()
        {
            var    mapper = new BOLTeamMapper();
            BOTeam bo     = new BOTeam();

            bo.SetProperties(1, "A", 1);
            ApiTeamResponseModel response = mapper.MapBOToModel(bo);

            response.Id.Should().Be(1);
            response.Name.Should().Be("A");
            response.OrganizationId.Should().Be(1);
        }
Beispiel #3
0
        public void MapBOToModelList()
        {
            var    mapper = new BOLTeamMapper();
            BOTeam bo     = new BOTeam();

            bo.SetProperties(1, "A", 1);
            List <ApiTeamResponseModel> response = mapper.MapBOToModel(new List <BOTeam>()
            {
                { bo }
            });

            response.Count.Should().Be(1);
        }
Beispiel #4
0
        public void MapModelToBO()
        {
            var mapper = new BOLTeamMapper();
            ApiTeamRequestModel model = new ApiTeamRequestModel();

            model.SetProperties("A", "A", "A", "A", "A", "A", "A", "A");
            BOTeam response = mapper.MapModelToBO("A", model);

            response.EnvironmentIds.Should().Be("A");
            response.JSON.Should().Be("A");
            response.MemberUserIds.Should().Be("A");
            response.Name.Should().Be("A");
            response.ProjectGroupIds.Should().Be("A");
            response.ProjectIds.Should().Be("A");
            response.TenantIds.Should().Be("A");
            response.TenantTags.Should().Be("A");
        }
Beispiel #5
0
        public void MapBOToModel()
        {
            var    mapper = new BOLTeamMapper();
            BOTeam bo     = new BOTeam();

            bo.SetProperties("A", "A", "A", "A", "A", "A", "A", "A", "A");
            ApiTeamResponseModel response = mapper.MapBOToModel(bo);

            response.EnvironmentIds.Should().Be("A");
            response.Id.Should().Be("A");
            response.JSON.Should().Be("A");
            response.MemberUserIds.Should().Be("A");
            response.Name.Should().Be("A");
            response.ProjectGroupIds.Should().Be("A");
            response.ProjectIds.Should().Be("A");
            response.TenantIds.Should().Be("A");
            response.TenantTags.Should().Be("A");
        }