Fixed tests

pull/4239/head
Taloth Saldono 4 years ago
parent f4d14301f1
commit 7e045f3e3c

@ -42,6 +42,7 @@ namespace NzbDrone.Core.Test.DecisionEngineTests.Search.SingleEpisodeSearchMatch
{ {
_remoteEpisode.ParsedEpisodeInfo.SeasonNumber = 10; _remoteEpisode.ParsedEpisodeInfo.SeasonNumber = 10;
_remoteEpisode.MappedSeasonNumber = 5; // 10 -> 5 mapping _remoteEpisode.MappedSeasonNumber = 5; // 10 -> 5 mapping
_searchCriteria.SeasonNumber = 10; // searching by tvdb 5 = 10 scene
Subject.IsSatisfiedBy(_remoteEpisode, _searchCriteria).Accepted.Should().BeTrue(); Subject.IsSatisfiedBy(_remoteEpisode, _searchCriteria).Accepted.Should().BeTrue();
} }
@ -51,6 +52,7 @@ namespace NzbDrone.Core.Test.DecisionEngineTests.Search.SingleEpisodeSearchMatch
{ {
_remoteEpisode.ParsedEpisodeInfo.SeasonNumber = 10; _remoteEpisode.ParsedEpisodeInfo.SeasonNumber = 10;
_remoteEpisode.MappedSeasonNumber = 6; // 9 -> 5 mapping _remoteEpisode.MappedSeasonNumber = 6; // 9 -> 5 mapping
_searchCriteria.SeasonNumber = 9; // searching by tvdb 5 = 9 scene
Subject.IsSatisfiedBy(_remoteEpisode, _searchCriteria).Accepted.Should().BeFalse(); Subject.IsSatisfiedBy(_remoteEpisode, _searchCriteria).Accepted.Should().BeFalse();
} }

@ -55,6 +55,10 @@ namespace NzbDrone.Core.Test.IndexerSearchTests
Mocker.GetMock<ISceneMappingService>() Mocker.GetMock<ISceneMappingService>()
.Setup(s => s.FindByTvdbId(It.IsAny<int>())) .Setup(s => s.FindByTvdbId(It.IsAny<int>()))
.Returns(new List<SceneMapping>()); .Returns(new List<SceneMapping>());
Mocker.GetMock<ISceneMappingService>()
.Setup(s => s.GetSceneNames(It.IsAny<int>(), It.IsAny<List<int>>(), It.IsAny<List<int>>()))
.Returns(new List<string>());
} }
private void WithEpisode(int seasonNumber, int episodeNumber, int? sceneSeasonNumber, int? sceneEpisodeNumber, string airDate = null) private void WithEpisode(int seasonNumber, int episodeNumber, int? sceneSeasonNumber, int? sceneEpisodeNumber, string airDate = null)

Loading…
Cancel
Save