diff --git a/GitVersion.yml b/GitVersion.yml
index c02e85371..19dfb1105 100644
--- a/GitVersion.yml
+++ b/GitVersion.yml
@@ -1,4 +1,4 @@
-next-version: 3.17.1
+next-version: 3.18.0
mode: ContinuousDelivery
legacy-semver-padding: 5
build-metadata-padding: 5
diff --git a/NUnitConsole.sln b/NUnitConsole.sln
index 760d8c675..4b047daea 100644
--- a/NUnitConsole.sln
+++ b/NUnitConsole.sln
@@ -69,11 +69,11 @@ EndProject
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "runners", "runners", "{F3E87D0F-6F06-4C0B-AE06-42C0834C3C6E}"
ProjectSection(SolutionItems) = preProject
nuget\runners\DotnetToolSettings.xml = nuget\runners\DotnetToolSettings.xml
- nuget\runners\nunit.agent.addins = nuget\runners\nunit.agent.addins
nuget\runners\nunit.console-runner-with-extensions.nuspec = nuget\runners\nunit.console-runner-with-extensions.nuspec
nuget\runners\nunit.console-runner.netcore.nuspec = nuget\runners\nunit.console-runner.netcore.nuspec
nuget\runners\nunit.console-runner.nuspec = nuget\runners\nunit.console-runner.nuspec
nuget\runners\nunit.console.nuget.addins = nuget\runners\nunit.console.nuget.addins
+ nuget\runners\nunit.console.nuget.agent.addins = nuget\runners\nunit.console.nuget.agent.addins
EndProjectSection
EndProject
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "mock-assembly", "src\NUnitEngine\mock-assembly\mock-assembly.csproj", "{D2C80E4B-1117-4F02-AB02-E453BDA0C58E}"
@@ -85,9 +85,9 @@ Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "choco", "choco", "{4FDF7BFA
choco\nunit-agent-x86.exe.ignore = choco\nunit-agent-x86.exe.ignore
choco\nunit-agent.exe.ignore = choco\nunit-agent.exe.ignore
choco\nunit-console-runner.nuspec = choco\nunit-console-runner.nuspec
- choco\nunit.agent.addins = choco\nunit.agent.addins
- choco\nunit.choco.addins = choco\nunit.choco.addins
choco\VERIFICATION.txt = choco\VERIFICATION.txt
+ choco\nunit.console.choco.addins = choco\nunit.console.choco.addins
+ choco\nunit.console.choco.agent.addins = choco\nunit.console.choco.agent.addins
EndProjectSection
EndProject
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "deprecated", "deprecated", "{9A7C8370-ED1F-486F-A8F5-C5BF4221464E}"
diff --git a/cake/package-definitions.cake b/cake/package-definitions.cake
index e492a86b8..b38bdc7a0 100644
--- a/cake/package-definitions.cake
+++ b/cake/package-definitions.cake
@@ -31,7 +31,8 @@ public void InitializePackageDefinitions(ICakeContext context)
Net70Test,
Net80Test,
Net50PlusNet60Test,
- Net40PlusNet60Test
+ Net40PlusNet60Test,
+ NUnitProjectTest
};
// Tests run for the NETCORE runner package
@@ -79,13 +80,13 @@ public void InitializePackageDefinitions(ICakeContext context)
checks: new PackageCheck[] {
HasFiles("LICENSE.txt", "NOTICES.txt"),
HasDirectory("tools").WithFiles(CONSOLE_FILES).AndFiles(ENGINE_FILES).AndFile("nunit.console.nuget.addins"),
- HasDirectory("tools/agents/net20").WithFiles(AGENT_FILES).AndFile("nunit.agent.addins"),
- HasDirectory("tools/agents/net40").WithFiles(AGENT_FILES).AndFile("nunit.agent.addins"),
- HasDirectory("tools/agents/netcoreapp3.1").WithFiles(AGENT_FILES_NETCORE).AndFile("nunit.agent.addins"),
- HasDirectory("tools/agents/net5.0").WithFiles(AGENT_FILES_NETCORE).AndFile("nunit.agent.addins"),
- HasDirectory("tools/agents/net6.0").WithFiles(AGENT_FILES_NETCORE).AndFile("nunit.agent.addins"),
- HasDirectory("tools/agents/net7.0").WithFiles(AGENT_FILES_NETCORE).AndFile("nunit.agent.addins"),
- HasDirectory("tools/agents/net8.0").WithFiles(AGENT_FILES_NETCORE).AndFile("nunit.agent.addins")
+ HasDirectory("tools/agents/net20").WithFiles(AGENT_FILES).AndFile("nunit.console.nuget.agent.addins"),
+ HasDirectory("tools/agents/net40").WithFiles(AGENT_FILES).AndFile("nunit.console.nuget.agent.addins"),
+ HasDirectory("tools/agents/netcoreapp3.1").WithFiles(AGENT_FILES_NETCORE).AndFile("nunit.console.nuget.agent.addins"),
+ HasDirectory("tools/agents/net5.0").WithFiles(AGENT_FILES_NETCORE).AndFile("nunit.console.nuget.agent.addins"),
+ HasDirectory("tools/agents/net6.0").WithFiles(AGENT_FILES_NETCORE).AndFile("nunit.console.nuget.agent.addins"),
+ HasDirectory("tools/agents/net7.0").WithFiles(AGENT_FILES_NETCORE).AndFile("nunit.console.nuget.agent.addins"),
+ HasDirectory("tools/agents/net8.0").WithFiles(AGENT_FILES_NETCORE).AndFile("nunit.console.nuget.agent.addins")
},
symbols: new PackageCheck[] {
HasDirectory("tools").WithFiles(ENGINE_PDB_FILES).AndFile("nunit3-console.pdb"),
@@ -136,14 +137,14 @@ public void InitializePackageDefinitions(ICakeContext context)
version: ProductVersion,
source: CHOCO_DIR + "nunit-console-runner.nuspec",
checks: new PackageCheck[] {
- HasDirectory("tools").WithFiles("LICENSE.txt", "NOTICES.txt", "VERIFICATION.txt").AndFiles(CONSOLE_FILES).AndFiles(ENGINE_FILES).AndFile("nunit.choco.addins"),
- HasDirectory("tools/agents/net20").WithFiles(AGENT_FILES).AndFile("nunit.agent.addins"),
- HasDirectory("tools/agents/net40").WithFiles(AGENT_FILES).AndFile("nunit.agent.addins"),
- HasDirectory("tools/agents/netcoreapp3.1").WithFiles(AGENT_FILES_NETCORE).AndFile("nunit.agent.addins"),
- HasDirectory("tools/agents/net5.0").WithFiles(AGENT_FILES_NETCORE).AndFile("nunit.agent.addins"),
- HasDirectory("tools/agents/net6.0").WithFiles(AGENT_FILES_NETCORE).AndFile("nunit.agent.addins"),
- HasDirectory("tools/agents/net7.0").WithFiles(AGENT_FILES_NETCORE).AndFile("nunit.agent.addins"),
- HasDirectory("tools/agents/net8.0").WithFiles(AGENT_FILES_NETCORE).AndFile("nunit.agent.addins")
+ HasDirectory("tools").WithFiles("LICENSE.txt", "NOTICES.txt", "VERIFICATION.txt").AndFiles(CONSOLE_FILES).AndFiles(ENGINE_FILES).AndFile("nunit.console.choco.addins"),
+ HasDirectory("tools/agents/net20").WithFiles(AGENT_FILES).AndFile("nunit.console.choco.agent.addins"),
+ HasDirectory("tools/agents/net40").WithFiles(AGENT_FILES).AndFile("nunit.console.choco.agent.addins"),
+ HasDirectory("tools/agents/netcoreapp3.1").WithFiles(AGENT_FILES_NETCORE).AndFile("nunit.console.choco.agent.addins"),
+ HasDirectory("tools/agents/net5.0").WithFiles(AGENT_FILES_NETCORE).AndFile("nunit.console.choco.agent.addins"),
+ HasDirectory("tools/agents/net6.0").WithFiles(AGENT_FILES_NETCORE).AndFile("nunit.console.choco.agent.addins"),
+ HasDirectory("tools/agents/net7.0").WithFiles(AGENT_FILES_NETCORE).AndFile("nunit.console.choco.agent.addins"),
+ HasDirectory("tools/agents/net8.0").WithFiles(AGENT_FILES_NETCORE).AndFile("nunit.console.choco.agent.addins")
},
executable: "tools/nunit3-console.exe",
tests: StandardRunnerTests),
@@ -159,7 +160,7 @@ public void InitializePackageDefinitions(ICakeContext context)
HasDirectory("Nunit.org/nunit-console/addins").WithFiles("nunit.core.dll", "nunit.core.interfaces.dll", "nunit.v2.driver.dll", "nunit-project-loader.dll", "vs-project-loader.dll", "nunit-v2-result-writer.dll", "teamcity-event-listener.dll")
},
executable: "NUnit.org/nunit-console/nunit3-console.exe",
- tests: StandardRunnerTests.Concat(new[] { NUnitProjectTest })),
+ tests: StandardRunnerTests),
NUnitConsoleZipPackage = new ZipPackage(
context: context,
@@ -181,7 +182,7 @@ public void InitializePackageDefinitions(ICakeContext context)
HasDirectory("bin/agents/net8.0").WithFiles(AGENT_FILES_NETCORE).AndFiles(AGENT_PDB_FILES_NETCORE)
},
executable: "bin/net20/nunit3-console.exe",
- tests: StandardRunnerTests.Concat(new[] { NUnitProjectTest })),
+ tests: StandardRunnerTests),
// NOTE: Packages below this point have no direct tests
diff --git a/cake/package-tester.cake b/cake/package-tester.cake
index a3ee24f4d..f3d2c3142 100644
--- a/cake/package-tester.cake
+++ b/cake/package-tester.cake
@@ -70,9 +70,37 @@ public class PackageTester
{
Console.WriteLine($"Unzipping package to {_installDirectory}");
_context.Unzip(_packageUnderTest, _installDirectory);
+
+ if (_packageType == PackageType.NuGet || _packageType == PackageType.Chocolatey)
+ {
+ foreach (string packageDir in System.IO.Directory.GetDirectories(EXTENSIONS_DIR))
+ {
+ string subdir = _packageType.ToString().ToLower();
+ string packageName = System.IO.Path.GetFileName(packageDir);
+ string targetDir = $"{PACKAGE_TEST_DIR}{subdir}/{packageName}";
+
+ _context.CopyDirectory(packageDir, targetDir);
+
+ if (_packageType == PackageType.Chocolatey)
+ RenamePackageForChocolatey(targetDir);
+ }
+ }
}
}
+ private void RenamePackageForChocolatey(string nugetDir)
+ {
+ string chocoDir = nugetDir
+ .Replace("NUnit.Extension.NUnitProjectLoader", "nunit-extension-nunit-project-loader")
+ .Replace("NUnit.Extension.VSProjectLoader", "nunit-extension-vs-project-loader")
+ .Replace("NUnit.Extension.NUnitV2ResultWriter", "nunit-extension-v2-result-writer")
+ .Replace("NUnit.Extension.NUnitV2Driver", "nunit-extension-nunit-v2-driver")
+ .Replace("NUnit.Extension.TeamCityEventListener", "nunit-extension-teamcity-event-listener");
+
+ if (chocoDir != nugetDir)
+ _context.MoveDirectory(nugetDir, chocoDir);
+ }
+
private void RunPackageTests()
{
var reporter = new ResultReporter(_packageName);
diff --git a/choco/nunit-console-runner.nuspec b/choco/nunit-console-runner.nuspec
index 068f8e2af..f9658c5c9 100644
--- a/choco/nunit-console-runner.nuspec
+++ b/choco/nunit-console-runner.nuspec
@@ -29,7 +29,7 @@
-
+
@@ -49,7 +49,7 @@
-
+
@@ -61,7 +61,7 @@
-
+
@@ -72,7 +72,7 @@
-
+
@@ -83,7 +83,7 @@
-
+
@@ -94,7 +94,7 @@
-
+
@@ -105,7 +105,7 @@
-
+
@@ -116,6 +116,6 @@
-
+
diff --git a/choco/nunit.agent.addins b/choco/nunit.agent.addins
deleted file mode 100644
index 1558d5f75..000000000
--- a/choco/nunit.agent.addins
+++ /dev/null
@@ -1 +0,0 @@
-../../ # refer to the directory containing the engine and runner
diff --git a/choco/nunit.choco.addins b/choco/nunit.console.choco.addins
similarity index 100%
rename from choco/nunit.choco.addins
rename to choco/nunit.console.choco.addins
diff --git a/choco/nunit.console.choco.agent.addins b/choco/nunit.console.choco.agent.addins
new file mode 100644
index 000000000..ddf5d016b
--- /dev/null
+++ b/choco/nunit.console.choco.agent.addins
@@ -0,0 +1,5 @@
+# Extensions built for a single runtime target
+../../../../nunit-extension-*/tools/ # find extensions installed under chocolatey
+
+# Extensions built for multiple targets
+../../../../nunit-extension-*/tools/*/ # find extensions installed under chocolatey
diff --git a/nuget/runners/nunit.agent.addins b/nuget/runners/nunit.agent.addins
deleted file mode 100644
index 1558d5f75..000000000
--- a/nuget/runners/nunit.agent.addins
+++ /dev/null
@@ -1 +0,0 @@
-../../ # refer to the directory containing the engine and runner
diff --git a/nuget/runners/nunit.console-runner.nuspec b/nuget/runners/nunit.console-runner.nuspec
index 290f218f1..45a728c16 100644
--- a/nuget/runners/nunit.console-runner.nuspec
+++ b/nuget/runners/nunit.console-runner.nuspec
@@ -38,7 +38,7 @@
-
+
@@ -52,7 +52,7 @@
-
+
@@ -66,7 +66,7 @@
-
+
@@ -80,7 +80,7 @@
-
+
@@ -94,7 +94,7 @@
-
+
@@ -108,7 +108,7 @@
-
+
@@ -122,7 +122,7 @@
-
+
diff --git a/nuget/runners/nunit.console.nuget.agent.addins b/nuget/runners/nunit.console.nuget.agent.addins
new file mode 100644
index 000000000..ddfcb54ab
--- /dev/null
+++ b/nuget/runners/nunit.console.nuget.agent.addins
@@ -0,0 +1,11 @@
+# Extensions built for a single runtime target
+../../../../NUnit.Extension.*/**/tools/ # nuget v2 layout
+../../../../../NUnit.Extension.*/**/tools/ # nuget v3 layout
+../../../../nunit.extension.*/**/tools/ # nuget v2 layout
+../../../../../nunit.extension.*/**/tools/ # nuget v3 layout
+
+# Extensions built for multiple targets
+../../../../NUnit.Extension.*/**/tools/*/ # nuget v2 layout
+../../../../../NUnit.Extension.*/**/tools/*/ # nuget v3 layout
+../../../../nunit.extension.*/**/tools/*/ # nuget v2 layout
+../../../../../nunit.extension.*/**/tools/*/ # nuget v3 layout