Exemplo n.º 1
0
 protected override void CustomTestSetup(IUmbracoBuilder builder)
 {
     NotificationHandler.PublishedContent = notification => { };
     builder.Services.AddUnique <IServerMessenger, ScopedRepositoryTests.LocalServerMessenger>();
     builder.AddCoreNotifications();
     builder.AddNotificationHandler <ContentPublishedNotification, NotificationHandler>();
     builder.Services.AddUnique <IUmbracoContextAccessor, TestUmbracoContextAccessor>();
     builder.Services.AddUnique(MockHttpContextAccessor.Object);
     builder.AddNuCache();
 }
 protected override void CustomTestSetup(IUmbracoBuilder builder)
 {
     builder.AddNuCache();
     builder.Services.AddUnique <IServerMessenger, LocalServerMessenger>();
     builder
     .AddNotificationHandler <DictionaryItemDeletedNotification, DistributedCacheBinder>()
     .AddNotificationHandler <DictionaryItemSavedNotification, DistributedCacheBinder>()
     .AddNotificationHandler <LanguageSavedNotification, DistributedCacheBinder>()
     .AddNotificationHandler <LanguageDeletedNotification, DistributedCacheBinder>()
     .AddNotificationHandler <UserSavedNotification, DistributedCacheBinder>()
     .AddNotificationHandler <LanguageDeletedNotification, DistributedCacheBinder>()
     .AddNotificationHandler <MemberGroupDeletedNotification, DistributedCacheBinder>()
     .AddNotificationHandler <MemberGroupSavedNotification, DistributedCacheBinder>();
     builder.AddNotificationHandler <LanguageSavedNotification, PublishedSnapshotServiceEventHandler>();
 }
 protected override void CustomTestSetup(IUmbracoBuilder builder)
 {
     base.CustomTestSetup(builder);
     builder.AddNuCache();
 }
Exemplo n.º 4
0
 protected override void CustomTestSetup(IUmbracoBuilder builder)
 {
     builder.Services.AddUnique <IVariationContextAccessor>(_variationContextAccessor);
     builder.AddNuCache();
 }