diff --git a/.config/dotnet-tools.json b/.config/dotnet-tools.json index b6cadaf6..678c0add 100644 --- a/.config/dotnet-tools.json +++ b/.config/dotnet-tools.json @@ -3,10 +3,10 @@ "isRoot": true, "tools": { "cake.tool": { - "version": "2.1.0", + "version": "3.2.0", "commands": [ "dotnet-cake" ] } } -} \ No newline at end of file +} diff --git a/.gitignore b/.gitignore index c0dabd86..40dc2c8a 100644 --- a/.gitignore +++ b/.gitignore @@ -34,7 +34,7 @@ tools/ # NUNIT *.VisualState.xml -TestResult.xml +TestResult*.xml # Build Results of an ATL Project [Dd]ebugPS/ @@ -288,4 +288,4 @@ CommentRemover.ConsoleApplication Output/ CommentRemover.Task Output/ # Generated Assembly info -AssemblyInfo.Generated.cs \ No newline at end of file +AssemblyInfo.Generated.cs diff --git a/build.cake b/build.cake index 2e2e7689..03c11e3b 100644 --- a/build.cake +++ b/build.cake @@ -148,18 +148,29 @@ Task("Test") .IsDependentOn("Build") .Does(() => { + Information("Testing against NUnit 3.xx"); DotNetTest(TEST_PROJECT, new DotNetTestSettings { Configuration = configuration, Loggers = new string[] { "trx" }, - VSTestReportPath = "TestResult.xml", + VSTestReportPath = "TestResult-NUnit3.xml", + MSBuildSettings = new DotNetMSBuildSettings().WithProperty("NUnitVersion", "3") + }); + Information("Testing against NUnit 4.xx"); + DotNetTest(TEST_PROJECT, new DotNetTestSettings + { + Configuration = configuration, + Loggers = new string[] { "trx" }, + VSTestReportPath = "TestResult-NUnit4.xml", + MSBuildSettings = new DotNetMSBuildSettings().WithProperty("NUnitVersion", "4") }); }) .Finally(() => { if (AppVeyor.IsRunningOnAppVeyor) { - AppVeyor.UploadTestResults("TestResult.xml", AppVeyorTestResultsType.MSTest); + AppVeyor.UploadTestResults("TestResult-NUnit3.xml", AppVeyorTestResultsType.MSTest); + AppVeyor.UploadTestResults("TestResult-NUnit4.xml", AppVeyorTestResultsType.MSTest); } });