This commit is contained in:
Stephan
2018-11-28 16:57:01 +01:00
parent b1651b8c9e
commit e42f140a2c
16 changed files with 150 additions and 178 deletions

View File

@@ -7,7 +7,6 @@ using Umbraco.Core;
using Umbraco.Core.Cache;
using Umbraco.Core.Components;
using Umbraco.Core.Composing;
using Umbraco.Core.Configuration;
using Umbraco.Core.Logging;
using Umbraco.Core.Sync;
@@ -25,7 +24,7 @@ namespace Umbraco.Tests.Cache.DistributedCache
public void Setup()
{
var register = RegisterFactory.Create();
Current.Factory = register.CreateFactory(); // fixme only for LightInject
var composition = new Composition(register, new TypeLoader(), Mock.Of<IProfilingLogger>(), RuntimeLevel.Run);
register.Register<IServerRegistrar>(_ => new TestServerRegistrar());
@@ -34,6 +33,8 @@ namespace Umbraco.Tests.Cache.DistributedCache
composition.GetCollectionBuilder<CacheRefresherCollectionBuilder>()
.Add<TestCacheRefresher>();
Current.Factory = register.CreateFactory();
_distributedCache = new Umbraco.Web.Cache.DistributedCache();
}