Skip to content

Commit

Permalink
Merge pull request #4430 from bdukes/test-in-parellel
Browse files Browse the repository at this point in the history
Run unit tests in parallel
  • Loading branch information
valadas authored Jan 22, 2021
2 parents ac39396 + 2159c85 commit 15c8ec8
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 8 deletions.
13 changes: 6 additions & 7 deletions Build/Cake/unit-tests.cs
Original file line number Diff line number Diff line change
Expand Up @@ -19,18 +19,17 @@ public override void Run(Context context)
testAssemblies -= context.GetFiles(@"**\DotNetNuke.Tests.Utilities.dll");
testAssemblies -= context.GetFiles(@"**\DotNetNuke.Tests.Urls.dll");

foreach (var file in testAssemblies)
{
context.VSTest(file.FullPath,
FixToolPath(context, new VSTestSettings()
context.VSTest(
testAssemblies,
FixToolPath(
context,
new VSTestSettings
{
Logger = $"trx;LogFileName={file.GetFilename()}.xml",
Logger = "trx",
Parallel = true,
EnableCodeCoverage = true,
FrameworkVersion = VSTestFrameworkVersion.NET45,
TestAdapterPath = @"tools\NUnitTestAdapter.2.3.0\build"
}));
}
}

// https://github.com/cake-build/cake/issues/1522
Expand Down
2 changes: 1 addition & 1 deletion azure-pipelines.yml
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@ steps:
displayName: 'Publish Test Results **/TestResults/*.xml'
inputs:
testResultsFormat: VSTest
testResultsFiles: '**/TestResults/*.xml'
testResultsFiles: '**/TestResults/*.trx'
mergeTestResults: true
failTaskOnFailedTests: true
condition: eq(variables['RunTests'], 'True')
Expand Down

0 comments on commit 15c8ec8

Please sign in to comment.