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(""); }
public NewsController(IConfiguration configuration) { this.configuration = configuration ?? throw new ArgumentNullException(nameof(configuration)); hnWrapperService = new HNWrapperService(configuration["HN:Url"]); }