Esempio n. 1
0
        private ActionExecutingContext GetDefaultContext()
        {
            var delegateGroupsController = new RecommendedLearningController(
                A.Fake <IFilteredApiHelperService>(),
                A.Fake <ISelfAssessmentService>(),
                A.Fake <IConfiguration>(),
                A.Fake <IRecommendedLearningService>(),
                A.Fake <IActionPlanService>()
                ).WithDefaultContext().WithMockUser(true, delegateId: DelegateId);
            var context = ContextHelper.GetDefaultActionExecutingContext(delegateGroupsController);

            context.RouteData.Values["selfAssessmentId"] = SelfAssessmentId;

            return(context);
        }
Esempio n. 2
0
        public void Setup()
        {
            filteredApiHelperService   = A.Fake <IFilteredApiHelperService>();
            selfAssessmentService      = A.Fake <ISelfAssessmentService>();
            configuration              = A.Fake <IConfiguration>();
            recommendedLearningService = A.Fake <IRecommendedLearningService>();
            actionPlanService          = A.Fake <IActionPlanService>();

            controller = new RecommendedLearningController(
                filteredApiHelperService,
                selfAssessmentService,
                configuration,
                recommendedLearningService,
                actionPlanService
                )
                         .WithDefaultContext()
                         .WithMockUser(true, delegateId: DelegateId);
        }