mirror of
https://github.com/lidarr/lidarr.git
synced 2025-08-14 10:47:08 -07:00
PostDownloadProvider broken down further.
Will try to reprocess _NzbDrone_ directories each pass, but will mark with an error when possible. Attempt to process _UNPACK_ and _FAILED_ directories 30 minutes after first detected by NzbDrone (to give SAB time to unpack properly before processing).
This commit is contained in:
parent
04ed22db55
commit
8cac84b4ad
9 changed files with 362 additions and 43 deletions
|
@ -1466,10 +1466,10 @@ namespace NzbDrone.Core.Test
|
|||
result.Should().BeFalse();
|
||||
}
|
||||
|
||||
[TestCase("The Office (US) - S01E05 - Episode Title", PostDownloadStatusType.Unpacking, 1)]
|
||||
[TestCase("The Office (US) - S01E05 - Episode Title", PostDownloadStatusType.Failed, 1)]
|
||||
[TestCase("The Office (US) - S01E05E06 - Episode Title", PostDownloadStatusType.Unpacking, 2)]
|
||||
[TestCase("The Office (US) - S01E05E06 - Episode Title", PostDownloadStatusType.Failed, 2)]
|
||||
[TestCase("The Office (US) - S01E01 - Episode Title", PostDownloadStatusType.Unpacking, 1)]
|
||||
[TestCase("The Office (US) - S01E01 - Episode Title", PostDownloadStatusType.Failed, 1)]
|
||||
[TestCase("The Office (US) - S01E01E02 - Episode Title", PostDownloadStatusType.Unpacking, 2)]
|
||||
[TestCase("The Office (US) - S01E01E02 - Episode Title", PostDownloadStatusType.Failed, 2)]
|
||||
[TestCase("The Office (US) - Season 01 - Episode Title", PostDownloadStatusType.Unpacking, 10)]
|
||||
[TestCase("The Office (US) - Season 01 - Episode Title", PostDownloadStatusType.Failed, 10)]
|
||||
public void SetPostDownloadStatus(string folderName, PostDownloadStatusType postDownloadStatus, int episodeCount)
|
||||
|
@ -1483,7 +1483,7 @@ namespace NzbDrone.Core.Test
|
|||
.With(s => s.CleanTitle = "officeus")
|
||||
.Build();
|
||||
|
||||
var fakeEpisodes = Builder<Episode>.CreateListOfSize(10)
|
||||
var fakeEpisodes = Builder<Episode>.CreateListOfSize(episodeCount)
|
||||
.WhereAll()
|
||||
.Have(c => c.SeriesId = 12345)
|
||||
.Have(c => c.SeasonNumber = 1)
|
||||
|
@ -1496,7 +1496,7 @@ namespace NzbDrone.Core.Test
|
|||
mocker.GetMock<SeriesProvider>().Setup(s => s.FindSeries("officeus")).Returns(fakeSeries);
|
||||
|
||||
//Act
|
||||
mocker.Resolve<EpisodeProvider>().SetPostDownloadStatus(folderName, postDownloadStatus);
|
||||
mocker.Resolve<EpisodeProvider>().SetPostDownloadStatus(fakeEpisodes.Select(e => e.EpisodeId), postDownloadStatus);
|
||||
|
||||
//Assert
|
||||
var result = db.Fetch<Episode>();
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue