mirror of https://github.com/Sonarr/Sonarr
Fixed broken tests
This commit is contained in:
parent
390dfbdee8
commit
b43397752e
|
@ -11,12 +11,6 @@ namespace NzbDrone.Common.Test
|
|||
{
|
||||
readonly EnviromentProvider enviromentController = new EnviromentProvider();
|
||||
|
||||
[Test]
|
||||
public void Is_user_interactive_should_be_false()
|
||||
{
|
||||
enviromentController.IsUserInteractive.Should().BeTrue();
|
||||
}
|
||||
|
||||
[Test]
|
||||
public void StartupPath_should_not_be_empty()
|
||||
{
|
||||
|
|
|
@ -16,7 +16,7 @@ namespace NzbDrone.Core.Test
|
|||
{
|
||||
[TestFixture]
|
||||
// ReSharper disable InconsistentNaming
|
||||
class CentralDispatchTest : TestBase
|
||||
class CentralDispatchFixture : TestBase
|
||||
{
|
||||
readonly IList<Type> indexers = typeof(CentralDispatch).Assembly.GetTypes().Where(t => t.IsSubclassOf(typeof(IndexerBase))).ToList();
|
||||
readonly IList<Type> jobs = typeof(CentralDispatch).Assembly.GetTypes().Where(t => t.GetInterfaces().Contains(typeof(IJob))).ToList();
|
|
@ -14,8 +14,6 @@ namespace NzbDrone.Core.Test.Framework
|
|||
{
|
||||
static TestBase()
|
||||
{
|
||||
InitLogging();
|
||||
|
||||
var oldDbFiles = Directory.GetFiles(Directory.GetCurrentDirectory(), "*.sdf", SearchOption.AllDirectories);
|
||||
foreach (var file in oldDbFiles)
|
||||
{
|
||||
|
@ -47,6 +45,8 @@ namespace NzbDrone.Core.Test.Framework
|
|||
[SetUp]
|
||||
public virtual void SetupBase()
|
||||
{
|
||||
InitLogging();
|
||||
|
||||
ExceptionVerification.Reset();
|
||||
if (Directory.Exists(TempFolder))
|
||||
{
|
||||
|
|
|
@ -99,7 +99,7 @@
|
|||
<Compile Include="JobTests\SeriesSearchJobTest.cs" />
|
||||
<Compile Include="ProviderTests\SearchProviderTest_Season.cs" />
|
||||
<Compile Include="ProviderTests\EventClientProviderTest.cs" />
|
||||
<Compile Include="CentralDispatchTest.cs" />
|
||||
<Compile Include="CentralDispatchFixture.cs" />
|
||||
<Compile Include="ProviderTests\XbmcProviderTest.cs" />
|
||||
<Compile Include="ProviderTests\DiskScanProviderTest.cs" />
|
||||
<Compile Include="ProviderTests\EpisodeProviderTest_GetEpisodesByParseResult.cs" />
|
||||
|
|
|
@ -1,6 +1,5 @@
|
|||
using NLog;
|
||||
using NLog.Config;
|
||||
using NUnit.Framework;
|
||||
using NzbDrone.Common;
|
||||
|
||||
namespace NzbDrone.Test.Common
|
||||
|
@ -9,10 +8,14 @@ namespace NzbDrone.Test.Common
|
|||
{
|
||||
protected static void InitLogging()
|
||||
{
|
||||
LogConfiguration.RegisterConsoleLogger(LogLevel.Trace);
|
||||
LogConfiguration.RegisterUdpLogger();
|
||||
if (LogManager.Configuration == null || LogManager.Configuration is XmlLoggingConfiguration)
|
||||
{
|
||||
LogManager.Configuration = new LoggingConfiguration();
|
||||
LogConfiguration.RegisterConsoleLogger(LogLevel.Trace);
|
||||
LogConfiguration.RegisterUdpLogger();
|
||||
|
||||
RegisterExceptionVerification();
|
||||
RegisterExceptionVerification();
|
||||
}
|
||||
}
|
||||
|
||||
private static void RegisterExceptionVerification()
|
||||
|
|
Loading…
Reference in New Issue