Fixed tests and missing logger initialization

This commit is contained in:
Taloth Saldono 2020-06-01 14:01:09 +02:00
parent 3564be19a8
commit 1e80361c3a
3 changed files with 9 additions and 1 deletions

View File

@ -7,6 +7,7 @@ using NzbDrone.Core.Parser.Model;
using NzbDrone.Core.Test.Framework;
using NzbDrone.Core.Tv;
using FizzWare.NBuilder;
using NzbDrone.Core.Download;
namespace NzbDrone.Core.Test.Download.TrackedDownloads
{
@ -26,8 +27,12 @@ namespace NzbDrone.Core.Test.Download.TrackedDownloads
.With(r => r.Episodes = _episodes)
.Build();
var downloadItem = Builder<DownloadClientItem>.CreateNew()
.Build();
_trackedDownload = Builder<TrackedDownload>.CreateNew()
.With(t => t.RemoteEpisode = remoteEpisode)
.With(t => t.DownloadItem = downloadItem)
.Build();
_historyItems = new List<EpisodeHistory>();

View File

@ -150,7 +150,7 @@ namespace NzbDrone.Core.Test.TvTests
}
[Test]
public void should_not_set_monitored_status_for_old_episodes_to_false_if_recent_enough()
public void should_not_set_monitored_status_for_old_episodes_to_false_if_episodes_existed()
{
var series = GetSeries();
series.Seasons = new List<Season>();
@ -176,6 +176,8 @@ namespace NzbDrone.Core.Test.TvTests
_insertedEpisodes[1].Monitored.Should().Be(true);
_insertedEpisodes[2].Monitored.Should().Be(true);
_insertedEpisodes[3].Monitored.Should().Be(true);
ExceptionVerification.ExpectedWarns(1);
}
[Test]

View File

@ -46,6 +46,7 @@ namespace NzbDrone.Core.Download
_parsingService = parsingService;
_seriesService = seriesService;
_trackedDownloadAlreadyImported = trackedDownloadAlreadyImported;
_logger = logger;
}
public void Check(TrackedDownload trackedDownload)