mirror of
https://github.com/Sonarr/Sonarr
synced 2025-01-18 21:29:46 +00:00
Fixed: Sample check has too little margin for 2 min anime with 1 minute files. Lowered to 15 sec.
This commit is contained in:
parent
b485bdaeec
commit
b63bcd16a7
2 changed files with 24 additions and 0 deletions
|
@ -121,6 +121,24 @@ namespace NzbDrone.Core.Test.MediaFiles.EpisodeImport
|
|||
ShouldBeFalse();
|
||||
}
|
||||
|
||||
[Test]
|
||||
public void should_return_false_if_runtime_greater_than_anime_short_minimum()
|
||||
{
|
||||
_series.Runtime = 2;
|
||||
GivenRuntime(60);
|
||||
|
||||
ShouldBeFalse();
|
||||
}
|
||||
|
||||
[Test]
|
||||
public void should_return_true_if_runtime_less_than_anime_short_minimum()
|
||||
{
|
||||
_series.Runtime = 2;
|
||||
GivenRuntime(10);
|
||||
|
||||
ShouldBeTrue();
|
||||
}
|
||||
|
||||
[Test]
|
||||
public void should_fall_back_to_file_size_if_mediainfo_dll_not_found_acceptable_size()
|
||||
{
|
||||
|
|
|
@ -100,6 +100,12 @@ namespace NzbDrone.Core.MediaFiles.EpisodeImport
|
|||
|
||||
private int GetMinimumAllowedRuntime(Series series)
|
||||
{
|
||||
//Anime short - 15 seconds
|
||||
if (series.Runtime <= 3)
|
||||
{
|
||||
return 15;
|
||||
}
|
||||
|
||||
//Webisodes - 90 seconds
|
||||
if (series.Runtime <= 10)
|
||||
{
|
||||
|
|
Loading…
Reference in a new issue