From 85fd0e1c22755f2cef80fe86574140bc22c43a5a Mon Sep 17 00:00:00 2001 From: "kay.one" Date: Mon, 22 Apr 2013 00:21:39 -0700 Subject: [PATCH] logging update. --- NzbDrone.Core/Jobs/JobController.cs | 2 +- NzbDrone.Core/Jobs/JobQueueItem.cs | 7 ++++++- NzbDrone.Integration.Test/SeriesIntegrationTest.cs | 8 +++++++- 3 files changed, 14 insertions(+), 3 deletions(-) diff --git a/NzbDrone.Core/Jobs/JobController.cs b/NzbDrone.Core/Jobs/JobController.cs index 4a4360447..e56d38ca5 100644 --- a/NzbDrone.Core/Jobs/JobController.cs +++ b/NzbDrone.Core/Jobs/JobController.cs @@ -58,7 +58,7 @@ namespace NzbDrone.Core.Jobs { if (IsProcessing) { - _logger.Trace("Queue is already running. Ignoring scheduler's request."); + _logger.Trace("Queue is already running. Ignoring scheduler request."); return; } diff --git a/NzbDrone.Core/Jobs/JobQueueItem.cs b/NzbDrone.Core/Jobs/JobQueueItem.cs index 25a9cd8ed..53c274276 100644 --- a/NzbDrone.Core/Jobs/JobQueueItem.cs +++ b/NzbDrone.Core/Jobs/JobQueueItem.cs @@ -17,7 +17,12 @@ namespace NzbDrone.Core.Jobs public override string ToString() { - return string.Format("[{0}({1})]", JobType.Name, Options); + if (Options != null) + { + return string.Format("[{0}({1})]", JobType.Name, Options); + } + + return string.Format("[{0}]", JobType.Name); } public enum JobSourceType diff --git a/NzbDrone.Integration.Test/SeriesIntegrationTest.cs b/NzbDrone.Integration.Test/SeriesIntegrationTest.cs index 5c902517a..e037fd22b 100644 --- a/NzbDrone.Integration.Test/SeriesIntegrationTest.cs +++ b/NzbDrone.Integration.Test/SeriesIntegrationTest.cs @@ -1,6 +1,8 @@ -using System.Net; +using System.IO; +using System.Net; using FluentAssertions; using NUnit.Framework; +using NzbDrone.Api.RootFolders; using NzbDrone.Api.Series; using System.Linq; @@ -36,6 +38,10 @@ namespace NzbDrone.Integration.Test { var series = Series.Lookup("archer").First(); + var rootFolder = RootFolders.Post(new RootFolderResource { Path = Directory.GetCurrentDirectory() }); + + series.RootFolderId = rootFolder.Id; + Series.Post(series); Series.All().Should().HaveCount(1);