MY TESTED ASP.NET CORE MVC DOCS
  • Tutorial
  • Testing Guide
  • API Reference
  • Troubleshoot
  • About
  • API Reference
  • MyTested.AspNetCore.Mvc.Builders.Contracts.ActionResults.NotFound
  • INotFoundTestBuilder
Show / Hide Table of Contents
  • Common Classes & Extensions
    • ActionAttributesTestBuilderViewFeaturesExtensions
    • AuthenticationScheme
    • BadRequestTestBuilderDataAnnotationsExtensions
    • BadRequestTestBuilderExtensions
    • BaseShouldReturnTestBuilderExtensions
    • BaseTestBuilderWithResponseModelExtensions
    • ComponentBuilderAuthenticationExtensions
    • ComponentBuilderCachingExtensions
    • ComponentBuilderDependencyInjectionExtensions
    • ComponentBuilderEntityFrameworkCoreExtensions
    • ComponentBuilderHttpExtensions
    • ComponentBuilderOptionsExtensions
    • ComponentBuilderRoutingExtensions
    • ComponentBuilderSessionExtensions
    • ComponentBuilderTempDataExtensions
    • ComponentShouldHaveTestBuilderCachingExtensions
    • ComponentShouldHaveTestBuilderEntityFrameworkCoreExtensions
    • ComponentShouldHaveTestBuilderHttpExtensions
    • ComponentShouldHaveTestBuilderModelStateExtensions
    • ComponentShouldHaveTestBuilderSessionExtensions
    • ComponentShouldHaveTestBuilderTempDataExtensions
    • ComponentShouldHaveTestBuilderViewBagExtensions
    • ComponentShouldHaveTestBuilderViewDataExtensions
    • ContentType
    • ControllerBuilderDataAnnotationsExtensions
    • CreatedTestBuilderExtensions
    • From
    • HttpHeader
    • HttpMethod
    • HttpRequestBuilderAuthenticationExtensions
    • HttpRequestBuilderViewFeaturesExtensions
    • HttpScheme
    • HttpStatusCode
    • LocalRedirectTestBuilderExtensions
    • ModelErrorDetailsTestBuilderViewFeaturesExtensions
    • ModelErrorTestBuilderViewFeaturesExtensions
    • MyApplication
    • MyController<TController>
    • MyMvc
    • MyRouting
    • MyViewComponent<TViewComponent>
    • RedirectTestBuilderExtensions
    • ResolvedRouteTestBuilderDataAnnotationsExtensions
    • ServiceCollectionAbstractionsExtensions
    • ServiceCollectionCachingExtensions
    • ServiceCollectionControllersExtensions
    • ServiceCollectionCoreExtensions
    • ServiceCollectionEntityFrameworkCoreExtensions
    • ServiceCollectionExtensions
    • ServiceCollectionHttpExtensions
    • ServiceCollectionOptionsExtensions
    • ServiceCollectionRoutingExtensions
    • ServiceCollectionSessionExtensions
    • ServiceCollectionTempDataExtensions
    • ServiceCollectionUniverseExtensions
    • ServiceCollectionViewComponentsExtensions
    • ServiceCollectionViewFeaturesExtensions
    • ShouldReturnTestBuilderExtensions
    • ShouldReturnTestBuilderJsonResultExtensions
    • ShouldReturnTestBuilderPartialViewResultExtensions
    • ShouldReturnTestBuilderViewComponentResultExtensions
    • ShouldReturnTestBuilderViewResultExtensions
    • ViewComponentShouldReturnTestBuilderExtensions
    • With
  • ActionResults.BadRequest
    • IBadRequestErrorMessageTestBuilder
    • IBadRequestTestBuilder
  • ActionResults.Challenge
    • IChallengeTestBuilder
  • ActionResults.Content
    • IContentTestBuilder
  • ActionResults.Created
    • ICreatedTestBuilder
  • ActionResults.File
    • IFileTestBuilder
    • IPhysicalFileTestBuilder
  • ActionResults.Forbid
    • IForbidTestBuilder
  • ActionResults.Json
    • IJsonSerializerSettingsTestBuilder
    • IJsonTestBuilder
  • ActionResults.LocalRedirect
    • ILocalRedirectTestBuilder
  • ActionResults.NotFound
    • INotFoundTestBuilder
  • ActionResults.Object
    • IObjectTestBuilder
  • ActionResults.Ok
    • IOkTestBuilder
  • ActionResults.Redirect
    • IRedirectTestBuilder
  • ActionResults.StatusCode
    • IStatusCodeTestBuilder
  • ActionResults.View
    • IViewComponentTestBuilder
    • IViewTestBuilder
  • Actions
    • IActionResultTestBuilder<TActionResult>
    • IShouldHaveTestBuilder<TActionResult>
    • IShouldReturnTestBuilder<TActionResult>
    • IVoidActionResultTestBuilder
  • Application
    • IApplicationConfigurationBuilder
  • Attributes
    • IActionAttributesTestBuilder
    • IBaseAttributesTestBuilder<TAttributesTestBuilder>
    • IControllerActionAttributesTestBuilder<TAttributesTestBuilder>
    • IControllerAttributesTestBuilder
    • IViewComponentAttributesTestBuilder
  • Authentication
    • IAuthenticationPropertiesTestBuilder
    • IClaimsIdentityBuilder
    • IClaimsPrincipalBuilder
  • Base
    • IBaseTestBuilder
    • IBaseTestBuilderWithAction
    • IBaseTestBuilderWithActionResult<TActionResult>
    • IBaseTestBuilderWithComponent
    • IBaseTestBuilderWithComponentBuilder<TBuilder>
    • IBaseTestBuilderWithComponentShouldHaveTestBuilder<TBuilder>
    • IBaseTestBuilderWithController
    • IBaseTestBuilderWithInvokedAction
    • IBaseTestBuilderWithModel<TModel>
    • IBaseTestBuilderWithModelError
    • IBaseTestBuilderWithResponseModel
    • IBaseTestBuilderWithViewComponent
    • IBaseTestBuilderWithViewComponentInvocation
    • IBaseTestBuilderWithViewComponentResult<TInvocationResult>
  • CaughtExceptions
    • IAggregateExceptionTestBuilder
    • IBaseExceptionTestBuilder
    • IExceptionMessageTestBuilder
    • IExceptionTestBuilder
    • IShouldThrowTestBuilder
  • Controllers
    • IControllerBuilder<TController>
    • IControllerTestBuilder
  • Data
    • IDataProviderEntryDetailsTestBuilder<TValue>
    • IDataProviderEntryKeyTestBuilder
    • IDataProviderEntryTestBuilder
    • IDbContextBuilder
    • IDbContextTestBuilder
    • IMemoryCacheBuilder
    • IMemoryCacheEntryBuilder
    • IMemoryCacheEntryDetailsTestBuilder<TValue>
    • IMemoryCacheEntryKeyBuilder
    • IMemoryCacheEntryKeyTestBuilder
    • IMemoryCacheEntryTestBuilder
    • IMemoryCacheTestBuilder
    • ISessionBuilder
    • ISessionTestBuilder
    • ITempDataBuilder
    • ITempDataTestBuilder
    • IViewBagTestBuilder
    • IViewDataTestBuilder
  • Http
    • IHttpRequestBuilder
    • IHttpResponseTestBuilder
    • IResponseCookieTestBuilder
  • Invocations
    • IBaseShouldReturnTestBuilder
    • IBaseShouldReturnTestBuilder<TInvocationResult, TBuilder>
    • IBaseShouldReturnTestBuilder<TInvocationResult>
    • IViewComponentResultTestBuilder<TInvocationResult>
    • IViewComponentShouldHaveTestBuilder<TInvocationResult>
    • IViewComponentShouldReturnTestBuilder<TInvocationResult>
  • Models
    • IModelDetailsTestBuilder<TModel>
    • IModelErrorDetailsTestBuilder
    • IModelErrorDetailsTestBuilder<TModel>
    • IModelErrorTestBuilder
    • IModelErrorTestBuilder<TModel>
    • IModelStateTestBuilder
  • Options
    • IOptionsBuilder
  • Routing
    • IResolvedRouteTestBuilder
    • IRouteTestBuilder
    • IShouldMapTestBuilder
  • Services
    • IServicesBuilder
  • Uri
    • IUriBuilder
    • IUriTestBuilder
  • ViewComponentResults
    • IViewTestBuilder
  • ViewComponents
    • IViewComponentBuilder<TViewComponent>
    • IViewComponentTestBuilder

Interface INotFoundTestBuilder

Used for testing Microsoft.AspNetCore.Mvc.NotFoundResult or Microsoft.AspNetCore.Mvc.NotFoundObjectResult.

Inherited Members
IBaseTestBuilderWithComponent.ShouldPassForThe<TComponent>(Action<TComponent>)
IBaseTestBuilderWithComponent.ShouldPassForThe<TComponent>(Func<TComponent, Boolean>)
Namespace:MyTested.AspNetCore.Mvc.Builders.Contracts.ActionResults.NotFound
Assembly:MyTested.AspNetCore.Mvc.Controllers.dll
Syntax
public interface INotFoundTestBuilder : IBaseTestBuilderWithResponseModel, IBaseTestBuilderWithActionResult<ActionResult>, IBaseTestBuilderWithInvokedAction, IBaseTestBuilderWithAction, IBaseTestBuilderWithComponent, IBaseTestBuilder

Methods

| Improve this Doc View Source

ContainingContentType(MediaTypeHeaderValue)

Tests whether Microsoft.AspNetCore.Mvc.NotFoundObjectResult contains the content type provided as MediaTypeHeaderValue.

Declaration
IAndNotFoundTestBuilder ContainingContentType(MediaTypeHeaderValue contentType)
Parameters
Type Name Description
Microsoft.Net.Http.Headers.MediaTypeHeaderValue contentType

