diff --git a/src/Swashbuckle.AspNetCore.SwaggerGen/SwaggerGenerator/SwaggerGenerator.cs b/src/Swashbuckle.AspNetCore.SwaggerGen/SwaggerGenerator/SwaggerGenerator.cs index cd135fa58e..24a37fcafd 100644 --- a/src/Swashbuckle.AspNetCore.SwaggerGen/SwaggerGenerator/SwaggerGenerator.cs +++ b/src/Swashbuckle.AspNetCore.SwaggerGen/SwaggerGenerator/SwaggerGenerator.cs @@ -709,7 +709,7 @@ private static bool IsFromFormAttributeUsedWithIFormFile(ApiParameterDescription new KeyValuePair("416", "Range Not Satisfiable"), new KeyValuePair("417", "Expectation Failed"), new KeyValuePair("421", "Misdirected Request"), - new KeyValuePair("422", "Unprocessable Entity"), + new KeyValuePair("422", "Unprocessable Content"), new KeyValuePair("423", "Locked"), new KeyValuePair("424", "Failed Dependency"), new KeyValuePair("426", "Upgrade Required"), diff --git a/test/Swashbuckle.AspNetCore.SwaggerGen.Test/SwaggerGenerator/SwaggerGeneratorTests.cs b/test/Swashbuckle.AspNetCore.SwaggerGen.Test/SwaggerGenerator/SwaggerGeneratorTests.cs index 07ece05c3e..185d649282 100644 --- a/test/Swashbuckle.AspNetCore.SwaggerGen.Test/SwaggerGenerator/SwaggerGeneratorTests.cs +++ b/test/Swashbuckle.AspNetCore.SwaggerGen.Test/SwaggerGenerator/SwaggerGeneratorTests.cs @@ -969,7 +969,7 @@ public void GetSwagger_GeneratesResponses_ForSupportedResponseTypes() Assert.Equal("Bad Request", response400.Description); Assert.Empty(response400.Content.Keys); var response422 = operation.Responses["422"]; - Assert.Equal("Unprocessable Entity", response422.Description); + Assert.Equal("Unprocessable Content", response422.Description); Assert.Empty(response422.Content.Keys); var responseDefault = operation.Responses["default"]; Assert.Equal("Error", responseDefault.Description);