1 write to Value
Microsoft.AspNetCore.Mvc.Core (1)
ObjectResult.cs (1)
24Value = value;
94 references to Value
Microsoft.AspNetCore.Mvc.Core (6)
ApiBehaviorOptions.cs (1)
87/// instance where the <see cref="ObjectResult.Value"/> is <see cref="ProblemDetails"/>.
Infrastructure\ObjectResultExecutor.cs (3)
76objectType = result.Value?.GetType(); 79var value = result.Value; 134if (result.Value is ProblemDetails)
MvcOptions.cs (1)
364/// When <see cref="ObjectResult.Value" /> is an instance of <see cref="IAsyncEnumerable{T}"/>,
ObjectResult.cs (1)
73if (Value is ProblemDetails details)
Microsoft.AspNetCore.Mvc.Core.Test (65)
AcceptedAtActionResultTests.cs (1)
103Assert.Same(value, result.Value);
AcceptedAtRouteResultTests.cs (1)
44Assert.Same(value, result.Value);
AcceptedResultTests.cs (1)
40Assert.Same(value, result.Value);
ActionResultOfTTest.cs (3)
72Assert.Same(value, objectResult.Value); 90Assert.Same(value, objectResult.Value); 108Assert.Same(value, objectResult.Value);
BadRequestObjectResultTests.cs (2)
20Assert.Equal(obj, badRequestObjectResult.Value); 31var errors = Assert.IsType<SerializableError>(badRequestObjectResult.Value);
ConflictObjectResultTest.cs (2)
20Assert.Equal(obj, conflictObjectResult.Value); 31var errors = Assert.IsType<SerializableError>(conflictObjectResult.Value);
ControllerBaseTest.cs (19)
1510Assert.Same(value, result.Value); 2002Assert.Equal("Test Content", result.Value); 2046Assert.Equal(obj, result.Value); 2061var errors = Assert.IsType<SerializableError>(result.Value); 2092Assert.Equal(obj, result.Value); 2107var errors = Assert.IsType<SerializableError>(result.Value); 2139Assert.Equal(obj, result.Value); 2154var errors = Assert.IsType<SerializableError>(result.Value); 2299Assert.Equal(value, result.Value); 2316Assert.Equal(value, result.Value); 2356var problemDetails = Assert.IsType<ValidationProblemDetails>(badRequestResult.Value); 2384var problemDetails = Assert.IsType<ValidationProblemDetails>(badRequestResult.Value); 2406var problemDetails = Assert.IsType<ValidationProblemDetails>(objectResult.Value); 2427var problemDetails = Assert.IsType<ValidationProblemDetails>(badRequestResult.Value); 2448var problemDetails = Assert.IsType<ValidationProblemDetails>(objectResult.Value); 2475var problemDetails = Assert.IsType<ProblemDetails>(badRequestResult.Value); 2501var problemDetails = Assert.IsType<ProblemDetails>(badRequestResult.Value); 2525var problemDetails = Assert.IsType<ProblemDetails>(badRequestResult.Value); 2546var problemDetails = Assert.IsType<ProblemDetails>(badRequestResult.Value);
DependencyInjection\ApiBehaviorOptionsSetupTest.cs (5)
44var problemDetails = Assert.IsType<ValidationProblemDetails>(badRequest.Value); 66var problemDetails = Assert.IsType<ValidationProblemDetails>(badRequest.Value); 90var problemDetails = Assert.IsType<ValidationProblemDetails>(objectResult.Value); 109var problemDetails = Assert.IsType<ValidationProblemDetails>(badRequest.Value); 126var problemDetails = Assert.IsType<ValidationProblemDetails>(badRequest.Value);
HttpNotFoundObjectResultTest.cs (1)
33Assert.Equal("Test Content", notFound.Value);
HttpOkObjectResultTest.cs (1)
43Assert.Same(value, result.Value);
Infrastructure\ActionMethodExecutorTest.cs (12)
113Assert.NotNull(result.Value); 114Assert.IsType<TestModel>(result.Value); 142Assert.NotNull(result.Value); 143Assert.IsType<TestModel>(result.Value); 171Assert.NotNull(result.Value); 172Assert.IsType<TestModel>(result.Value); 328Assert.NotNull(result.Value); 329Assert.IsType<TestModel>(result.Value); 357Assert.NotNull(result.Value); 358Assert.IsType<TestModel>(result.Value); 411Assert.NotNull(result.Value); 412Assert.IsType<TestModel>(result.Value);
Infrastructure\ActionResultTypeMapperTest.cs (1)
71Assert.Same(returnValue, objectResult.Value);
Infrastructure\ControllerActionInvokerTest.cs (9)
900Assert.Equal(inputParam1, contentResult.Value); 995Assert.Equal(inputString, contentResult.Value); 1045Assert.Equal("hello", contentResult.Value); 1072Assert.Equal(inputString, contentResult.Value); 1098Assert.Equal("world", contentResult.Value); 1125Assert.Equal(inputString, contentResult.Value); 1182Assert.IsType<int>(((ObjectResult)result).Value); 1183Assert.Equal(1, ((ObjectResult)result).Value); 1291Assert.Equal(inputParam1, contentResult.Value);
Infrastructure\ProblemDetalsClientErrorFactoryTest.cs (4)
32var problemDetails = Assert.IsType<ProblemDetails>(objectResult.Value); 59var problemDetails = Assert.IsType<ProblemDetails>(objectResult.Value); 89var problemDetails = Assert.IsType<ProblemDetails>(objectResult.Value); 115var problemDetails = Assert.IsType<ProblemDetails>(objectResult.Value);
ObjectResultTests.cs (1)
27Assert.Equal(input, result.Value);
UnprocessableEntityObjectResultTests.cs (2)
20Assert.Equal(obj, result.Value); 31var errors = Assert.IsType<SerializableError>(result.Value);
Microsoft.AspNetCore.Mvc.RazorPages.Test (8)
PageModelTest.cs (4)
1532Assert.Equal("Test Content", result.Value); 1561Assert.Equal("Test Content", result.Value); 1684Assert.Equal(value, result.Value); 1701Assert.Equal(value, result.Value);
PageTest.cs (4)
1522Assert.Equal("Test Content", result.Value); 1551Assert.Equal("Test Content", result.Value); 1674Assert.Equal(value, result.Value); 1691Assert.Equal(value, result.Value);
Microsoft.AspNetCore.Mvc.ViewFeatures.Test (15)
ControllerUnitTestabilityTests.cs (15)
98Assert.Equal(content, createdResult.Value); 118Assert.Equal(content, acceptedResult.Value); 268Assert.Equal("Test Content", httpNotFoundObjectResult.Value); 302Assert.Same(error, httpBadRequest.Value); 315Assert.Null(httpBadRequest.Value); 337Assert.Same(value, createdAtRouteResult.Value); 351Assert.Null(createdAtRouteResult.Value); 373Assert.Same(value, acceptedAtRouteResult.Value); 387Assert.Null(acceptedAtRouteResult.Value); 411Assert.Same(value, createdAtActionResult.Value); 425Assert.Null(createdAtActionResult.Value); 450Assert.Same(value, acceptedAtActionResult.Value); 464Assert.Null(acceptedAtActionResult.Value); 694var problemDetails = Assert.IsType<ProblemDetails>(badRequest.Value); 711var validationProblemDetails = Assert.IsType<ValidationProblemDetails>(badRequest.Value);