Your ROOT_URL in app.ini is https://git.cloudchain.link/ but you are visiting https://dash.bss.nz/open-source-mirrors/Lidarr/commit/5014745f88dad48b8a6e509272e6f78d824ca8ec
You should set ROOT_URL correctly, otherwise the web may not work correctly.
2 changed files with
43 additions and
1 deletions
@ -72,10 +72,13 @@ namespace NzbDrone.Core.Test.ProviderTests.PostDownloadProviderTests
. Setup ( c = > c . GetDirectorySize ( It . IsAny < String > ( ) ) )
. Returns ( 10 ) ;
Mocker . GetMock < DiskProvider > ( )
. Setup ( c = > c . FolderExists ( It . IsAny < String > ( ) ) )
. Returns ( true ) ;
//Act
Mocker . Resolve < PostDownloadProvider > ( ) . ProcessDropFolder ( @"C:\drop\" ) ;
//Assert
Mocker . GetMock < DiskScanProvider > ( ) . Verify ( c = > c . Scan ( It . IsAny < Series > ( ) , subFolders [ 0 ] ) , Times . Once ( ) ) ;
Mocker . GetMock < DiskScanProvider > ( ) . Verify ( c = > c . Scan ( It . IsAny < Series > ( ) , subFolders [ 1 ] ) , Times . Never ( ) ) ;
@ -112,6 +115,10 @@ namespace NzbDrone.Core.Test.ProviderTests.PostDownloadProviderTests
. Setup ( c = > c . GetDirectorySize ( It . IsAny < String > ( ) ) )
. Returns ( 10 ) ;
Mocker . GetMock < DiskProvider > ( )
. Setup ( c = > c . FolderExists ( It . IsAny < String > ( ) ) )
. Returns ( true ) ;
//Act
Mocker . Resolve < PostDownloadProvider > ( ) . ProcessDropFolder ( @"C:\drop\" ) ;
@ -49,6 +49,10 @@ namespace NzbDrone.Core.Test.ProviderTests.PostDownloadProviderTests
Mocker . GetMock < SeriesProvider > ( )
. Setup ( c = > c . FindSeries ( It . IsAny < string > ( ) ) )
. Returns ( fakeSeries ) ;
Mocker . GetMock < DiskProvider > ( )
. Setup ( s = > s . FolderExists ( fakeSeries . Path ) )
. Returns ( true ) ;
}
private void WithImportableFiles ( )
@ -156,6 +160,10 @@ namespace NzbDrone.Core.Test.ProviderTests.PostDownloadProviderTests
. Setup ( s = > s . FreeDiskSpace ( new DirectoryInfo ( series . Path ) ) )
. Returns ( 9 ) ;
Mocker . GetMock < DiskProvider > ( )
. Setup ( s = > s . FolderExists ( series . Path ) )
. Returns ( true ) ;
//Act
Mocker . Resolve < PostDownloadProvider > ( ) . ProcessVideoFile ( downloadName ) ;
@ -211,5 +219,32 @@ namespace NzbDrone.Core.Test.ProviderTests.PostDownloadProviderTests
//Assert
Mocker . GetMock < DiskScanProvider > ( ) . Verify ( c = > c . ImportFile ( fakeSeries , downloadName ) , Times . Once ( ) ) ;
}
[Test]
public void should_return_if_series_Path_doesnt_exist ( )
{
var downloadName = @"C:\Test\Drop\30.Rock.S01E01.Pilot.mkv" ;
WithValidSeries ( ) ;
Mocker . GetMock < DiskProvider > ( )
. Setup ( s = > s . GetDirectorySize ( downloadName ) )
. Returns ( 10 ) ;
Mocker . GetMock < DiskProvider > ( )
. Setup ( s = > s . FreeDiskSpace ( It . IsAny < DirectoryInfo > ( ) ) )
. Returns ( 10 ) ;
Mocker . GetMock < DiskProvider > ( )
. Setup ( s = > s . FolderExists ( fakeSeries . Path ) )
. Returns ( false ) ;
//Act
Mocker . Resolve < PostDownloadProvider > ( ) . ProcessVideoFile ( downloadName ) ;
//Assert
ExceptionVerification . ExpectedWarns ( 1 ) ;
}
}
}