Content type as MediaTypeHeaderValue.

Returns
Type Description
MyTested.AspNetCore.Mvc.Builders.Contracts.ActionResults.NotFound.IAndNotFoundTestBuilder

The same MyTested.AspNetCore.Mvc.Builders.Contracts.ActionResults.NotFound.IAndNotFoundTestBuilder.

| Improve this Doc View Source

ContainingContentType(String)

Tests whether Microsoft.AspNetCore.Mvc.NotFoundObjectResult contains the content type provided as string.

Declaration
IAndNotFoundTestBuilder ContainingContentType(string contentType)
Parameters
Type Name Description
System.String contentType

Content type as string.

Returns
Type Description
MyTested.AspNetCore.Mvc.Builders.Contracts.ActionResults.NotFound.IAndNotFoundTestBuilder

The same MyTested.AspNetCore.Mvc.Builders.Contracts.ActionResults.NotFound.IAndNotFoundTestBuilder.

| Improve this Doc View Source

ContainingContentTypes(MediaTypeHeaderValue[])

Tests whether Microsoft.AspNetCore.Mvc.NotFoundObjectResult contains the same content types provided as MediaTypeHeaderValue parameters.

Declaration
IAndNotFoundTestBuilder ContainingContentTypes(params MediaTypeHeaderValue[] contentTypes)
Parameters
Type Name Description
Microsoft.Net.Http.Headers.MediaTypeHeaderValue[] contentTypes

Content types as MediaTypeHeaderValue parameters.

Returns
Type Description
MyTested.AspNetCore.Mvc.Builders.Contracts.ActionResults.NotFound.IAndNotFoundTestBuilder

The same MyTested.AspNetCore.Mvc.Builders.Contracts.ActionResults.NotFound.IAndNotFoundTestBuilder.

| Improve this Doc View Source

ContainingContentTypes(IEnumerable<MediaTypeHeaderValue>)

