Do not unmonitor episodes after using Manual File Import
This commit is contained in:
parent
dd3899806b
commit
77fdebc366
|
@ -119,5 +119,20 @@ namespace NzbDrone.Core.Test.TvTests.EpisodeServiceTests
|
||||||
Mocker.GetMock<IEpisodeRepository>()
|
Mocker.GetMock<IEpisodeRepository>()
|
||||||
.Verify(v => v.ClearFileId(It.IsAny<Episode>(), false), Times.Once());
|
.Verify(v => v.ClearFileId(It.IsAny<Episode>(), false), Times.Once());
|
||||||
}
|
}
|
||||||
|
|
||||||
|
[Test]
|
||||||
|
public void should_leave_monitored_to_true_if_autoUnmonitor_is_true_and_is_for_manual_override()
|
||||||
|
{
|
||||||
|
GivenSingleEpisodeFile();
|
||||||
|
|
||||||
|
Mocker.GetMock<IConfigService>()
|
||||||
|
.SetupGet(s => s.AutoUnmonitorPreviouslyDownloadedEpisodes)
|
||||||
|
.Returns(true);
|
||||||
|
|
||||||
|
Subject.Handle(new EpisodeFileDeletedEvent(_episodeFile, DeleteMediaFileReason.ManualOverride));
|
||||||
|
|
||||||
|
Mocker.GetMock<IEpisodeRepository>()
|
||||||
|
.Verify(v => v.ClearFileId(It.IsAny<Episode>(), false), Times.Once());
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -221,7 +221,7 @@ namespace NzbDrone.Core.Tv
|
||||||
{
|
{
|
||||||
_logger.Debug("Detaching episode {0} from file.", episode.Id);
|
_logger.Debug("Detaching episode {0} from file.", episode.Id);
|
||||||
|
|
||||||
var unmonitorForReason = message.Reason != DeleteMediaFileReason.Upgrade ||
|
var unmonitorForReason = message.Reason != DeleteMediaFileReason.Upgrade &&
|
||||||
message.Reason != DeleteMediaFileReason.ManualOverride;
|
message.Reason != DeleteMediaFileReason.ManualOverride;
|
||||||
|
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue