removed dead code

This commit is contained in:
Keivan Beigi
2014-10-03 16:29:52 -07:00
parent 7b49669b95
commit 6a743a8792
19 changed files with 15 additions and 342 deletions
@@ -61,28 +61,6 @@ namespace NzbDrone.Core.Test.RootFolderTests
Mocker.GetMock<IRootFolderRepository>().Verify(c => c.Delete(1), Times.Once());
}
[Test]
public void should_return_empty_list_when_folder_doesnt_exist()
{
WithNonExistingFolder();
Mocker.GetMock<IRootFolderRepository>().Setup(c => c.All()).Returns(new List<RootFolder>());
const string path = "d:\\bad folder";
var result = Subject.GetUnmappedFolders(path);
result.Should().NotBeNull();
result.Should().BeEmpty();
Mocker.GetMock<IDiskProvider>().Verify(c => c.GetDirectories(It.IsAny<String>()), Times.Never());
}
[Test]
public void GetUnmappedFolders_throw_on_empty_folders()
{
Assert.Throws<ArgumentException>(() => Mocker.Resolve<RootFolderService>().GetUnmappedFolders(""));
}
[TestCase("")]
[TestCase(null)]
[TestCase("BAD PATH")]
@@ -101,25 +79,6 @@ namespace NzbDrone.Core.Test.RootFolderTests
Assert.Throws<InvalidOperationException>(() => Subject.Add(new RootFolder { Path = @"C:\TV".AsOsAgnostic() }));
}
[Test]
public void should_not_include_system_files_and_folders()
{
Mocker.GetMock<IDiskProvider>()
.Setup(s => s.GetDirectories(It.IsAny<String>()))
.Returns(new string[]
{
@"C:\30 Rock".AsOsAgnostic(),
@"C:\$Recycle.Bin".AsOsAgnostic(),
@"C:\.AppleDouble".AsOsAgnostic(),
@"C:\Test\.AppleDouble".AsOsAgnostic()
});
Mocker.GetMock<ISeriesService>()
.Setup(s => s.GetAllSeries())
.Returns(new List<Series>());
Subject.GetUnmappedFolders(@"C:\")
.Should().OnlyContain(u => u.Path == @"C:\30 Rock".AsOsAgnostic());
}
}
}