All tests now use base class Mocker

This commit is contained in:
kay.one 2011-12-14 20:15:53 -08:00
commit 1b45a85f3f
39 changed files with 1002 additions and 1010 deletions

View file

@ -4,12 +4,13 @@ using Moq;
using NUnit.Framework;
using NzbDrone.Core.Jobs;
using NzbDrone.Core.Model.Notification;
using NzbDrone.Core.Test.Framework;
using NzbDrone.Test.Common.AutoMoq;
namespace NzbDrone.Core.Test.JobTests
{
[TestFixture]
public class SearchJobTest
public class SearchJobTest:CoreTest
{
[TestCase(0)]
[TestCase(-1)]
@ -17,8 +18,8 @@ namespace NzbDrone.Core.Test.JobTests
[ExpectedException(typeof(ArgumentOutOfRangeException))]
public void start_target_id_less_than_0_throws_exception(int target)
{
var mocker = new AutoMoqer(MockBehavior.Strict);
mocker.Resolve<EpisodeSearchJob>().Start(new ProgressNotification("Test"), target, 0);
WithStrictMocker();
Mocker.Resolve<EpisodeSearchJob>().Start(new ProgressNotification("Test"), target, 0);
}
[TestCase(0)]
@ -27,8 +28,8 @@ namespace NzbDrone.Core.Test.JobTests
[ExpectedException(typeof(ArgumentOutOfRangeException))]
public void start_secondary_target_id_less_than_0_throws_exception(int target)
{
var mocker = new AutoMoqer(MockBehavior.Strict);
mocker.Resolve<SeasonSearchJob>().Start(new ProgressNotification("Test"), 0, target);
WithStrictMocker();
Mocker.Resolve<SeasonSearchJob>().Start(new ProgressNotification("Test"), 0, target);
}
}
}