public async Task CanDescribeLegend(string rootUrl, string mapUrl) { var gateway = new PortalGateway(rootUrl); var layerResponse = await IntegrationTestFixture.TestPolicy.Execute(() => { return(gateway.DescribeLegends(mapUrl.AsEndpoint())); }); Assert.NotNull(layerResponse); Assert.Null(layerResponse.Error); Assert.NotNull(layerResponse.Layers); Assert.True(layerResponse.Layers.Any()); }
public async Task CanDescribeLegend2(string rootUrl, string mapUrl, int?dpi, int?size) { var gateway = new PortalGateway(rootUrl); var request = new LegendsDescription(mapUrl.AsEndpoint()); request.Dpi = dpi; if (size.HasValue) { request.Size = new List <int>(); request.Size.Add(size.Value); request.Size.Add(size.Value); } var layerResponse = await IntegrationTestFixture.TestPolicy.Execute(() => { return(gateway.DescribeLegends(request)); }); Assert.NotNull(layerResponse); Assert.Null(layerResponse.Error); Assert.NotNull(layerResponse.Layers); Assert.True(layerResponse.Layers.Any()); }