I am trying to implement a Gated Check-In process in Azure DevOps (VSTS) based on the success of the unit tests. However, I am consistently getting this warning/error that assemblies are not found.
##[warning]No test assemblies found matching the pattern: **\*Test*.dll,!**\*TestAdapter.dll,!**\obj\**.
##[debug]Processed: ##vso[task.issue type=warning;]No test assemblies found matching the pattern: **\*Test*.dll,!**\*TestAdapter.dll,!**\obj\**.
======================================================
All my unit tests run successfully in Visual Studio 2017 in Test Explorer locally.
The Azure DevOps documentation seems straightforward but it does not work when I follow it.
I am using a Hosted VS2017 Agent. The CI Build itself succeeds upon check in to TFS source control.
Log
screen 1
screen 2 screen 3 screen 4 screen 5 [screen 6]
The "old" .NET had the files located in the Release folder (which is described by the BuildConfiguration
variable).
.NET Core builds contain an extra folder:
YourNamespaceHere.UnitTests > bin > Release > netcoreapp2.1 > dll's
When you add an extra wildcard, the build will find the unittest dll's.
**\$(BuildConfiguration)\*\*unittests.dll
I have renamed the *Tests*
part to *unittests.dll
as my project also contains integrationtests.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With