private async Task <ApiDashboardConfigurationResponseModel> CreateRecord() { var model = new ApiDashboardConfigurationRequestModel(); model.SetProperties("B", "B", "B", "B", "B"); CreateResponse <ApiDashboardConfigurationResponseModel> result = await this.Client.DashboardConfigurationCreateAsync(model); result.Success.Should().BeTrue(); return(result.Record); }
public void MapModelToBO() { var mapper = new BOLDashboardConfigurationMapper(); ApiDashboardConfigurationRequestModel model = new ApiDashboardConfigurationRequestModel(); model.SetProperties("A", "A", "A", "A", "A"); BODashboardConfiguration response = mapper.MapModelToBO("A", model); response.IncludedEnvironmentIds.Should().Be("A"); response.IncludedProjectIds.Should().Be("A"); response.IncludedTenantIds.Should().Be("A"); response.IncludedTenantTags.Should().Be("A"); response.JSON.Should().Be("A"); }
public void MapRequestToResponse() { var mapper = new ApiDashboardConfigurationModelMapper(); var model = new ApiDashboardConfigurationRequestModel(); model.SetProperties("A", "A", "A", "A", "A"); ApiDashboardConfigurationResponseModel response = mapper.MapRequestToResponse("A", model); response.Id.Should().Be("A"); response.IncludedEnvironmentIds.Should().Be("A"); response.IncludedProjectIds.Should().Be("A"); response.IncludedTenantIds.Should().Be("A"); response.IncludedTenantTags.Should().Be("A"); response.JSON.Should().Be("A"); }
public void CreatePatch() { var mapper = new ApiDashboardConfigurationModelMapper(); var model = new ApiDashboardConfigurationRequestModel(); model.SetProperties("A", "A", "A", "A", "A"); JsonPatchDocument <ApiDashboardConfigurationRequestModel> patch = mapper.CreatePatch(model); var response = new ApiDashboardConfigurationRequestModel(); patch.ApplyTo(response); response.IncludedEnvironmentIds.Should().Be("A"); response.IncludedProjectIds.Should().Be("A"); response.IncludedTenantIds.Should().Be("A"); response.IncludedTenantTags.Should().Be("A"); response.JSON.Should().Be("A"); }