1 write to EndpointMetadata
Microsoft.AspNetCore.Http.Abstractions (1)
RequestDelegateResult.cs (1)
17EndpointMetadata = metadata;
42 references to EndpointMetadata
Microsoft.AspNetCore.Http.Extensions (1)
RequestDelegateFactoryOptions.cs (1)
43/// Any metadata already in <see cref="EndpointBuilder.Metadata"/> will be included in <see cref="RequestDelegateResult.EndpointMetadata" /> <b>before</b>
Microsoft.AspNetCore.Http.Extensions.Tests (40)
RequestDelegateFactoryTests.cs (40)
2527Assert.Empty(result.EndpointMetadata); 2536var responseMetadata = Assert.IsAssignableFrom<IProducesResponseTypeMetadata>(Assert.Single(result.EndpointMetadata)); 2548var responseMetadata = Assert.IsAssignableFrom<IProducesResponseTypeMetadata>(Assert.Single(result.EndpointMetadata)); 2568Assert.Collection(result.EndpointMetadata, 2586Assert.Empty(result.EndpointMetadata); 2599Assert.Contains(result.EndpointMetadata, m => m is ParameterNameMetadata { Name: "param1" }); 2600Assert.Contains(result.EndpointMetadata, m => m is ParameterNameMetadata { Name: "param2" }); 2613Assert.Contains(result.EndpointMetadata, m => m is CustomEndpointMetadata { Source: MetadataSource.Parameter }); 2626Assert.Contains(result.EndpointMetadata, m => m is CustomEndpointMetadata { Source: MetadataSource.ReturnType }); 2639Assert.Contains(result.EndpointMetadata, m => m is CustomEndpointMetadata { Source: MetadataSource.ReturnType }); 2652Assert.Contains(result.EndpointMetadata, m => m is CustomEndpointMetadata { Source: MetadataSource.ReturnType }); 2665Assert.Contains(result.EndpointMetadata, m => m is CustomEndpointMetadata { Source: MetadataSource.ReturnType }); 2685Assert.Contains(result.EndpointMetadata, m => m is CustomEndpointMetadata { Source: MetadataSource.Caller }); 2687Assert.Contains(result.EndpointMetadata, m => m is MetadataCountMetadata { Count: 1 }); 2707Assert.Contains(result.EndpointMetadata, m => m is CustomEndpointMetadata { Source: MetadataSource.Caller }); 2708Assert.Contains(result.EndpointMetadata, m => m is ProducesResponseTypeMetadata { Type: { } type } && type == typeof(CountsDefaultEndpointMetadataResult)); 2710Assert.Contains(result.EndpointMetadata, m => m is MetadataCountMetadata { Count: 2 }); 2730Assert.Contains(result.EndpointMetadata, m => m is CustomEndpointMetadata { Source: MetadataSource.Caller }); 2731Assert.Contains(result.EndpointMetadata, m => m is ProducesResponseTypeMetadata { Type: { } type } && type == typeof(CountsDefaultEndpointMetadataResult)); 2733Assert.Contains(result.EndpointMetadata, m => m is MetadataCountMetadata { Count: 2 }); 2753Assert.Contains(result.EndpointMetadata, m => m is CustomEndpointMetadata { Source: MetadataSource.Caller }); 2754Assert.Contains(result.EndpointMetadata, m => m is IProducesResponseTypeMetadata { Type: { } type } && type == typeof(CountsDefaultEndpointMetadataResult)); 2756Assert.Contains(result.EndpointMetadata, m => m is MetadataCountMetadata { Count: 2 }); 2776Assert.Contains(result.EndpointMetadata, m => m is CustomEndpointMetadata { Source: MetadataSource.Caller }); 2777Assert.Contains(result.EndpointMetadata, m => m is ParameterNameMetadata { Name: "param1" }); 2797Assert.Contains(result.EndpointMetadata, m => m is CustomEndpointMetadata { Source: MetadataSource.Caller }); 2798Assert.Contains(result.EndpointMetadata, m => m is CustomEndpointMetadata { Source: MetadataSource.Parameter }); 2818Assert.Collection(result.EndpointMetadata, 2852Assert.Contains(result.EndpointMetadata, m => m is RoutePatternMetadata { RoutePattern: "/test/pattern" }); 2887Assert.Contains(result.EndpointMetadata, m => m is IParameterBindingMetadata { Name: "param1" }); 2888Assert.Same(options.EndpointBuilder.Metadata, result.EndpointMetadata); 2944Assert.DoesNotContain(result.EndpointMetadata, m => m is IAcceptsMetadata); 2957Assert.DoesNotContain(result.EndpointMetadata, m => m is IAcceptsMetadata); 2970Assert.DoesNotContain(result.EndpointMetadata, m => m is IAcceptsMetadata); 2983Assert.DoesNotContain(result.EndpointMetadata, m => m is IAcceptsMetadata); 2996Assert.DoesNotContain(result.EndpointMetadata, m => m is IAcceptsMetadata); 3010Assert.DoesNotContain(result.EndpointMetadata, m => m is IAcceptsMetadata); 3025Assert.Contains(result.EndpointMetadata, m => m is MetadataService); 3040Assert.Contains(result.EndpointMetadata, m => m is MetadataService); 3084Assert.Same(options.EndpointBuilder.Metadata, result.EndpointMetadata);
Microsoft.AspNetCore.Mvc.ApiExplorer.Test (1)
EndpointMetadataApiDescriptionProviderTest.cs (1)
1551var metadataItems = new List<object>(requestDelegateResult.EndpointMetadata) { methodInfo, httpMethodMetadata };