Tests whether Microsoft.AspNetCore.Mvc.NotFoundObjectResult contains the same content types provided as collection of MediaTypeHeaderValue.

Declaration
IAndNotFoundTestBuilder ContainingContentTypes(IEnumerable<MediaTypeHeaderValue> contentTypes)
Parameters
Type Name Description
System.Collections.Generic.IEnumerable<Microsoft.Net.Http.Headers.MediaTypeHeaderValue> contentTypes

Content types as collection of MediaTypeHeaderValue.

Returns
Type Description
MyTested.AspNetCore.Mvc.Builders.Contracts.ActionResults.NotFound.IAndNotFoundTestBuilder

The same MyTested.AspNetCore.Mvc.Builders.Contracts.ActionResults.NotFound.IAndNotFoundTestBuilder.

| Improve this Doc View Source

ContainingContentTypes(IEnumerable<String>)

Tests whether Microsoft.AspNetCore.Mvc.NotFoundObjectResult contains the same content types provided as collection of strings.

Declaration
IAndNotFoundTestBuilder ContainingContentTypes(IEnumerable<string> contentTypes)
Parameters
Type Name Description
System.Collections.Generic.IEnumerable<System.String> contentTypes

Content types as collection of strings.

Returns
Type Description
MyTested.AspNetCore.Mvc.Builders.Contracts.ActionResults.NotFound.IAndNotFoundTestBuilder

The same MyTested.AspNetCore.Mvc.Builders.Contracts.ActionResults.NotFound.IAndNotFoundTestBuilder.

| Improve this Doc View Source

ContainingContentTypes(String[])

Tests whether Microsoft.AspNetCore.Mvc.NotFoundObjectResult contains the same content types provided as string parameters.

Declaration
IAndNotFoundTestBuilder ContainingContentTypes(params string[] contentTypes)
Parameters
Type Name Description
System.String[] contentTypes

Content types as string parameters.

Returns
Type Description
MyTested.AspNetCore.Mvc.Builders.Contracts.ActionResults.NotFound.IAndNotFoundTestBuilder

The same MyTested.AspNetCore.Mvc.Builders.Contracts.ActionResults.NotFound.IAndNotFoundTestBuilder.

| Improve this Doc View Source

ContainingOutputFormatter(IOutputFormatter)

Tests whether Microsoft.AspNetCore.Mvc.NotFoundObjectResult contains the provided IOutputFormatter.

Declaration
IAndNotFoundTestBuilder ContainingOutputFormatter(IOutputFormatter outputFormatter)
Parameters
Type Name Description
Microsoft.AspNetCore.Mvc.Formatters.IOutputFormatter outputFormatter

Instance of IOutputFormatter.

Returns
Type Description
MyTested.AspNetCore.Mvc.Builders.Contracts.ActionResults.NotFound.IAndNotFoundTestBuilder

The same MyTested.AspNetCore.Mvc.Builders.Contracts.ActionResults.NotFound.IAndNotFoundTestBuilder.

| Improve this Doc View Source

ContainingOutputFormatterOfType<TOutputFormatter>()

Tests whether Microsoft.AspNetCore.Mvc.NotFoundObjectResult contains IOutputFormatter of the provided type.

Declaration
IAndNotFoundTestBuilder ContainingOutputFormatterOfType<TOutputFormatter>()where TOutputFormatter : IOutputFormatter
Returns
Type Description
MyTested.AspNetCore.Mvc.Builders.Contracts.ActionResults.NotFound.IAndNotFoundTestBuilder

The same MyTested.AspNetCore.Mvc.Builders.Contracts.ActionResults.NotFound.IAndNotFoundTestBuilder.

Type Parameters
Name Description
TOutputFormatter Type of IOutputFormatter.
| Improve this Doc View Source

ContainingOutputFormatters(IOutputFormatter[])

Tests whether Microsoft.AspNetCore.Mvc.NotFoundObjectResult contains the provided output formatters.

