Skip to content

How to ask mstest to stop once it finds a discovery failure like UTA007 #499

@sadjadbp

Description

@sadjadbp

Description

We had bunch of test that their signature was async, but return types where void.
So we were receiving errors like this Azure DevOps test step

2018-10-11T06:06:39.0663002Z [MSTest][Discovery][x.dll] UTA007: Method Test1 defined in class Class1 does not have correct signature. Test method marked with the [TestMethod] attribute must be non-static, public, return-type as void and should not take any parameter. Example: public void Test.Class1.Test(). Additionally, if you are using async-await in test method then return-type must be Task. Example: public async Task Test.Class1.Test2()

The question here is what parameter we could pass to vstest.console.exe to break/stop on these errors. We basically didn't know these tests was not running for a long time

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type
No fields configured for issues without a type.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions