Fixed newznab testing and saving

This commit is contained in:
Mark McDowall 2014-07-07 13:12:00 -07:00
parent 1ef756acd2
commit 07cb7edfcf
2 changed files with 5 additions and 5 deletions

View File

@ -20,7 +20,7 @@ namespace NzbDrone.Core.Test.IndexerTests
{ {
_indexers = new List<IIndexer>(); _indexers = new List<IIndexer>();
_indexers.Add(new Newznab()); _indexers.Add(Mocker.GetMock<Newznab>().Object);
_indexers.Add(new Omgwtfnzbs()); _indexers.Add(new Omgwtfnzbs());
_indexers.Add(new Wombles()); _indexers.Add(new Wombles());

View File

@ -16,9 +16,7 @@ namespace NzbDrone.Core.Indexers.Newznab
private readonly IFetchFeedFromIndexers _feedFetcher; private readonly IFetchFeedFromIndexers _feedFetcher;
private readonly HttpProvider _httpProvider; private readonly HttpProvider _httpProvider;
private readonly Logger _logger; private readonly Logger _logger;
public Newznab(IFetchFeedFromIndexers feedFetcher, HttpProvider httpProvider, Logger logger) public Newznab(IFetchFeedFromIndexers feedFetcher, HttpProvider httpProvider, Logger logger)
{ {
_feedFetcher = feedFetcher; _feedFetcher = feedFetcher;
@ -26,7 +24,9 @@ namespace NzbDrone.Core.Indexers.Newznab
_logger = logger; _logger = logger;
} }
public Newznab() //protected so it can be mocked, but not used for DI
//TODO: Is there a better way to achieve this?
protected Newznab()
{ {
} }