Exemple #1
0
 public UserProfileService(IProfileSettingsService profileSettingsService, IUserProfileProvider userProfileProvider, IContactFacetsService contactFacetsService, IAccountTrackerService accountTrackerService)
 {
     _profileSettingsService = profileSettingsService;
     _userProfileProvider    = userProfileProvider;
     _contactFacetsService   = contactFacetsService;
     _accountTrackerService  = accountTrackerService;
 }
 public OnReIndexTemplates(ILogger logger,
                           ITemplatesReIndexerService templatesReIndexerService,
                           IMessengerService messengerService,
                           IUserProfileProvider userProfileProvider, bool useAzureStorage = false)
     : base(logger, messengerService, FunctionName, QueueName, useAzureStorage, userProfileProvider, templatesReIndexerService)
 {
 }
Exemple #3
0
 public UserProfileService(IProfileSettingsService profileSettingsService, IUserProfileProvider userProfileProvider, IUpdateContactFacetsService updateContactFacetsService, IAccountTrackerService accountTrackerService)
 {
     this.profileSettingsService     = profileSettingsService;
     this.userProfileProvider        = userProfileProvider;
     this.updateContactFacetsService = updateContactFacetsService;
     this.accountTrackerService      = accountTrackerService;
 }
Exemple #4
0
 public OnCalcsInstructAllocationResults(
     ILogger logger,
     IBuildProjectsService buildProjectsService,
     IMessengerService messengerService,
     IUserProfileProvider userProfileProvider, bool useAzureStorage = false)
     : base(logger, messengerService, FunctionName, QueueName, useAzureStorage, userProfileProvider, buildProjectsService)
 {
 }
Exemple #5
0
 public OnEditSpecificationEvent(
     ILogger logger,
     IFundingStreamPermissionService fundingStreamPermissionService,
     IMessengerService messengerService,
     IUserProfileProvider userProfileProvider, bool useAzureStorage = false)
     : base(logger, messengerService, FunctionName, $"{ServiceBusConstants.TopicNames.EditSpecification}/{ServiceBusConstants.TopicSubscribers.UpdateUsersForEditSpecification}", useAzureStorage, userProfileProvider, fundingStreamPermissionService)
 {
 }
 public OnBatchPublishedProviderValidation(
     ILogger logger,
     IBatchUploadValidationService validationService,
     IMessengerService messengerService,
     IUserProfileProvider userProfileProvider, bool useAzureStorage = false)
     : base(logger, messengerService, FunctionName, QueueName, useAzureStorage, userProfileProvider, validationService)
 {
 }
 public OnTestExecution(
     ILogger logger,
     ITestEngineService testEngineService,
     IMessengerService messengerService,
     IUserProfileProvider userProfileProvider, bool useAzureStorage = false)
     : base(logger, messengerService, FunctionName, QueueName, useAzureStorage, userProfileProvider, testEngineService)
 {
 }
 public CalcsAddRelationshipToBuildProject(
     ILogger logger,
     IBuildProjectsService buildProjectsService,
     IMessengerService messengerService,
     IUserProfileProvider userProfileProvider, bool useAzureStorage = false)
     : base(logger, messengerService, FunctionName, QueueName, useAzureStorage, userProfileProvider, buildProjectsService)
 {
 }
 public OnPopulateScopedProvidersEventTrigger(
     ILogger logger,
     IScopedProvidersService scopedProviderService,
     IMessengerService messengerService,
     IUserProfileProvider userProfileProvider, bool useAzureStorage = false)
     : base(logger, messengerService, FunctionName, QueueName, useAzureStorage, userProfileProvider, scopedProviderService)
 {
 }
Exemple #10
0
 public OnJobNotification(
     ILogger logger,
     IJobManagementService jobManagementService,
     IMessengerService messengerService,
     IUserProfileProvider userProfileProvider, bool useAzureStorage = false)
     : base(logger, messengerService, FunctionName, $"{ServiceBusConstants.TopicNames.JobNotifications}/{ServiceBusConstants.TopicSubscribers.UpdateJobsOnCompletion}", useAzureStorage, userProfileProvider, jobManagementService)
 {
 }
 public OnCalculationResultsCsvGeneration(
     ILogger logger,
     IProviderResultsCsvGeneratorService csvGeneratorService,
     IMessengerService messengerService,
     IUserProfileProvider userProfileProvider, bool useAzureStorage = false)
     : base(logger, messengerService, FunctionName, QueueName, useAzureStorage, userProfileProvider, csvGeneratorService)
 {
 }
 public OnDataDefinitionChanges(
     ILogger logger,
     IDatasetDefinitionFieldChangesProcessor datasetDefinitionFieldChangesProcessor,
     IMessengerService messengerService,
     IUserProfileProvider userProfileProvider, bool useAzureStorage = false)
     : base(logger, messengerService, FunctionName, $"{ServiceBusConstants.TopicNames.DataDefinitionChanges}/{ServiceBusConstants.TopicSubscribers.UpdateCalculationFieldDefinitionProperties}", useAzureStorage, userProfileProvider, datasetDefinitionFieldChangesProcessor)
 {
 }
 public OnPublishedFundingUndo(
     ILogger logger,
     IPublishedFundingUndoJobService undoService,
     IMessengerService messengerService,
     IUserProfileProvider userProfileProvider, bool useAzureStorage = false)
     : base(logger, messengerService, FunctionName, QueueName, useAzureStorage, userProfileProvider, undoService)
 {
 }
Exemple #14
0
 public OnAddRelationshipEvent(
     ILogger logger,
     ISpecificationsService specificationsService,
     IMessengerService messengerService,
     IUserProfileProvider userProfileProvider, bool useAzureStorage = false)
     : base(logger, messengerService, FunctionName, QueueName, useAzureStorage, userProfileProvider, specificationsService)
 {
 }
Exemple #15
0
 public OnSearchIndexWriterEventTrigger(ILogger logger,
                                        IMessengerService messengerService,
                                        IUserProfileProvider userProfileProvider,
                                        ISearchIndexWriterService searchIndexWriterService,
                                        bool useAzureStorage = false)
     : base(logger, messengerService, FunctionName, QueueName, useAzureStorage, userProfileProvider, searchIndexWriterService)
 {
 }
Exemple #16
0
 public OnPublishAllProviderFunding(
     ILogger logger,
     IPublishService publishService,
     IMessengerService messengerService,
     IUserProfileProvider userProfileProvider, bool useAzureStorage = false)
     : base(logger, messengerService, FunctionName, QueueName, useAzureStorage, userProfileProvider, publishService)
 {
 }
Exemple #17
0
 public OnDeletePublishedProviders(
     ILogger logger,
     IDeletePublishedProvidersService deletePublishedProvidersService,
     IMessengerService messengerService,
     IUserProfileProvider userProfileProvider, bool useAzureStorage = false)
     : base(logger, messengerService, FunctionName, QueueName, useAzureStorage, userProfileProvider, deletePublishedProvidersService)
 {
 }
 public OnCalculationAggregationsJobCompleted(
     ILogger logger,
     IJobService jobService,
     IMessengerService messengerService,
     IUserProfileProvider userProfileProvider, bool useAzureStorage = false)
     : base(logger, messengerService, FunctionName, $"{ServiceBusConstants.TopicNames.JobNotifications}/{ServiceBusConstants.TopicSubscribers.CreateInstructAllocationsJob}", useAzureStorage, userProfileProvider, jobService)
 {
 }
        public LoggedInUserMiddleware(RequestDelegate next, IUserProfileProvider userProfileProvider)
        {
            Guard.ArgumentNotNull(next, nameof(next));
            Guard.ArgumentNotNull(userProfileProvider, nameof(userProfileProvider));

            _next = next;
            _userProfileProvider = userProfileProvider;
        }
 public OnPublishIntegrityCheck(
     ILogger logger,
     IPublishIntegrityCheckService publishIntegrityCheckService,
     IMessengerService messengerService,
     IUserProfileProvider userProfileProvider, bool useAzureStorage = false)
     : base(logger, messengerService, FunctionName, QueueName, useAzureStorage, userProfileProvider, publishIntegrityCheckService)
 {
 }
        public static void SetupTests(TestContext tc)
        {
            SetupTests("notifications");

            _logger = CreateLogger();
            _notificationService = CreateNotificationService();
            _userProfileProvider = CreateUserProfileProvider();
        }
 public OnEditSpecificationEvent(
     ILogger logger,
     IScenariosService scenariosService,
     IMessengerService messengerService,
     IUserProfileProvider userProfileProvider, bool useAzureStorage = false)
     : base(logger, messengerService, FunctionName, $"{ServiceBusConstants.TopicNames.EditSpecification}/{ServiceBusConstants.TopicSubscribers.UpdateScenariosForEditSpecification}", useAzureStorage, userProfileProvider, scenariosService)
 {
 }
Exemple #23
0
 public OnProviderResultsSpecificationCleanup(
     ILogger logger,
     IResultsService resultsService,
     IMessengerService messengerService,
     IUserProfileProvider userProfileProvider, bool useAzureStorage = false)
     : base(logger, messengerService, FunctionName, $"{ServiceBusConstants.TopicNames.ProviderSourceDatasetCleanup}/{ServiceBusConstants.TopicSubscribers.CleanupCalculationResultsForSpecificationProviders}", useAzureStorage, userProfileProvider, resultsService)
 {
 }
 public OnReIndexSpecificationCalculationRelationships(
     ILogger logger,
     IReIndexSpecificationCalculationRelationships service,
     IMessengerService messengerService,
     IUserProfileProvider userProfileProvider, bool useAzureStorage = false)
     : base(logger, messengerService, FunctionName, QueueName, useAzureStorage, userProfileProvider, service)
 {
 }
 public OnRunSqlImport(
     ILogger logger,
     ISqlImportService importService,
     IMessengerService messengerService,
     IUserProfileProvider userProfileProvider, bool useAzureStorage = false)
     : base(logger, messengerService, FunctionName, QueueName, useAzureStorage, userProfileProvider, importService)
 {
 }
