bump sdk to net-9

This commit is contained in:
Paul Schneider
2025-06-08 14:41:50 +01:00
parent a1722a87ae
commit d1b0f5e6d9
30 changed files with 372 additions and 1067 deletions

View File

@ -1,25 +1,18 @@
using System;
using Microsoft.Dnx.Compilation.CSharp;
using Microsoft.Extensions.Configuration;
using Microsoft.Extensions.PlatformAbstractions;
using Xunit.Abstractions;
namespace yavscTests
{
public class BaseTestContext {
protected IApplicationEnvironment applicationEnvironment = null;
protected IServiceProvider serviceProvider = null;
protected IConfigurationRoot configurationRoot;
protected BeforeCompileContext beforeCompileContext;
protected IServiceProvider provider;
protected IConfigurationRoot configuration;
protected readonly ITestOutputHelper _output;
protected ServerSideFixture _serverFixture;
public BaseTestContext(ITestOutputHelper output, ServerSideFixture serverFixture)
public BaseTestContext( ServerSideFixture serverFixture)
{
this._output = output;
this._serverFixture = serverFixture;
}
}

View File

@ -1,41 +0,0 @@
CONFIGURATION=Debug
BINTARGET=bin/$(CONFIGURATION)/dnx451/test.dll
SOURCE_DIR=../..
MAKEFILE_DIR=$(SOURCE_DIR)/scripts/make
MSBUILD=msbuild
YAVSCSRC=../../src
all: test
include $(MAKEFILE_DIR)/dnx.mk
$(YAVSCSRC)/Yavsc/bin/$(CONFIGURATION)/dnx451/Yavsc.dll:
make -C $(YAVSCSRC)/Yavsc
$(YAVSCSRC)/Yavsc.Abstract/bin/$(CONFIGURATION)/dnx451/Yavsc.Abstract.dll:
make -C $(YAVSCSRC)/Yavsc.Abstract
$(YAVSCSRC)/Yavsc.Server/bin/$(CONFIGURATION)/dnx451/Yavsc.Server.dll:
make -C $(YAVSCSRC)/Yavsc.Server
$(BINTARGET): project.lock.json $(YAVSCSRC)/Yavsc/bin/$(CONFIGURATION)/dnx451/Yavsc.dll $(YAVSCSRC)/Yavsc.Abstract/bin/$(CONFIGURATION)/dnx451/Yavsc.Abstract.dll $(YAVSCSRC)/Yavsc.Server/bin/$(CONFIGURATION)/dnx451/Yavsc.Server.dll
dnu build --configuration $(CONFIGURATION)
non-regression: $(BINTARGET)
ASPNET_ENV=Development dnx test -maxthreads 1 -trait regression=non
all-tests: $(BINTARGET)
ASPNET_ENV=Testing dnx test -maxthreads 1
regression: $(BINTARGET)
ASPNET_ENV=Testing dnx test -maxthreads 1 -trait regression=oui
test: all-tests
testdev: $(BINTARGET)
ASPNET_ENV=Development dnx test -maxthreads 1 -trait dev=wip
clean:
rm -rf bin obj testingrepo
.PHONY: test

View File

@ -64,7 +64,7 @@ namespace yavscTests
public static string ApiKey { get; private set; }
public Startup(IHostingEnvironment env, IApplicationEnvironment appEnv)
public Startup(IHostingEnvironment env)
{
var devtag = env.IsDevelopment() ? "D" : "";
var prodtag = env.IsProduction() ? "P" : "";

View File

@ -1,23 +0,0 @@
using System;
using System.Threading.Tasks;
using Microsoft.AspNetCore.Hosting.Server;
using Microsoft.AspNetCore.Http.Features;
using Microsoft.Extensions.Configuration;
namespace Yavsc.Server
{
public class CliServerFactory : IServerFactory
{
public IFeatureCollection Initialize(IConfiguration configuration)
{
FeatureCollection featureCollection = new FeatureCollection();
return featureCollection;
}
public IDisposable Start(IFeatureCollection serverFeatures, Func<IFeatureCollection, Task> application)
{
var task = application(serverFeatures);
return task;
}
}
}

View File

@ -8,10 +8,12 @@
<ItemGroup>
<PackageReference Include="Microsoft.AspNetCore.Hosting" Version="2.3.0" />
<PackageReference Include="Microsoft.Extensions.Caching.Memory" Version="8.0.1" />
<PackageReference Include="Microsoft.Extensions.Options" Version="8.0.2" />
<PackageReference Include="Microsoft.Extensions.Options.ConfigurationExtensions" Version="8.0.0" />
<PackageReference Include="Microsoft.Extensions.Caching.Memory" Version="9.0.3" />
<PackageReference Include="Microsoft.Extensions.Options" Version="9.0.3" />
<PackageReference Include="Microsoft.Extensions.Options.ConfigurationExtensions" Version="9.0.3" />
<PackageReference Include="Newtonsoft.Json" Version="13.0.3" />
<PackageReference Include="xunit" Version="2.9.3" />
</ItemGroup>
<ItemGroup>