Class ServiceCollectionTempDataExtensions
Contains view features extension methods for IServiceCollection.
Inheritance
System.Object
ServiceCollectionTempDataExtensions
Namespace:MyTested.AspNetCore.Mvc
Assembly:MyTested.AspNetCore.Mvc.TempData.dll
Syntax
public static class ServiceCollectionTempDataExtensions
Methods
| Improve this Doc View SourceReplaceTempDataProvider(IServiceCollection)
Replaces the default Microsoft.AspNetCore.Mvc.ViewFeatures.ITempDataProvider with a mocked implementation.
Declaration
public static IServiceCollection ReplaceTempDataProvider(this IServiceCollection serviceCollection)
Parameters
Type | Name | Description |
---|---|---|
Microsoft.Extensions.DependencyInjection.IServiceCollection | serviceCollection | Instance of IServiceCollection type. |
Returns
Type | Description |
---|---|
Microsoft.Extensions.DependencyInjection.IServiceCollection | The same IServiceCollection. |