Пример #1
0
 public SignpostingController(
     IUserService userService,
     ILearningHubResourceService learningHubResourceService,
     IActionPlanService actionPlanService
     )
 {
     this.userService = userService;
     this.learningHubResourceService = learningHubResourceService;
     this.actionPlanService          = actionPlanService;
 }
Пример #2
0
 public SignpostingSsoController(
     ILearningHubLinkService learningHubLinkService,
     ILearningHubResourceService learningHubResourceService,
     IUserService userService
     )
 {
     this.learningHubLinkService     = learningHubLinkService;
     this.learningHubResourceService = learningHubResourceService;
     this.userService = userService;
 }
Пример #3
0
 public RecommendedLearningService(
     ISelfAssessmentDataService selfAssessmentDataService,
     ICompetencyLearningResourcesDataService competencyLearningResourcesDataService,
     ILearningHubResourceService learningHubResourceService,
     ILearningLogItemsDataService learningLogItemsDataService,
     IConfigDataService configDataService
     )
 {
     this.selfAssessmentDataService = selfAssessmentDataService;
     this.competencyLearningResourcesDataService = competencyLearningResourcesDataService;
     this.learningHubResourceService             = learningHubResourceService;
     this.learningLogItemsDataService            = learningLogItemsDataService;
     this.configDataService = configDataService;
 }
Пример #4
0
        public void Setup()
        {
            competencyLearningResourcesDataService = A.Fake <ICompetencyLearningResourcesDataService>();
            learningLogItemsDataService            = A.Fake <ILearningLogItemsDataService>();
            learningHubResourceService             = A.Fake <ILearningHubResourceService>();
            selfAssessmentDataService = A.Fake <ISelfAssessmentDataService>();
            configDataService         = A.Fake <IConfigDataService>();

            recommendedLearningService = new RecommendedLearningService(
                selfAssessmentDataService,
                competencyLearningResourcesDataService,
                learningHubResourceService,
                learningLogItemsDataService,
                configDataService
                );
        }
        public void Setup()
        {
            learningHubLinkService     = A.Fake <ILearningHubLinkService>();
            learningHubResourceService = A.Fake <ILearningHubResourceService>();
            userService = A.Fake <IUserService>();

            controller = new SignpostingSsoController(
                learningHubLinkService,
                learningHubResourceService,
                userService
                )
                         .WithDefaultContext()
                         .WithMockSessionData(new Dictionary <string, string>())
                         .WithMockUser(true);

            A.CallTo(() => learningHubLinkService.IsLearningHubAccountLinked(A <int> ._)).Returns(true);
        }
Пример #6
0
        public void SetUp()
        {
            userService = A.Fake <IUserService>();
            learningHubResourceService = A.Fake <ILearningHubResourceService>();
            actionPlanService          = A.Fake <IActionPlanService>();

            A.CallTo(() => actionPlanService.UpdateActionPlanResourcesLastAccessedDateIfPresent(A <int> ._, A <int> ._))
            .DoesNothing();
            A.CallTo(() => userService.GetDelegateUserById(DelegateId))
            .Returns(UserTestHelper.GetDefaultDelegateUser(DelegateId));
            A.CallTo(() => userService.DelegateUserLearningHubAccountIsLinked(DelegateId)).Returns(false);
            A.CallTo(() => learningHubResourceService.GetResourceByReferenceId(ResourceReferenceId))
            .Returns((new ResourceReferenceWithResourceDetails(), false));

            controller = new SignpostingController(
                userService,
                learningHubResourceService,
                actionPlanService
                ).WithDefaultContext().WithMockUser(true, delegateId: DelegateId);
        }
Пример #7
0
        public void Setup()
        {
            genericCatalogue = Builder <Catalogue> .CreateNew().With(c => c.Name = "Generic catalogue").Build();

            clockService = A.Fake <IClockService>();
            competencyLearningResourcesDataService = A.Fake <ICompetencyLearningResourcesDataService>();
            learningLogItemsDataService            = A.Fake <ILearningLogItemsDataService>();
            learningHubResourceService             = A.Fake <ILearningHubResourceService>();
            selfAssessmentDataService            = A.Fake <ISelfAssessmentDataService>();
            learningResourceReferenceDataService = A.Fake <ILearningResourceReferenceDataService>();
            config = A.Fake <IConfiguration>();

            actionPlanService = new ActionPlanService(
                competencyLearningResourcesDataService,
                learningLogItemsDataService,
                clockService,
                learningHubResourceService,
                selfAssessmentDataService,
                config,
                learningResourceReferenceDataService
                );
        }