added new episode number unit test

This commit is contained in:
Luke Pulverenti 2014-07-19 15:55:22 -04:00
parent bc657237aa
commit a19c6adcb7

View File

@ -9,6 +9,8 @@ namespace MediaBrowser.Tests.Resolvers
[TestMethod]
public void TestGetEpisodeNumberFromFile()
{
Assert.AreEqual(03, TVUtils.GetEpisodeNumberFromFile(@"S02E03 blah.avi", true));
Assert.AreEqual(02, TVUtils.GetEpisodeNumberFromFile(@"Season 1\01x02 blah.avi", true));
Assert.AreEqual(02, TVUtils.GetEpisodeNumberFromFile(@"Season 1\S01x02 blah.avi", true));
Assert.AreEqual(02, TVUtils.GetEpisodeNumberFromFile(@"Season 1\S01E02 blah.avi", true));
@ -140,6 +142,9 @@ namespace MediaBrowser.Tests.Resolvers
[TestMethod]
public void TestGetSeasonNumberFromPath() {
Assert.AreEqual(02, TVUtils.GetSeasonNumberFromEpisodeFile(@"\Show\Season 02\S02E03 blah.avi"));
Assert.AreEqual(1, TVUtils.GetSeasonNumberFromPath(@"\Drive\Season 1"));
Assert.AreEqual(1, TVUtils.GetSeasonNumberFromPath(@"\Drive\Season 1"));
Assert.AreEqual(1, TVUtils.GetSeasonNumberFromPath(@"\Drive\Season 1"));