140 references to AssertStatusCodeAsync
Microsoft.AspNetCore.Mvc.FunctionalTests (140)
ApiBehaviorTest.cs (16)
61await response.AssertStatusCodeAsync(HttpStatusCode.BadRequest); 112await response.AssertStatusCodeAsync(HttpStatusCode.UnsupportedMediaType); 128await response.AssertStatusCodeAsync(HttpStatusCode.UnsupportedMediaType); 156await response.AssertStatusCodeAsync(HttpStatusCode.OK); 177await response.AssertStatusCodeAsync(HttpStatusCode.OK); 193await response.AssertStatusCodeAsync(HttpStatusCode.OK); 210await response.AssertStatusCodeAsync(HttpStatusCode.OK); 230await response.AssertStatusCodeAsync(HttpStatusCode.OK); 251await response.AssertStatusCodeAsync(HttpStatusCode.OK); 269await response.AssertStatusCodeAsync(HttpStatusCode.OK); 284await response.AssertStatusCodeAsync(HttpStatusCode.OK); 298await response.AssertStatusCodeAsync(HttpStatusCode.NotFound); 327await response.AssertStatusCodeAsync(HttpStatusCode.NotFound); 345await response.AssertStatusCodeAsync(HttpStatusCode.NotFound); 358await response.AssertStatusCodeAsync(HttpStatusCode.BadRequest); 450await response.AssertStatusCodeAsync(HttpStatusCode.BadRequest);
AsyncActionsTests.cs (3)
302await response.AssertStatusCodeAsync(HttpStatusCode.OK); 312await response.AssertStatusCodeAsync(HttpStatusCode.NotFound); 322await response.AssertStatusCodeAsync(HttpStatusCode.OK);
AsyncEnumerableTestBase.cs (3)
45await response.AssertStatusCodeAsync(HttpStatusCode.OK); 63await response.AssertStatusCodeAsync(HttpStatusCode.InternalServerError); 82await response.AssertStatusCodeAsync(HttpStatusCode.OK);
AuthMiddlewareAndFilterTestBase.cs (10)
42await response.AssertStatusCodeAsync(HttpStatusCode.OK); 60await response.AssertStatusCodeAsync(HttpStatusCode.OK); 85await response.AssertStatusCodeAsync(HttpStatusCode.OK); 95await response.AssertStatusCodeAsync(HttpStatusCode.OK); 105await response.AssertStatusCodeAsync(HttpStatusCode.OK); 124await response.AssertStatusCodeAsync(HttpStatusCode.OK); 262await response.AssertStatusCodeAsync(HttpStatusCode.OK); 267await response.AssertStatusCodeAsync(HttpStatusCode.Redirect); 273await response.AssertStatusCodeAsync(HttpStatusCode.Redirect); 281await response.AssertStatusCodeAsync(HttpStatusCode.OK);
AuthMiddlewareUsingRequireAuthTest.cs (4)
51await response.AssertStatusCodeAsync(HttpStatusCode.OK); 70await response.AssertStatusCodeAsync(HttpStatusCode.OK); 75await response.AssertStatusCodeAsync(HttpStatusCode.Redirect); 83await response.AssertStatusCodeAsync(HttpStatusCode.OK);
BasicTests.cs (7)
539await response.AssertStatusCodeAsync(HttpStatusCode.OK); 562await response.AssertStatusCodeAsync(HttpStatusCode.OK); 584await response.AssertStatusCodeAsync(HttpStatusCode.OK); 604await response.AssertStatusCodeAsync(HttpStatusCode.OK); 616await response.AssertStatusCodeAsync(HttpStatusCode.OK); 628await response.AssertStatusCodeAsync(HttpStatusCode.BadRequest); 654await response.AssertStatusCodeAsync(HttpStatusCode.BadRequest);
ComponentRenderingFunctionalTests.cs (5)
42await response.AssertStatusCodeAsync(HttpStatusCode.OK); 58await response.AssertStatusCodeAsync(HttpStatusCode.OK); 75await response.AssertStatusCodeAsync(HttpStatusCode.Redirect); 89await response.AssertStatusCodeAsync(HttpStatusCode.OK); 167await response.AssertStatusCodeAsync(HttpStatusCode.OK);
CorsTestsBase.cs (1)
423await response.AssertStatusCodeAsync(HttpStatusCode.OK);
HtmlGenerationTest.cs (2)
138await response.AssertStatusCodeAsync(HttpStatusCode.OK); 796await response.AssertStatusCodeAsync(HttpStatusCode.OK);
HttpActionResultTests.cs (2)
41await response.AssertStatusCodeAsync(HttpStatusCode.OK); 55await response.AssertStatusCodeAsync(HttpStatusCode.NoContent);
Infrastructure\HttpClientExtensions.cs (1)
17await AssertStatusCodeAsync(response, HttpStatusCode.OK);
InputFormatterTests.cs (15)
94await response.AssertStatusCodeAsync(HttpStatusCode.OK); 106await response.AssertStatusCodeAsync(HttpStatusCode.BadRequest); 126await response.AssertStatusCodeAsync(HttpStatusCode.OK); 138await response.AssertStatusCodeAsync(HttpStatusCode.BadRequest); 158await response.AssertStatusCodeAsync(HttpStatusCode.OK); 170await response.AssertStatusCodeAsync(HttpStatusCode.BadRequest); 189await response.AssertStatusCodeAsync(HttpStatusCode.BadRequest); 207await response.AssertStatusCodeAsync(HttpStatusCode.BadRequest); 234await response.AssertStatusCodeAsync(HttpStatusCode.UnsupportedMediaType); 244await response.AssertStatusCodeAsync(HttpStatusCode.OK); 254await response.AssertStatusCodeAsync(HttpStatusCode.OK); 264await response.AssertStatusCodeAsync(HttpStatusCode.OK); 279await response.AssertStatusCodeAsync(HttpStatusCode.OK); 294await response.AssertStatusCodeAsync(HttpStatusCode.OK); 309await response.AssertStatusCodeAsync(HttpStatusCode.OK);
InputObjectValidationTests.cs (4)
277await response.AssertStatusCodeAsync(HttpStatusCode.InternalServerError); 298await response.AssertStatusCodeAsync(HttpStatusCode.BadRequest); 327await response.AssertStatusCodeAsync(HttpStatusCode.BadRequest); 359await response.AssertStatusCodeAsync(HttpStatusCode.BadRequest);
JsonInputFormatterTestBase.cs (2)
160await response.AssertStatusCodeAsync(HttpStatusCode.BadRequest); 191await response.AssertStatusCodeAsync(HttpStatusCode.OK);
JsonOutputFormatterTestBase.cs (10)
84await response.AssertStatusCodeAsync(HttpStatusCode.OK); 95await response.AssertStatusCodeAsync(HttpStatusCode.OK); 106await response.AssertStatusCodeAsync(HttpStatusCode.OK); 117await response.AssertStatusCodeAsync(HttpStatusCode.OK); 131await response.AssertStatusCodeAsync(HttpStatusCode.OK); 145await response.AssertStatusCodeAsync(HttpStatusCode.OK); 159await response.AssertStatusCodeAsync(HttpStatusCode.OK); 174await response.AssertStatusCodeAsync(HttpStatusCode.OK); 187await response.AssertStatusCodeAsync(HttpStatusCode.NotFound); 206await response.AssertStatusCodeAsync(HttpStatusCode.OK);
MvcSandboxTest.cs (2)
37await response.AssertStatusCodeAsync(HttpStatusCode.OK); 47await response.AssertStatusCodeAsync(HttpStatusCode.OK);
NewtonsoftJsonOutputFormatterTest.cs (2)
34await response.AssertStatusCodeAsync(HttpStatusCode.OK); 46await response.AssertStatusCodeAsync(HttpStatusCode.OK);
NonNullableReferenceTypesTest.cs (5)
41await response.AssertStatusCodeAsync(HttpStatusCode.OK); 65await response.AssertStatusCodeAsync(HttpStatusCode.OK); 83await response.AssertStatusCodeAsync(HttpStatusCode.OK); 109await response.AssertStatusCodeAsync(HttpStatusCode.Redirect); 119_ = await response.AssertStatusCodeAsync(HttpStatusCode.OK);
RazorBuildTest.cs (1)
72await response.AssertStatusCodeAsync(HttpStatusCode.OK);
RazorPagesTest.cs (3)
800await response.AssertStatusCodeAsync(HttpStatusCode.OK); 825await response.AssertStatusCodeAsync(HttpStatusCode.BadRequest); 1316await response.AssertStatusCodeAsync(HttpStatusCode.OK);
RazorPagesWithBasePathTest.cs (3)
688await response.AssertStatusCodeAsync(HttpStatusCode.OK); 716await response.AssertStatusCodeAsync(HttpStatusCode.OK); 748await response.AssertStatusCodeAsync(HttpStatusCode.OK);
RazorPagesWithEndpointRoutingTest.cs (4)
37await response.AssertStatusCodeAsync(HttpStatusCode.Redirect); 48await response.AssertStatusCodeAsync(HttpStatusCode.OK); 61await response.AssertStatusCodeAsync(HttpStatusCode.Redirect); 72await response.AssertStatusCodeAsync(HttpStatusCode.Redirect);
ReadFromDisconnectedClientTest.cs (2)
48await response.AssertStatusCodeAsync(HttpStatusCode.BadRequest); 65await response.AssertStatusCodeAsync(HttpStatusCode.BadRequest);
RequestFormLimitsTest.cs (2)
53await response.AssertStatusCodeAsync(HttpStatusCode.BadRequest); 149await response.AssertStatusCodeAsync(HttpStatusCode.BadRequest);
RoutingDynamicTest.cs (1)
171await response.AssertStatusCodeAsync(HttpStatusCode.OK);
RoutingTestsBase.cs (2)
1579await response.AssertStatusCodeAsync(HttpStatusCode.OK); 1591await response.AssertStatusCodeAsync(HttpStatusCode.OK);
SimpleWithWebApplicationBuilderTests.cs (11)
62await response.AssertStatusCodeAsync(HttpStatusCode.OK); 77await response.AssertStatusCodeAsync(HttpStatusCode.OK); 92await response.AssertStatusCodeAsync(HttpStatusCode.Accepted); 107await response.AssertStatusCodeAsync(HttpStatusCode.NotFound); 119await response.AssertStatusCodeAsync(HttpStatusCode.MovedPermanently); 132await response.AssertStatusCodeAsync(HttpStatusCode.OK); 225await response.AssertStatusCodeAsync(HttpStatusCode.OK); 240await response.AssertStatusCodeAsync(HttpStatusCode.UnsupportedMediaType); 255await response.AssertStatusCodeAsync(HttpStatusCode.Accepted); 276await response.AssertStatusCodeAsync(HttpStatusCode.OK); 292await response.AssertStatusCodeAsync(HttpStatusCode.BadRequest);
SystemTextJsonOutputFormatterTest.cs (4)
23await response.AssertStatusCodeAsync(HttpStatusCode.OK); 42await response.AssertStatusCodeAsync(HttpStatusCode.OK); 65await response.AssertStatusCodeAsync(HttpStatusCode.OK); 80await response.AssertStatusCodeAsync(HttpStatusCode.OK);
TempDataPropertyTest.cs (2)
48await redirectResponse.AssertStatusCodeAsync(HttpStatusCode.Redirect); 54await response.AssertStatusCodeAsync(HttpStatusCode.OK);
ViewEngineTests.cs (3)
81await response.AssertStatusCodeAsync(HttpStatusCode.OK); 258await response.AssertStatusCodeAsync(HttpStatusCode.OK); 429await response.AssertStatusCodeAsync(HttpStatusCode.OK);
XmlDataContractSerializerFormattersWrappingTest.cs (4)
235await response.AssertStatusCodeAsync(HttpStatusCode.NotFound); 262await response.AssertStatusCodeAsync(HttpStatusCode.NotFound); 277await response.AssertStatusCodeAsync(HttpStatusCode.BadRequest); 310await response.AssertStatusCodeAsync(HttpStatusCode.BadRequest);
XmlSerializerFormattersWrappingTest.cs (4)
218await response.AssertStatusCodeAsync(HttpStatusCode.NotFound); 245await response.AssertStatusCodeAsync(HttpStatusCode.NotFound); 260await response.AssertStatusCodeAsync(HttpStatusCode.BadRequest); 292await response.AssertStatusCodeAsync(HttpStatusCode.BadRequest);