Declaration
IAndNotFoundTestBuilder ContainingOutputFormatters(params IOutputFormatter[] outputFormatters)
Parameters
Type Name Description
Microsoft.AspNetCore.Mvc.Formatters.IOutputFormatter[] outputFormatters

IOutputFormatter parameters.

Returns
Type Description
MyTested.AspNetCore.Mvc.Builders.Contracts.ActionResults.NotFound.IAndNotFoundTestBuilder

The same MyTested.AspNetCore.Mvc.Builders.Contracts.ActionResults.NotFound.IAndNotFoundTestBuilder.

| Improve this Doc View Source

ContainingOutputFormatters(IEnumerable<IOutputFormatter>)

Tests whether Microsoft.AspNetCore.Mvc.NotFoundObjectResult contains the provided output formatters.

Declaration
IAndNotFoundTestBuilder ContainingOutputFormatters(IEnumerable<IOutputFormatter> outputFormatters)
Parameters
Type Name Description
System.Collections.Generic.IEnumerable<Microsoft.AspNetCore.Mvc.Formatters.IOutputFormatter> outputFormatters

Collection of IOutputFormatter.

Returns
Type Description
MyTested.AspNetCore.Mvc.Builders.Contracts.ActionResults.NotFound.IAndNotFoundTestBuilder

The same MyTested.AspNetCore.Mvc.Builders.Contracts.ActionResults.NotFound.IAndNotFoundTestBuilder.

| Improve this Doc View Source

WithStatusCode(Int32)

Tests whether Microsoft.AspNetCore.Mvc.NotFoundObjectResult has the same status code as the provided one.

Declaration
IAndNotFoundTestBuilder WithStatusCode(int statusCode)
Parameters
Type Name Description
System.Int32 statusCode

Status code as integer.

Returns
Type Description
MyTested.AspNetCore.Mvc.Builders.Contracts.ActionResults.NotFound.IAndNotFoundTestBuilder

The same MyTested.AspNetCore.Mvc.Builders.Contracts.ActionResults.NotFound.IAndNotFoundTestBuilder.

| Improve this Doc View Source

WithStatusCode(HttpStatusCode)

Tests whether Microsoft.AspNetCore.Mvc.NotFoundObjectResult has the same status code as the provided HttpStatusCode.

Declaration
IAndNotFoundTestBuilder WithStatusCode(HttpStatusCode statusCode)
Parameters
Type Name Description
System.Net.HttpStatusCode statusCode

HttpStatusCode enumeration.

Returns
Type Description
MyTested.AspNetCore.Mvc.Builders.Contracts.ActionResults.NotFound.IAndNotFoundTestBuilder

The same MyTested.AspNetCore.Mvc.Builders.Contracts.ActionResults.NotFound.IAndNotFoundTestBuilder.

Extension Methods

BaseTestBuilderWithResponseModelExtensions.WithNoModel()
BaseTestBuilderWithResponseModelExtensions.WithModelOfType(Type)
BaseTestBuilderWithResponseModelExtensions.WithModelOfType<TModel>()
BaseTestBuilderWithResponseModelExtensions.WithModel<TModel>(TModel)
  • Improve this Doc
  • View Source
In This Article
  • Methods
    • ContainingContentType(MediaTypeHeaderValue)
    • ContainingContentType(String)
    • ContainingContentTypes(MediaTypeHeaderValue[])
    • ContainingContentTypes(IEnumerable<MediaTypeHeaderValue>)
    • ContainingContentTypes(IEnumerable<String>)
    • ContainingContentTypes(String[])
    • ContainingOutputFormatter(IOutputFormatter)
    • ContainingOutputFormatterOfType<TOutputFormatter>()
    • ContainingOutputFormatters(IOutputFormatter[])
    • ContainingOutputFormatters(IEnumerable<IOutputFormatter>)
    • WithStatusCode(Int32)
    • WithStatusCode(HttpStatusCode)
  • Extension Methods
Back to top Copyright © 2015-2016 MyTestedASP.NET. All Rights Reserved. Generated by DocFX