Exemplo n.º 1
0
 public ContextService(IHttpContextAccessor httpContextAccessor,
                       ISiteFacade siteFacade,
                       IThemeFacade themeFacade)
 {
     _httpContextAccessor = httpContextAccessor;
     _siteFacade          = siteFacade;
     _themeFacade         = themeFacade;
 }
Exemplo n.º 2
0
 public ThemeController(IThemeFacade themeFacade,
                        ICommandSender commandSender,
                        IThemeRules themeRules,
                        IContextService contextService)
     : base(contextService)
 {
     _themeFacade   = themeFacade;
     _commandSender = commandSender;
     _themeRules    = themeRules;
 }
Exemplo n.º 3
0
 public ContextService(IHttpContextAccessor httpContextAccessor,
                       ISiteFacade siteFacade,
                       IPageFacade pageFacade,
                       ILanguageFacade languageFacade,
                       IThemeFacade themeFacade)
 {
     _httpContextAccessor = httpContextAccessor;
     _siteFacade          = siteFacade;
     _pageFacade          = pageFacade;
     _languageFacade      = languageFacade;
     _themeFacade         = themeFacade;
 }
Exemplo n.º 4
0
        public void Setup()
        {
            _themeId = Guid.NewGuid();

            var themeRepositoryMock = new Mock <IThemeRepository>();
            var cacheManagerMock    = new Mock <ICacheManager>();

            var mapperMock = new Mock <AutoMapper.IMapper>();

            mapperMock.Setup(x => x.Map <ThemeAdminModel>(It.IsAny <Theme>())).Returns(new ThemeAdminModel());

            _sut = new ThemeFacade(themeRepositoryMock.Object, cacheManagerMock.Object, mapperMock.Object);
        }