Skip to content

Commit

Permalink
Merge pull request #1603 from nunit/issue-1601
Browse files Browse the repository at this point in the history
Drop agents for .NET 7.0 and .NET Core 3.1
  • Loading branch information
CharliePoole authored Jan 18, 2025
2 parents 0d2aea3 + 1c4d532 commit 04be095
Show file tree
Hide file tree
Showing 7 changed files with 4 additions and 71 deletions.
2 changes: 2 additions & 0 deletions .github/workflows/NUnitConsoleAndEngine.CI.yml
Original file line number Diff line number Diff line change
Expand Up @@ -31,12 +31,14 @@ jobs:
with:
fetch-depth: 0

# Ensure all required runtimes are available
- name: 🛠️ Setup .NET
uses: actions/setup-dotnet@v4
with:
dotnet-version: |
3.1.x
6.0.x
7.0.x
8.0.100
- name: 🔧 Install dotnet tools
Expand Down
12 changes: 0 additions & 12 deletions build.cake
Original file line number Diff line number Diff line change
Expand Up @@ -63,17 +63,13 @@ BuildSettings.Packages.AddRange(new PackageDefinition[] {
HasFiles("LICENSE.txt", "NOTICES.txt"),
HasDirectory("tools").WithFiles("nunit3-console.exe", "nunit3-console.exe.config").AndFiles(ENGINE_FILES),
HasDirectory("tools/agents/net462").WithFiles(AGENT_FILES),
HasDirectory("tools/agents/netcoreapp3.1").WithFiles(AGENT_FILES_NETCORE),
HasDirectory("tools/agents/net6.0").WithFiles(AGENT_FILES_NETCORE),
HasDirectory("tools/agents/net7.0").WithFiles(AGENT_FILES_NETCORE),
HasDirectory("tools/agents/net8.0").WithFiles(AGENT_FILES_NETCORE)
},
symbols: new PackageCheck[] {
HasDirectory("tools").WithFiles(ENGINE_PDB_FILES).AndFile("nunit3-console.pdb"),
HasDirectory("tools/agents/net462").WithFiles(AGENT_PDB_FILES),
HasDirectory("tools/agents/netcoreapp3.1").WithFiles(AGENT_PDB_FILES_NETCORE),
HasDirectory("tools/agents/net6.0").WithFiles(AGENT_PDB_FILES_NETCORE),
HasDirectory("tools/agents/net7.0").WithFiles(AGENT_PDB_FILES_NETCORE),
HasDirectory("tools/agents/net8.0").WithFiles(AGENT_PDB_FILES_NETCORE)
},
testRunner: new ConsoleRunnerSelfTester(BuildSettings.NuGetTestDirectory
Expand Down Expand Up @@ -105,9 +101,7 @@ BuildSettings.Packages.AddRange(new PackageDefinition[] {
checks: new PackageCheck[] {
HasDirectory("tools").WithFiles("LICENSE.txt", "NOTICES.txt", "VERIFICATION.txt", "nunit3-console.exe", "nunit3-console.exe.config").AndFiles(ENGINE_FILES),
HasDirectory("tools/agents/net462").WithFiles(AGENT_FILES),
HasDirectory("tools/agents/netcoreapp3.1").WithFiles(AGENT_FILES_NETCORE),
HasDirectory("tools/agents/net6.0").WithFiles(AGENT_FILES_NETCORE),
HasDirectory("tools/agents/net7.0").WithFiles(AGENT_FILES_NETCORE),
HasDirectory("tools/agents/net8.0").WithFiles(AGENT_FILES_NETCORE)
},
testRunner: new ConsoleRunnerSelfTester(BuildSettings.ChocolateyTestDirectory
Expand All @@ -126,14 +120,8 @@ BuildSettings.Packages.AddRange(new PackageDefinition[] {
HasDirectory("NUnit.Extension.NUnitV2ResultWriter.3.8.0"),
HasDirectory("NUnit.Extension.TeamCityEventListener.1.0.7"),
HasDirectory("NUnit.Extension.VSProjectLoader.3.9.0"),
//HasDirectory("bin/net462/addins").WithFiles(
// "nunit.core.dll", "nunit.core.interfaces.dll", "nunit.engine.api.dll",
// "nunit.v2.driver.dll", "nunit-project-loader.dll", "nunit-v2-result-writer.dll",
// "teamcity-event-listener.dll", "vs-project-loader.dll"),
HasDirectory("bin/netcoreapp3.1").WithFiles(ENGINE_CORE_FILES).AndFiles(ENGINE_CORE_PDB_FILES),
HasDirectory("bin/agents/net462").WithFiles(AGENT_FILES).AndFiles(AGENT_PDB_FILES),
HasDirectory("bin/agents/net6.0").WithFiles(AGENT_FILES_NETCORE).AndFiles(AGENT_PDB_FILES_NETCORE),
HasDirectory("bin/agents/net7.0").WithFiles(AGENT_FILES_NETCORE).AndFiles(AGENT_PDB_FILES_NETCORE),
HasDirectory("bin/agents/net8.0").WithFiles(AGENT_FILES_NETCORE).AndFiles(AGENT_PDB_FILES_NETCORE),
},
testRunner: new ConsoleRunnerSelfTester(BuildSettings.ZipTestDirectory
Expand Down
20 changes: 0 additions & 20 deletions choco/nunit-console-runner.nuspec
Original file line number Diff line number Diff line change
Expand Up @@ -49,16 +49,6 @@
<file src = "nunit-agent.exe.ignore" target="tools/agents/net462" />
<file src = "nunit-agent-x86.exe.ignore" target="tools/agents/net462" />

<file src = "$BIN_DIR$agents/netcoreapp3.1/nunit-agent.dll" target="tools/agents/netcoreapp3.1" />
<file src = "$BIN_DIR$agents/netcoreapp3.1/nunit-agent.dll.config" target="tools/agents/netcoreapp3.1" />
<file src = "$BIN_DIR$agents/netcoreapp3.1/nunit-agent.deps.json" target="tools/agents/netcoreapp3.1" />
<file src = "$BIN_DIR$agents/netcoreapp3.1/nunit-agent.runtimeconfig.json" target="tools/agents/netcoreapp3.1" />
<file src = "$BIN_DIR$agents/netcoreapp3.1/nunit.engine.api.dll" target="tools/agents/netcoreapp3.1" />
<file src = "$BIN_DIR$agents/netcoreapp3.1/nunit.engine.api.xml" target="tools/agents/netcoreapp3.1" />
<file src = "$BIN_DIR$agents/netcoreapp3.1/nunit.engine.core.dll" target="tools/agents/netcoreapp3.1" />
<file src = "$BIN_DIR$agents/netcoreapp3.1/testcentric.engine.metadata.dll" target="tools/agents/netcoreapp3.1" />
<file src = "$BIN_DIR$agents/netcoreapp3.1/Microsoft.Extensions.DependencyModel.dll" target="tools/agents/netcoreapp3.1" />

<file src = "$BIN_DIR$agents/net6.0/nunit-agent.dll" target="tools/agents/net6.0" />
<file src = "$BIN_DIR$agents/net6.0/nunit-agent.dll.config" target="tools/agents/net6.0" />
<file src = "$BIN_DIR$agents/net6.0/nunit-agent.deps.json" target="tools/agents/net6.0" />
Expand All @@ -69,16 +59,6 @@
<file src = "$BIN_DIR$agents/net6.0/testcentric.engine.metadata.dll" target="tools/agents/net6.0" />
<file src = "$BIN_DIR$agents/net6.0/Microsoft.Extensions.DependencyModel.dll" target="tools/agents/net6.0" />

<file src = "$BIN_DIR$agents/net7.0/nunit-agent.dll" target="tools/agents/net7.0" />
<file src = "$BIN_DIR$agents/net7.0/nunit-agent.dll.config" target="tools/agents/net7.0" />
<file src = "$BIN_DIR$agents/net7.0/nunit-agent.deps.json" target="tools/agents/net7.0" />
<file src = "$BIN_DIR$agents/net7.0/nunit-agent.runtimeconfig.json" target="tools/agents/net7.0" />
<file src = "$BIN_DIR$agents/net7.0/nunit.engine.api.dll" target="tools/agents/net7.0" />
<file src = "$BIN_DIR$agents/net7.0/nunit.engine.api.xml" target="tools/agents/net7.0" />
<file src = "$BIN_DIR$agents/net7.0/nunit.engine.core.dll" target="tools/agents/net7.0" />
<file src = "$BIN_DIR$agents/net7.0/testcentric.engine.metadata.dll" target="tools/agents/net7.0" />
<file src = "$BIN_DIR$agents/net7.0/Microsoft.Extensions.DependencyModel.dll" target="tools/agents/net7.0" />

<file src = "$BIN_DIR$agents/net8.0/nunit-agent.dll" target="tools/agents/net8.0" />
<file src = "$BIN_DIR$agents/net8.0/nunit-agent.dll.config" target="tools/agents/net8.0" />
<file src = "$BIN_DIR$agents/net8.0/nunit-agent.deps.json" target="tools/agents/net8.0" />
Expand Down
11 changes: 0 additions & 11 deletions nuget/engine/nunit.engine.nuspec
Original file line number Diff line number Diff line change
Expand Up @@ -55,17 +55,6 @@
<file src="agents/net462/nunit.engine.api.pdb" target="contentFiles/any/agents/net462" />
<file src="agents/net462/testcentric.engine.metadata.dll" target="contentFiles/any/agents/net462" />

<file src="agents/netcoreapp3.1/nunit-agent.dll" target="contentFiles/any/agents/netcoreapp3.1" />
<file src="agents/netcoreapp3.1/nunit-agent.pdb" target="contentFiles/any/agents/netcoreapp3.1" />
<file src="agents/netcoreapp3.1/nunit-agent.dll.config" target="contentFiles/any/agents/netcoreapp3.1" />
<file src="agents/netcoreapp3.1/nunit-agent.deps.json" target="contentFiles/any/agents/netcoreapp3.1" />
<file src="agents/netcoreapp3.1/nunit-agent.runtimeconfig.json" target="contentFiles/any/agents/netcoreapp3.1" />
<file src="agents/netcoreapp3.1/nunit.engine.core.dll" target="contentFiles/any/agents/netcoreapp3.1" />
<file src="agents/netcoreapp3.1/nunit.engine.core.pdb" target="contentFiles/any/agents/netcoreapp3.1" />
<file src="agents/netcoreapp3.1/nunit.engine.api.dll" target="contentFiles/any/agents/netcoreapp3.1" />
<file src="agents/netcoreapp3.1/nunit.engine.api.pdb" target="contentFiles/any/agents/netcoreapp3.1" />
<file src="agents/netcoreapp3.1/testcentric.engine.metadata.dll" target="contentFiles/any/agents/netcoreapp3.1" />

<file src="net8.0/nunit.engine.dll" target="lib/net8.0" />
<file src="net8.0/nunit.engine.pdb" target="lib/net8.0" />
<file src="net8.0/nunit.engine.core.dll" target="lib/net8.0" />
Expand Down
26 changes: 0 additions & 26 deletions nuget/runners/nunit.console-runner.nuspec
Original file line number Diff line number Diff line change
Expand Up @@ -40,19 +40,6 @@
<file src="agents/net462/nunit.engine.core.pdb" target="tools/agents/net462" />
<file src="agents/net462/testcentric.engine.metadata.dll" target="tools/agents/net462" />

<file src="agents/netcoreapp3.1/nunit-agent.dll" target="tools/agents/netcoreapp3.1" />
<file src="agents/netcoreapp3.1/nunit-agent.pdb" target="tools/agents/netcoreapp3.1" />
<file src="agents/netcoreapp3.1/nunit-agent.dll.config" target="tools/agents/netcoreapp3.1" />
<file src="agents/netcoreapp3.1/nunit-agent.deps.json" target="tools/agents/netcoreapp3.1" />
<file src="agents/netcoreapp3.1/nunit-agent.runtimeconfig.json" target="tools/agents/netcoreapp3.1" />
<file src="agents/netcoreapp3.1/nunit.engine.api.dll" target="tools/agents/netcoreapp3.1" />
<file src="agents/netcoreapp3.1/nunit.engine.api.pdb" target="tools/agents/netcoreapp3.1" />
<file src="agents/netcoreapp3.1/nunit.engine.api.xml" target="tools/agents/netcoreapp3.1" />
<file src="agents/netcoreapp3.1/nunit.engine.core.dll" target="tools/agents/netcoreapp3.1" />
<file src="agents/netcoreapp3.1/nunit.engine.core.pdb" target="tools/agents/netcoreapp3.1" />
<file src="agents/netcoreapp3.1/testcentric.engine.metadata.dll" target="tools/agents/netcoreapp3.1" />
<file src="agents/netcoreapp3.1/Microsoft.Extensions.DependencyModel.dll" target="tools/agents/netcoreapp3.1" />

<file src="agents/net6.0/nunit-agent.dll" target="tools/agents/net6.0" />
<file src="agents/net6.0/nunit-agent.pdb" target="tools/agents/net6.0" />
<file src="agents/net6.0/nunit-agent.dll.config" target="tools/agents/net6.0" />
Expand All @@ -66,19 +53,6 @@
<file src="agents/net6.0/testcentric.engine.metadata.dll" target="tools/agents/net6.0" />
<file src="agents/net6.0/Microsoft.Extensions.DependencyModel.dll" target="tools/agents/net6.0" />

<file src="agents/net7.0/nunit-agent.dll" target="tools/agents/net7.0" />
<file src="agents/net7.0/nunit-agent.pdb" target="tools/agents/net7.0" />
<file src="agents/net7.0/nunit-agent.dll.config" target="tools/agents/net7.0" />
<file src="agents/net7.0/nunit-agent.deps.json" target="tools/agents/net7.0" />
<file src="agents/net7.0/nunit-agent.runtimeconfig.json" target="tools/agents/net7.0" />
<file src="agents/net7.0/nunit.engine.api.dll" target="tools/agents/net7.0" />
<file src="agents/net7.0/nunit.engine.api.pdb" target="tools/agents/net7.0" />
<file src="agents/net7.0/nunit.engine.api.xml" target="tools/agents/net7.0" />
<file src="agents/net7.0/nunit.engine.core.dll" target="tools/agents/net7.0" />
<file src="agents/net7.0/nunit.engine.core.pdb" target="tools/agents/net7.0" />
<file src="agents/net7.0/testcentric.engine.metadata.dll" target="tools/agents/net7.0" />
<file src="agents/net7.0/Microsoft.Extensions.DependencyModel.dll" target="tools/agents/net7.0" />

<file src="agents/net8.0/nunit-agent.dll" target="tools/agents/net8.0" />
<file src="agents/net8.0/nunit-agent.pdb" target="tools/agents/net8.0" />
<file src="agents/net8.0/nunit-agent.dll.config" target="tools/agents/net8.0" />
Expand Down
2 changes: 1 addition & 1 deletion src/NUnitEngine/nunit-agent/nunit-agent.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
<PropertyGroup>
<OutputType>Exe</OutputType>
<RootNamespace>nunit.agent</RootNamespace>
<TargetFrameworks>net462;netcoreapp3.1;net6.0;net7.0;net8.0</TargetFrameworks>
<TargetFrameworks>net462;net6.0;net8.0</TargetFrameworks>
<ApplicationManifest>app.manifest</ApplicationManifest>
<ApplicationIcon>..\..\..\nunit.ico</ApplicationIcon>
<GenerateSupportedRuntime>false</GenerateSupportedRuntime>
Expand Down
2 changes: 1 addition & 1 deletion src/NUnitEngine/nunit.engine/Services/AgentProcess.cs
Original file line number Diff line number Diff line change
Expand Up @@ -127,7 +127,7 @@ public static string GetTestAgentExePath(RuntimeFramework targetRuntime, bool re
agentExtension = ".exe";
break;
case RuntimeType.NetCore:
runtimeDir = major >= 8 ? "net8.0" : major == 7 ? "net7.0" : major == 6 ? "net6.0" : "netcoreapp3.1";
runtimeDir = major >= 7 ? "net8.0" : "net6.0";
agentName = "nunit-agent";
agentExtension = ".dll";
break;
Expand Down

0 comments on commit 04be095

Please sign in to comment.