Exemple #26
0
 public OnGeneratePublishedFundingCsv(
     ILogger logger,
     IFundingLineCsvGenerator csvGenerator,
     IMessengerService messengerService,
     IUserProfileProvider userProfileProvider, bool useAzureStorage = false)
     : base(logger, messengerService, FunctionName, QueueName, useAzureStorage, userProfileProvider, csvGenerator)
 {
 }
 public OnUpdateCodeContextCache(
     ILogger logger,
     ICodeContextCache codeContextCache,
     IMessengerService messengerService,
     IUserProfileProvider userProfileProvider, bool useAzureStorage = false)
     : base(logger, messengerService, FunctionName, QueueName, useAzureStorage, userProfileProvider, codeContextCache)
 {
 }
Exemple #28
0
 public OnScaleUpCosmosDbCollection(
     ILogger logger,
     ICosmosDbScalingService scalingService,
     IMessengerService messengerService,
     IUserProfileProvider userProfileProvider, bool useAzureStorage = false)
     : base(logger, messengerService, FunctionName, $"{ServiceBusConstants.TopicNames.JobNotifications}/{ServiceBusConstants.TopicSubscribers.ScaleUpCosmosdbCollection}", useAzureStorage, userProfileProvider, scalingService)
 {
 }
 public OnRefreshFunding(
     ILogger logger,
     IRefreshService refreshService,
     IMessengerService messengerService,
     IUserProfileProvider userProfileProvider, bool useAzureStorage = false)
     : base(logger, messengerService, FunctionName, QueueName, useAzureStorage, userProfileProvider, refreshService)
 {
 }
Exemple #30
0
 public OnReIndexPublishedProviders(
     ILogger logger,
     IPublishedProviderReIndexerService publishedProviderReIndexerService,
     IMessengerService messengerService,
     IUserProfileProvider userProfileProvider, bool useAzureStorage = false)
     : base(logger, messengerService, FunctionName, QueueName, useAzureStorage, userProfileProvider, publishedProviderReIndexerService)
 {
 }
    public void GetEmptyProfileShouldReturnEditProfileWithInterests([Frozen] IEnumerable<string> interests, IProfileSettingsService profileSettingsService, IUserProfileProvider userProfileProvider, [Greedy] UserProfileService userProfileService)
    {
      var profile = userProfileService.GetEmptyProfile();

      profile.Should().NotBeNull();
      profile.FirstName.Should().BeNull();
      profile.LastName.Should().BeNull();
      profile.Interest.Should().BeNull();
      profile.PhoneNumber.Should().BeNull();
      profile.InterestTypes.Should().BeEquivalentTo(interests);
    }
 public void GetUserDefaultProfileIdShouldReturnId([Frozen] Item item, IProfileSettingsService profileSettingsService, IUserProfileProvider userProfileProvider, [Greedy] UserProfileService userProfileService)
 {
   userProfileService.GetUserDefaultProfileId().Should().Be(item.ID.ToString());
 }
 public UserProfileService(IProfileSettingsService profileSettingsService, IUserProfileProvider userProfileProvider)
 {
   this.profileSettingsService = profileSettingsService;
   this.userProfileProvider = userProfileProvider;
 }
    public void ValidateProfileShouldreturnValid(ModelStateDictionary modelState, [Frozen] IEnumerable<string> interests, IProfileSettingsService profileSettingsService, IUserProfileProvider userProfileProvider, [Greedy] UserProfileService userProfileService)
    {
      var editProfile = new EditProfile() { Interest = interests.First() };

      var result = userProfileService.ValidateProfile(editProfile, modelState);

      result.Should().BeTrue();
    }
    public void ValidateProfileShouldAddModelError(ModelStateDictionary modelState, [Frozen] IEnumerable<string> interests, IProfileSettingsService profileSettingsService, IUserProfileProvider userProfileProvider, [Greedy] UserProfileService userProfileService)
    {
      var editProfile = new EditProfile() { Interest = "invalid interest" };

      var result = userProfileService.ValidateProfile(editProfile, modelState);

      result.Should().BeFalse();
      modelState.Keys.Should().Contain("Interest");
    }
 public void GetUserDefaultProfileIdShouldReturnNull(IProfileSettingsService profileSettingsService, IUserProfileProvider userProfileProvider, [Greedy] UserProfileService userProfileService)
 {
   userProfileService.GetUserDefaultProfileId().Should().BeNull();
 }
 public void GetInterestsShouldReturnInterests([Frozen] IEnumerable<string> interests, IProfileSettingsService profileSettingsService, IUserProfileProvider userProfileProvider, [Greedy] UserProfileService userProfileService)
 {
   userProfileService.GetInterests().Should().BeEquivalentTo(interests);
 }