MicrosoftPremier / VstsExtensions

Documentation and issue tracking for Microsoft Premier Services Visual Studio Team Services Extensions
MIT License
59 stars 14 forks source link

Build quality check is unable to find the code coverage metric data when it's is a Pull Request #90

Closed davidsekar closed 4 years ago

davidsekar commented 4 years ago

When a build is triggered by a Create Pull request (I.e., for branch policy validation), BQC task is unable to fetch the previous code coverage metric. It shows following in the logs and the build passes.

[WARNING] The baseline build could not be found. All policies based on the previous build will pass.

[warning]The baseline build could not be found. All policies based on the previous build will pass.

Will it be feasible to get the targetRefBranch code coverage dataset and compare it with the PR validation build coverage data? That way it will be sensible and prevent the low code coverage code getting into the parent branch.

ReneSchumacher commented 4 years ago

Hi @davidsekar,

you have to correctly configure the baseline for the task as described at https://github.com/MicrosoftPremier/VstsExtensions/blob/master/BuildQualityChecks/en-US/overview.md#task-parameters and https://github.com/MicrosoftPremier/VstsExtensions/blob/master/BuildQualityChecks/en-US/PullRequests.md. Currently, the task does not automatically pick up code coverage from the PR target branch, even though that is on our backlog.

René

ReneSchumacher commented 4 years ago

Hi again,

since I haven't received any further feedback, I assume that you have been able to solve your issue. Closing this for now. If you need additional assistance, please feel free to add another comment or open a new issue.

Happy building, René