mirror of
https://github.com/Readarr/Readarr.git
synced 2026-04-25 22:36:59 -04:00
@@ -21,7 +21,8 @@ namespace NzbDrone.Common.Test.Http
|
||||
{
|
||||
[IntegrationTest]
|
||||
[TestFixture(typeof(ManagedHttpDispatcher))]
|
||||
public class HttpClientFixture<TDispatcher> : TestBase<HttpClient> where TDispatcher : IHttpDispatcher
|
||||
public class HttpClientFixture<TDispatcher> : TestBase<HttpClient>
|
||||
where TDispatcher : IHttpDispatcher
|
||||
{
|
||||
private static string[] _httpBinHosts = new[] { "eu.httpbin.org", "httpbin.org" };
|
||||
private static int _httpBinRandom;
|
||||
@@ -557,7 +558,7 @@ namespace NzbDrone.Common.Test.Http
|
||||
[Test]
|
||||
public void should_call_interceptor()
|
||||
{
|
||||
Mocker.SetConstant<IEnumerable<IHttpRequestInterceptor>>(new [] { Mocker.GetMock<IHttpRequestInterceptor>().Object });
|
||||
Mocker.SetConstant<IEnumerable<IHttpRequestInterceptor>>(new[] { Mocker.GetMock<IHttpRequestInterceptor>().Object });
|
||||
|
||||
Mocker.GetMock<IHttpRequestInterceptor>()
|
||||
.Setup(v => v.PreRequest(It.IsAny<HttpRequest>()))
|
||||
|
||||
@@ -1,11 +1,11 @@
|
||||
using NUnit.Framework;
|
||||
using FluentAssertions;
|
||||
using NzbDrone.Test.Common;
|
||||
using System;
|
||||
using System.Text;
|
||||
using NzbDrone.Common.Http;
|
||||
using System;
|
||||
using System.Collections.Specialized;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using FluentAssertions;
|
||||
using NUnit.Framework;
|
||||
using NzbDrone.Common.Http;
|
||||
using NzbDrone.Test.Common;
|
||||
|
||||
namespace NzbDrone.Common.Test.Http
|
||||
{
|
||||
|
||||
@@ -35,7 +35,6 @@ namespace NzbDrone.Common.Test.Http
|
||||
var request = builder.Resource("/v1/").Build();
|
||||
|
||||
request.Url.FullUri.Should().Be("http://domain/v1/");
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -6,4 +6,4 @@ namespace NzbDrone.Common.Test.Http
|
||||
public class HttpRequestFixture
|
||||
{
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -84,7 +84,7 @@ namespace NzbDrone.Common.Test.Http
|
||||
public void should_combine_relative_path(string basePath, string relativePath, string expected)
|
||||
{
|
||||
var newUri = new HttpUri(basePath).CombinePath(relativePath);
|
||||
|
||||
|
||||
newUri.FullUri.Should().Be(expected);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -27,4 +27,4 @@ namespace NzbDrone.Common.Test.Http
|
||||
Subject.GetUserAgent(false).Should().NotBeNullOrWhiteSpace();
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user