예제 #1
0
        public void Setup()
        {
            _httpTest = new HttpTest();
            _fixture  = new Fixture();

            _configuration = new Mock <IConfiguration>();

            var _mockConfSection = new Mock <IConfigurationSection>();

            _mockConfSection.SetupGet(m => m[It.Is <string>(s => s == "default")]).Returns("mock value");

            _httpService = new HttpService();

            _configuration.Setup(a => a.GetSection(It.Is <string>(s => s == "base.url.api"))).Returns(_mockConfSection.Object);
            _configuration.Setup(s => s.GetSection(It.Is <string>(t => t == "sufix.url.listid.api"))).Returns(_mockConfSection.Object);
            _configuration.Setup(d => d.GetSection(It.Is <string>(f => f == "sufix.url.desc.api"))).Returns(_mockConfSection.Object);


            _acl = new StoriesAcl(_configuration.Object, _httpService);
        }
예제 #2
0
 public StoriesIDsChain(IStoriesAcl storiesAcl)
 {
     _storiesAcl = storiesAcl;
 }
 public BestStoriesService(IStoriesAcl storiesAcl)
 {
     _storiesAcl = storiesAcl;
 }
예제 #4
0
 public StoriesDescriptionChain(IStoriesAcl storiesAcl)
 {
     _storiesAcl = storiesAcl;
 }