48 references to MetadataSource
Microsoft.AspNetCore.Http.Extensions.Tests (48)
RequestDelegateFactoryTests.cs (27)
2572m => Assert.True(m is CustomEndpointMetadata { Source: MetadataSource.Parameter })); 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 }); 2677new CustomEndpointMetadata { Source = MetadataSource.Caller } 2685Assert.Contains(result.EndpointMetadata, m => m is CustomEndpointMetadata { Source: MetadataSource.Caller }); 2699new CustomEndpointMetadata { Source = MetadataSource.Caller } 2707Assert.Contains(result.EndpointMetadata, m => m is CustomEndpointMetadata { Source: MetadataSource.Caller }); 2722new CustomEndpointMetadata { Source = MetadataSource.Caller } 2730Assert.Contains(result.EndpointMetadata, m => m is CustomEndpointMetadata { Source: MetadataSource.Caller }); 2745new CustomEndpointMetadata { Source = MetadataSource.Caller } 2753Assert.Contains(result.EndpointMetadata, m => m is CustomEndpointMetadata { Source: MetadataSource.Caller }); 2768new CustomEndpointMetadata { Source = MetadataSource.Caller } 2776Assert.Contains(result.EndpointMetadata, m => m is CustomEndpointMetadata { Source: MetadataSource.Caller }); 2789new CustomEndpointMetadata { Source = MetadataSource.Caller } 2797Assert.Contains(result.EndpointMetadata, m => m is CustomEndpointMetadata { Source: MetadataSource.Caller }); 2798Assert.Contains(result.EndpointMetadata, m => m is CustomEndpointMetadata { Source: MetadataSource.Parameter }); 2810new CustomEndpointMetadata { Source = MetadataSource.Caller } 2822m => Assert.True(m is CustomEndpointMetadata { Source: MetadataSource.Caller }), 2832m => Assert.True(m is CustomEndpointMetadata { Source: MetadataSource.Parameter }), 3330builder.Metadata.Add(new CustomEndpointMetadata { Source = MetadataSource.ReturnType }); 3431builder.Metadata.Add(new CustomEndpointMetadata { Source = MetadataSource.Property }); 3456builder.Metadata.Add(new CustomEndpointMetadata { Source = MetadataSource.Parameter }); 3479builder.Metadata.Add(new CustomEndpointMetadata { Source = MetadataSource.Parameter }); 3510public MetadataSource Source { get; init; }
RequestDelegateGenerator\RequestDelegateCreationTests.Metadata.cs (16)
227Assert.Contains(endpoint.Metadata, m => m is CustomEndpointMetadata { Source: MetadataSource.Parameter }); 242Assert.Contains(endpoint.Metadata, m => m is CustomEndpointMetadata { Source: MetadataSource.ReturnType }); 257Assert.Contains(endpoint.Metadata, m => m is CustomEndpointMetadata { Source: MetadataSource.ReturnType }); 272Assert.Contains(endpoint.Metadata, m => m is CustomEndpointMetadata { Source: MetadataSource.ReturnType }); 402Assert.Contains(endpoint.Metadata, m => m is CustomEndpointMetadata { Source: MetadataSource.Caller }); 419Assert.Contains(endpoint.Metadata, m => m is CustomEndpointMetadata { Source: MetadataSource.Caller }); 436Assert.Contains(endpoint.Metadata, m => m is CustomEndpointMetadata { Source: MetadataSource.Caller }); 453Assert.Contains(endpoint.Metadata, m => m is CustomEndpointMetadata { Source: MetadataSource.Caller }); 469Assert.Contains(endpoint.Metadata, m => m is CustomEndpointMetadata { Source: MetadataSource.Caller }); 470Assert.Contains(endpoint.Metadata, m => m is CustomEndpointMetadata { Source: MetadataSource.Parameter }); 485Assert.Contains(endpoint.Metadata, m => m is CustomEndpointMetadata { Source: MetadataSource.Caller }); 486Assert.Contains(endpoint.Metadata, m => m is CustomEndpointMetadata { Source: MetadataSource.Parameter }); 540m => Assert.True(m is CustomEndpointMetadata { Source: MetadataSource.Parameter }), 544m => Assert.True(m is CustomEndpointMetadata { Source: MetadataSource.Caller })); 560Assert.Contains(endpoint.Metadata, m => m is CustomEndpointMetadata { Source: MetadataSource.Parameter }); 562Assert.Contains(endpoint.Metadata, m => m is CustomEndpointMetadata { Source: MetadataSource.Property });
RequestDelegateGenerator\SharedTypes.cs (5)
566builder.Metadata.Add(new CustomEndpointMetadata { Source = MetadataSource.Parameter }); 574public MetadataSource Source { get; init; } 601builder.Metadata.Add(new CustomEndpointMetadata { Source = MetadataSource.Parameter }); 614builder.Metadata.Add(new CustomEndpointMetadata { Source = MetadataSource.Property }); 621builder.Metadata.Add(new CustomEndpointMetadata { Source = MetadataSource.ReturnType });