/// <summary> /// Initializes a new instance of the <see cref="AbpPushRequestSubscriptionManager"/> class. /// </summary> public AbpPushRequestSubscriptionManager( IPushRequestStore pushRequestStore, IPushDefinitionManager pushDefinitionManager, IGuidGenerator guidGenerator) { RequestStore = pushRequestStore; DefinitionManager = pushDefinitionManager; GuidGenerator = guidGenerator; }
/// <summary> /// Initializes a new instance of the <see cref="AbpPushRequestDistributor"/> class. /// </summary> public AbpPushRequestDistributor( IPushRequestStore pushRequestStore, IPushDefinitionManager pushDefinitionManager, IAbpPushConfiguration pushConfiguration, IIocResolver iocResolver, IGuidGenerator guidGenerator) { RequestStore = pushRequestStore; DefinitionManager = pushDefinitionManager; Configuration = pushConfiguration; IocResolver = iocResolver; GuidGenerator = guidGenerator; }
/// <summary> /// Initializes a new instance of the <see cref="AbpPushRequestPublisher"/> class. /// </summary> public AbpPushRequestPublisher( IPushRequestStore pushRequestStore, IBackgroundJobManager backgroundJobManager, IPushRequestDistributor pushRequestDistributor, IAbpPushConfiguration pushConfiguration, IGuidGenerator guidGenerator ) { RequestStore = pushRequestStore; BackgroundJobManager = backgroundJobManager; RequestDistributor = pushRequestDistributor; Configuration = pushConfiguration; GuidGenerator = guidGenerator; AbpSession = NullAbpSession.Instance; }
public PushRequestPublisher_Tests() { _store = Substitute.For <IPushRequestStore>(); _backgroundJobManager = Substitute.For <IBackgroundJobManager>(); _distributor = Substitute.For <IPushRequestDistributor>(); _configuration = Substitute.For <IAbpPushConfiguration>(); _generator = Substitute.For <IGuidGenerator>(); _publisher = new AbpPushRequestPublisher( _store, _backgroundJobManager, _distributor, _configuration, _generator ); _publisher.UnitOfWorkManager = Substitute.For <IUnitOfWorkManager>(); _publisher.UnitOfWorkManager.Current.Returns(Substitute.For <IActiveUnitOfWork>()); }
public PushRequestDistributor_Tests() { _store = Substitute.For <IPushRequestStore>(); _definitionManager = Substitute.For <IPushDefinitionManager>(); _configuration = Substitute.For <IAbpPushConfiguration>(); _configuration.ServiceProviders.Returns(new List <ServiceProviderInfo>()); _iocResolver = Substitute.For <IIocResolver>(); _generator = Substitute.For <IGuidGenerator>(); _distributor = new AbpPushRequestDistributor( _store, _definitionManager, _configuration, _iocResolver, _generator ); _distributor.UnitOfWorkManager = Substitute.For <IUnitOfWorkManager>(); _distributor.UnitOfWorkManager.Current.Returns(Substitute.For <IActiveUnitOfWork>()); var _settingManager = Substitute.For <ISettingManager>(); _settingManager.GetSettingValueForUser(Arg.Any <string>(), Arg.Any <int?>(), Arg.Any <long>()) .Returns("true"); _distributor.SettingManager = _settingManager; }