65 references to SupportedResponseTypes
ApiExplorerWebSite (1)
ApiExplorerDataFilter.cs (1)
95foreach (var response in description.SupportedResponseTypes)
Microsoft.AspNetCore.Grpc.Swagger (2)
Internal\GrpcJsonTranscodingDescriptionProvider.cs (2)
80apiDescription.SupportedResponseTypes.Add(new ApiResponseType 86apiDescription.SupportedResponseTypes.Add(new ApiResponseType
Microsoft.AspNetCore.Mvc.ApiExplorer (2)
DefaultApiDescriptionProvider.cs (1)
121apiDescription.SupportedResponseTypes.Add(apiResponseType);
EndpointMetadataApiDescriptionProvider.cs (1)
165AddSupportedResponseTypes(apiDescription.SupportedResponseTypes, methodInfo.ReturnType, routeEndpoint.Metadata);
Microsoft.AspNetCore.Mvc.ApiExplorer.Test (58)
DefaultApiDescriptionProviderTest.cs (24)
499var responseType = Assert.Single(description.SupportedResponseTypes); 517var responseType = Assert.Single(description.SupportedResponseTypes); 536var responseType = Assert.Single(description.SupportedResponseTypes); 558var responseType = Assert.Single(description.SupportedResponseTypes); 576var responseType = Assert.Single(description.SupportedResponseTypes); 592var responseType = Assert.Single(description.SupportedResponseTypes); 608var responseType = Assert.Single(description.SupportedResponseTypes); 633Assert.Empty(description.SupportedResponseTypes); 699Assert.Equal(4, description.SupportedResponseTypes.Count); 702description.SupportedResponseTypes.OrderBy(responseType => responseType.StatusCode), 809Assert.Equal(3, description.SupportedResponseTypes.Count); 812description.SupportedResponseTypes.OrderBy(responseType => responseType.StatusCode), 872Assert.Equal(4, description.SupportedResponseTypes.Count); 875description.SupportedResponseTypes.OrderBy(responseType => responseType.StatusCode), 942Assert.Equal(4, description.SupportedResponseTypes.Count); 945description.SupportedResponseTypes.OrderBy(responseType => responseType.StatusCode), 1012Assert.Equal(4, description.SupportedResponseTypes.Count); 1015description.SupportedResponseTypes.OrderBy(responseType => responseType.StatusCode), 1060var responseType = Assert.Single(description.SupportedResponseTypes); 1085var responseType = Assert.Single(description.SupportedResponseTypes); 1124var responseTypes = Assert.Single(description.SupportedResponseTypes); 1148var responseType = Assert.Single(description.SupportedResponseTypes); 1168var responseType = Assert.Single(description.SupportedResponseTypes); 1200var responseType = Assert.Single(description.SupportedResponseTypes);
EndpointMetadataApiDescriptionProviderTest.cs (34)
137var responseType = Assert.Single(apiDescription.SupportedResponseTypes); 156var responseType = Assert.Single(apiDescription.SupportedResponseTypes); 171var responseType = Assert.Single(apiDescription.SupportedResponseTypes); 192Assert.Equal(2, apiDescription.SupportedResponseTypes.Count); 194var inferredResponseType = apiDescription.SupportedResponseTypes[0]; 202var annotatedResponseType = apiDescription.SupportedResponseTypes[1]; 219Assert.Equal(3, apiDescription.SupportedResponseTypes.Count); 221var rdfInferredResponseType = apiDescription.SupportedResponseTypes[0]; 230var createdResponseType = apiDescription.SupportedResponseTypes[1]; 239var badRequestResponseType = apiDescription.SupportedResponseTypes[2]; 257Assert.Equal(2, apiDescription.SupportedResponseTypes.Count); 259var createdResponseType = apiDescription.SupportedResponseTypes[0]; 268var badRequestResponseType = apiDescription.SupportedResponseTypes[1]; 283Assert.Equal(2, apiDescription.SupportedResponseTypes.Count); 285var createdResponseType = apiDescription.SupportedResponseTypes[0]; 294var badRequestResponseType = apiDescription.SupportedResponseTypes[1]; 308Assert.Single(apiDescription.SupportedResponseTypes); 310var createdResponseType = apiDescription.SupportedResponseTypes[0]; 326Assert.Single(apiDescription.SupportedResponseTypes); 328var responseType = apiDescription.SupportedResponseTypes[0]; 341Assert.Single(apiDescription.SupportedResponseTypes); 343var createdResponseType = apiDescription.SupportedResponseTypes[0]; 362Assert.Equal(2, apiDescription.SupportedResponseTypes.Count); 364var createdResponseType = apiDescription.SupportedResponseTypes[0]; 373var badRequestResponseType = apiDescription.SupportedResponseTypes[1]; 396Assert.Equal(2, apiDescription.SupportedResponseTypes.Count); 398var createdResponseType = apiDescription.SupportedResponseTypes[0]; 407var badRequestResponseType = apiDescription.SupportedResponseTypes[1]; 850Assert.Contains(apiDescription.SupportedResponseTypes, m => m is { StatusCode: 400, Type: { } type } && type == typeof(ProblemDetails)); 851Assert.Contains(apiDescription.SupportedResponseTypes, m => m is { StatusCode: 200, Type: { } type } && type == typeof(string)); 875var responseTypes = Assert.Single(apiDescription.SupportedResponseTypes); 927context.Results.SelectMany(r => r.SupportedResponseTypes).OrderBy(r => r.StatusCode), 977context.Results.SelectMany(r => r.SupportedResponseTypes).OrderBy(r => r.StatusCode), 1077context.Results.SelectMany(r => r.SupportedResponseTypes).OrderBy(r => r.StatusCode),
Microsoft.AspNetCore.OpenApi (2)
Services\OpenApiDocumentService.cs (2)
328if (description.SupportedResponseTypes.Count == 0) 337foreach (var responseType in description.SupportedResponseTypes)