Class BaseShouldReturnTestBuilderExtensions
Contains model extension methods for IBaseShouldReturnTestBuilder.
Inheritance
System.Object
BaseShouldReturnTestBuilderExtensions
Namespace:MyTested.AspNetCore.Mvc
Assembly:MyTested.AspNetCore.Mvc.Models.dll
Syntax
public static class BaseShouldReturnTestBuilderExtensions
Methods
| Improve this Doc View SourceResult<TResult>(IBaseShouldReturnTestBuilder, TResult)
Tests whether the result is deeply equal to the provided one.
Declaration
public static IAndModelDetailsTestBuilder<TResult> Result<TResult>(this IBaseShouldReturnTestBuilder builder, TResult model)
Parameters
Type | Name | Description |
---|---|---|
IBaseShouldReturnTestBuilder | builder | Instance of IBaseShouldReturnTestBuilder type. |
TResult | model | Expected return object. |
Returns
Type | Description |
---|---|
MyTested.AspNetCore.Mvc.Builders.Contracts.Models.IAndModelDetailsTestBuilder<TResult> | Test builder of IModelDetailsTestBuilder<TModel> type. |
Type Parameters
Name | Description |
---|---|
TResult | Expected response type. |
ResultOfType<TResult>(IBaseShouldReturnTestBuilder)
Tests whether the result is of the provided type.
Declaration
public static IAndModelDetailsTestBuilder<TResult> ResultOfType<TResult>(this IBaseShouldReturnTestBuilder builder)
Parameters
Type | Name | Description |
---|---|---|
IBaseShouldReturnTestBuilder | builder | Instance of IBaseShouldReturnTestBuilder type. |
Returns
Type | Description |
---|---|
MyTested.AspNetCore.Mvc.Builders.Contracts.Models.IAndModelDetailsTestBuilder<TResult> | Test builder of IModelDetailsTestBuilder<TModel> type. |
Type Parameters
Name | Description |
---|---|
TResult | Expected response type. |
ResultOfType<TInvocationResult>(IBaseShouldReturnTestBuilder<TInvocationResult>, Type)
Tests whether the result is of the provided type.
Declaration
public static IAndModelDetailsTestBuilder<TInvocationResult> ResultOfType<TInvocationResult>(this IBaseShouldReturnTestBuilder<TInvocationResult> builder, Type resultType)
Parameters
Type | Name | Description |
---|---|---|
IBaseShouldReturnTestBuilder<TInvocationResult> | builder | Instance of IBaseShouldReturnTestBuilder<TInvocationResult> type. |
System.Type | resultType | Expected return type. |
Returns
Type | Description |
---|---|
MyTested.AspNetCore.Mvc.Builders.Contracts.Models.IAndModelDetailsTestBuilder<TInvocationResult> | Test builder of IModelDetailsTestBuilder<TModel> type. |
Type Parameters
Name | Description |
---|---|
TInvocationResult |