Ejemplo n.º 1
0
        public void TestInit()
        {
            this.mockHNConverterService = new Mock <IHNConverterService>();
            this.mockHNConverterService.Setup(s => s.MapToIds(It.IsAny <string>())).Returns(GetIds());
            this.mockHNConverterService.Setup(s => s.MapToItem(It.IsAny <string>())).Returns(GetStoryItem());

            this.hnWrapperService = new HNWrapperService("");
        }
Ejemplo n.º 2
0
 public NewsController(IConfiguration configuration)
 {
     this.configuration = configuration ?? throw new ArgumentNullException(nameof(configuration));
     hnWrapperService   = new HNWrapperService(configuration["HN:Url"]);
 }