a better result
This commit is contained in:
@ -3,8 +3,6 @@
|
||||
<apikeys>
|
||||
</apikeys>
|
||||
<packageSources>
|
||||
<add key="dev" value="http://localhost:5000/index.json" protocolVersion="3" />
|
||||
<!-- <add key="isn-prod" value="https://isn.pschneider.fr/index.json" protocolVersion="3" />
|
||||
<add key="nuget.org" value="https://api.nuget.org/v3/index.json" protocolVersion="3" /> -->
|
||||
<add key="dev" value="http://localhost:5000/v3/index" protocolVersion="3" />
|
||||
</packageSources>
|
||||
</configuration>
|
||||
|
@ -1 +1 @@
|
||||
nuget install -NoCache -Verbosity detailed -ConfigFile ANuGet.Config Yavsc.Abstract
|
||||
nuget install -NoCache -Verbosity detailed -ConfigFile ANuGet.Config isn.abst
|
||||
|
4
test/data/test-isn/urls
Normal file
4
test/data/test-isn/urls
Normal file
@ -0,0 +1,4 @@
|
||||
https://api.nuget.org/v3/registration5-gz-semver2/yavsc.abstract/index.json
|
||||
https://api.nuget.org/v3/catalog0/data/2019.09.17.10.18.17/yavsc.abstract.1.0.6-rc07.json
|
||||
http://localhost:5000/v3/index
|
||||
http://localhost:5000/v3/registration/isn.abst/index.json
|
@ -33,7 +33,7 @@ namespace isn.tests
|
||||
[Fact]
|
||||
public async Task TestHttpClient()
|
||||
{
|
||||
string url = "https://isn.pschneider.fr/v3/index.json" ;
|
||||
string url = "https://isn.pschneider.fr"+Constants.ApiVersionPrefix+"/index.json" ;
|
||||
HttpClient client = new HttpClient();
|
||||
// var json = await client.GetStringAsync(new System.Uri(url));
|
||||
var response = await client.GetAsync(url);
|
||||
|
@ -1,28 +1,24 @@
|
||||
using System.Threading;
|
||||
using System;
|
||||
using Microsoft.AspNetCore.Hosting;
|
||||
using Microsoft.AspNetCore;
|
||||
using Xunit;
|
||||
using isnd.Data;
|
||||
using Microsoft.EntityFrameworkCore;
|
||||
using Microsoft.Extensions.DependencyInjection;
|
||||
using Microsoft.Extensions.Options;
|
||||
using System.Diagnostics;
|
||||
using Microsoft.AspNetCore.Hosting.Server;
|
||||
using Microsoft.AspNetCore.Hosting.Server.Features;
|
||||
using Microsoft.Extensions.Configuration;
|
||||
using isnd.tests;
|
||||
using NuGet.Protocol;
|
||||
using NuGet.Configuration;
|
||||
using System.Threading.Tasks;
|
||||
using NuGet.Protocol.Core.Types;
|
||||
using isn.abst;
|
||||
|
||||
namespace isnd.host.tests
|
||||
{
|
||||
[Collection("Web server collection")]
|
||||
public class UnitTestWebHost : IClassFixture<WebServerFixture>
|
||||
{
|
||||
const string apiindex = "/v3/index";
|
||||
const string apiindex = Constants.ApiVersionPrefix + "/index";
|
||||
WebServerFixture server;
|
||||
public UnitTestWebHost(WebServerFixture server)
|
||||
{
|
||||
@ -88,7 +84,7 @@ namespace isnd.host.tests
|
||||
PackageSource packageSource = new PackageSource(pkgSourceUrl);
|
||||
HttpSource client = new HttpSource(packageSource, PkgSourceMessageHandler, throttle);
|
||||
NuGet.Protocol.RegistrationResourceV3 res = new NuGet.Protocol.RegistrationResourceV3(client ,
|
||||
new Uri(isnSettings.ExternalUrl + "/v3/registration"));
|
||||
new Uri(isnSettings.ExternalUrl + Constants.ApiVersionPrefix + "/registration"));
|
||||
}
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user