Fixed: Use empty string when {Original Title} is not available

This commit is contained in:
Mark McDowall
2014-09-28 00:47:24 -07:00
parent d34a170214
commit 3f11fcf2e1
2 changed files with 14 additions and 1 deletions
@@ -1,3 +1,4 @@
using System;
using System.Collections.Generic;
using System.IO;
using System.Linq;
@@ -615,5 +616,17 @@ namespace NzbDrone.Core.Test.OrganizerTests
Subject.BuildFileName(new List<Episode> { _episode1 }, _series, _episodeFile)
.Should().Be("Venture.Bros.15x06");
}
[Test]
public void should_use_empty_string_instead_of_null_when_scene_name_is_not_available()
{
_namingConfig.RenameEpisodes = true;
_namingConfig.StandardEpisodeFormat = "{Original Title}";
_episodeFile.SceneName = null;
Subject.BuildFileName(new List<Episode> { _episode1 }, _series, _episodeFile)
.Should().Be(String.Empty);
}
}
}