From 299d4f53b06f62c855687d644657a4d09cbc5d35 Mon Sep 17 00:00:00 2001 From: "kay.one" Date: Mon, 5 Aug 2013 19:42:22 -0700 Subject: [PATCH] fixing linux tests. --- NzbDrone.Api.Test/DirectoryLookupServiceFixture.cs | 12 ++++++------ NzbDrone.Common.Test/ProcessProviderTests.cs | 3 ++- 2 files changed, 8 insertions(+), 7 deletions(-) diff --git a/NzbDrone.Api.Test/DirectoryLookupServiceFixture.cs b/NzbDrone.Api.Test/DirectoryLookupServiceFixture.cs index 2a8bb8911..7399a8f82 100644 --- a/NzbDrone.Api.Test/DirectoryLookupServiceFixture.cs +++ b/NzbDrone.Api.Test/DirectoryLookupServiceFixture.cs @@ -11,7 +11,7 @@ using NzbDrone.Test.Common; namespace NzbDrone.Api.Test { [TestFixture] - public class DirectoryLookupServiceFixture :TestBase + public class DirectoryLookupServiceFixture : TestBase { private const string RECYCLING_BIN = "$Recycle.Bin"; private const string SYSTEM_VOLUME_INFORMATION = "System Volume Information"; @@ -49,11 +49,11 @@ namespace NzbDrone.Api.Test e = Path.Combine(root, e); }); } - + [Test] public void should_not_contain_recycling_bin_for_root_of_drive() { - const string root = @"C:\"; + string root = @"C:\".AsOsAgnostic(); SetupFolders(root); Mocker.GetMock() @@ -64,9 +64,9 @@ namespace NzbDrone.Api.Test } [Test] - public void should_not_contain_system_volume_information_for_root_of_drive() + public void should_not_contain_system_volume_information() { - const string root = @"C:\"; + string root = @"C:\".AsOsAgnostic(); SetupFolders(root); Mocker.GetMock() @@ -79,7 +79,7 @@ namespace NzbDrone.Api.Test [Test] public void should_not_contain_recycling_bin_or_system_volume_information_for_root_of_drive() { - const string root = @"C:\"; + string root = @"C:\"; SetupFolders(root); Mocker.GetMock() diff --git a/NzbDrone.Common.Test/ProcessProviderTests.cs b/NzbDrone.Common.Test/ProcessProviderTests.cs index 1f40fe665..126464107 100644 --- a/NzbDrone.Common.Test/ProcessProviderTests.cs +++ b/NzbDrone.Common.Test/ProcessProviderTests.cs @@ -1,6 +1,7 @@ using System; using System.ComponentModel; using System.Diagnostics; +using System.IO; using System.Linq; using FluentAssertions; using NUnit.Framework; @@ -48,7 +49,7 @@ namespace NzbDrone.Common.Test [Test] public void Should_be_able_to_start_process() { - var startInfo = new ProcessStartInfo(DummyApp.DUMMY_PROCCESS_NAME + ".exe"); + var startInfo = new ProcessStartInfo(Path.Combine(Directory.GetCurrentDirectory(), DummyApp.DUMMY_PROCCESS_NAME + ".exe")); Subject.Exists(DummyApp.DUMMY_PROCCESS_NAME).Should()