You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Apr 6, 2026. It is now read-only.
The VSTS task doesn't fail when there are invalid unit tests.
When running the command coverage run -m xmlrunner discover -s . -p test_*.py manually, coverage outputs the failed xml, etc. but the task doesn't output anything to console on this step and appears as if everything is fine while it's not. I see in the code that it's set to silent so I'm assuming this is intended behavior? Can't there be an option passed in to allow failing the task whenever tests are not passing. I don't want the build process to even continue when there are failures.
coverage run -m xmlrunner discover -s . -p test_*.py output
Traceback (most recent call last):
File "C:\agent_work\6\s\src\tests\misc\test_fail.py", line 6, in test_test
self.assertTrue(False)
AssertionError: False is not true
Runner Code
// Execute the unit tests
let unittestTool = tl.tool(coverageToolPath).arg(['run', '-m', 'xmlrunner', 'discover', '-s', '.', '-p', testFilePattern]);
unittestTool.execSync(toolRunOptions);