21 references to ProducesErrorResponseTypeAttribute
Microsoft.AspNetCore.Mvc.ApiExplorer.Test (8)
ApiResponseTypeProviderTest.cs (8)
339
actionDescriptor.Properties[typeof(ProducesErrorResponseTypeAttribute)] = new
ProducesErrorResponseTypeAttribute
(errorType);
391
actionDescriptor.Properties[typeof(ProducesErrorResponseTypeAttribute)] = new
ProducesErrorResponseTypeAttribute
(errorType);
434
actionDescriptor.Properties[typeof(ProducesErrorResponseTypeAttribute)] = new
ProducesErrorResponseTypeAttribute
(errorType);
485
actionDescriptor.Properties[typeof(ProducesErrorResponseTypeAttribute)] = new
ProducesErrorResponseTypeAttribute
(typeof(InvalidTimeZoneException));
531
actionDescriptor.Properties[typeof(ProducesErrorResponseTypeAttribute)] = new
ProducesErrorResponseTypeAttribute
(typeof(void));
577
actionDescriptor.Properties[typeof(ProducesErrorResponseTypeAttribute)] = new
ProducesErrorResponseTypeAttribute
(typeof(ProblemDetails));
627
actionDescriptor.Properties[typeof(ProducesErrorResponseTypeAttribute)] = new
ProducesErrorResponseTypeAttribute
(typeof(ProblemDetails));
657
actionDescriptor.Properties[typeof(ProducesErrorResponseTypeAttribute)] = new
ProducesErrorResponseTypeAttribute
(typeof(ProblemDetails));
Microsoft.AspNetCore.Mvc.Core (1)
ApplicationModels\ApiBehaviorApplicationModelProvider.cs (1)
44
var defaultErrorTypeAttribute = new
ProducesErrorResponseTypeAttribute
(defaultErrorType);
Microsoft.AspNetCore.Mvc.Core.Test (6)
ApplicationModels\ApiConventionApplicationModelConventionTest.cs (6)
10
[assembly:
ProducesErrorResponseType
(typeof(InvalidEnumArgumentException))]
104
controllerAttributes: new[] { new
ProducesErrorResponseTypeAttribute
(expected) });
122
actionAttributes: new[] { new
ProducesErrorResponseTypeAttribute
(expected) },
123
controllerAttributes: new[] { new
ProducesErrorResponseTypeAttribute
(typeof(Guid)) });
139
var action = GetActionModel(nameof(TestController.Delete), new[] { new
ProducesErrorResponseTypeAttribute
(expected) });
153
return new ApiConventionApplicationModelConvention(new
ProducesErrorResponseTypeAttribute
(errorType));
Mvc.Api.Analyzers.Test (6)
TestFiles\AddResponseTypeAttributeCodeFixProviderIntegrationTest\CodeFixAddsResponseTypeWhenDifferentFromErrorType.Input.cs (1)
3
[
ProducesErrorResponseType
(typeof(CodeFixAddsResponseTypeWhenDifferentErrorModel))]
TestFiles\AddResponseTypeAttributeCodeFixProviderIntegrationTest\CodeFixAddsResponseTypeWhenDifferentFromErrorType.Output.cs (1)
5
[
ProducesErrorResponseType
(typeof(CodeFixAddsResponseTypeWhenDifferentErrorModel))]
TestFiles\SymbolApiResponseMetadataProviderTest\GetErrorResponseType_ReturnsTypeDefinedAtAction.cs (2)
8
[
ProducesErrorResponseType
(typeof(ModelStateDictionary))]
11
[
ProducesErrorResponseType
(typeof(GetErrorResponseType_ReturnsTypeDefinedAtActionModel))]
TestFiles\SymbolApiResponseMetadataProviderTest\GetErrorResponseType_ReturnsTypeDefinedAtAssembly.cs (1)
6
[assembly:
ProducesErrorResponseType
(typeof(Microsoft.AspNetCore.Mvc.Api.Analyzers.TestFiles.SymbolApiResponseMetadataProviderTest.GetErrorResponseType_ReturnsTypeDefinedAtAssemblyModel))]
TestFiles\SymbolApiResponseMetadataProviderTest\GetErrorResponseType_ReturnsTypeDefinedAtController.cs (1)
6
[
ProducesErrorResponseType
(typeof(GetErrorResponseType_ReturnsTypeDefinedAtControllerModel))]