Class ServiceCollectionCachingExtensions
Contains caching extension methods for IServiceCollection.
Inheritance
System.Object
ServiceCollectionCachingExtensions
Namespace:MyTested.AspNetCore.Mvc
Assembly:MyTested.AspNetCore.Mvc.Caching.dll
Syntax
public static class ServiceCollectionCachingExtensions
Methods
| Improve this Doc View SourceReplaceMemoryCache(IServiceCollection)
Replaces the default Microsoft.Extensions.Caching.Memory.IMemoryCache with a mocked implementation.
Declaration
public static IServiceCollection ReplaceMemoryCache(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. |