mirror of
https://github.com/Readarr/Readarr.git
synced 2026-04-18 21:34:28 -04:00
added custom IntConverter to get around the mono bug
http://json.codeplex.com/workitem/24176
This commit is contained in:
+9
-1
@@ -4,6 +4,7 @@ using FizzWare.NBuilder;
|
||||
using Moq;
|
||||
using NUnit.Framework;
|
||||
using NzbDrone.Common;
|
||||
using NzbDrone.Common.Serializer;
|
||||
using NzbDrone.Core.Configuration;
|
||||
using NzbDrone.Core.Download.Clients.Nzbget;
|
||||
using NzbDrone.Core.Parser.Model;
|
||||
@@ -51,9 +52,16 @@ namespace NzbDrone.Core.Test.Download.DownloadClientTests.NzbgetProviderTests
|
||||
[Test]
|
||||
public void should_add_item_to_queue()
|
||||
{
|
||||
|
||||
var command = new JsonRequest
|
||||
{
|
||||
Method = "appendurl",
|
||||
Params = new object[] { "30.Rock.S01E01.Pilot.720p.hdtv.nzb", "TV", 50, false, "http://www.nzbdrone.com" }
|
||||
};
|
||||
|
||||
Mocker.GetMock<IHttpProvider>()
|
||||
.Setup(s => s.PostCommand("192.168.5.55:6789", "nzbget", "pass",
|
||||
It.Is<String>(c => c.Equals("{\"method\":\"appendurl\",\"params\":[\"30.Rock.S01E01.Pilot.720p.hdtv.nzb\",\"TV\",50,false,\"http://www.nzbdrone.com\"]}"))))
|
||||
It.Is<String>(c => c.Equals(command.ToJson()))))
|
||||
.Returns("{\"version\": \"1.1\",\"result\": true}");
|
||||
|
||||
Mocker.Resolve<NzbgetClient>().DownloadNzb(_remoteEpisode);
|
||||
|
||||
Reference in New Issue
Block a user