question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Code Coverage Summary in Build

See original GitHub issue

Required Information

Entering this information will route you directly to the right team and expedite traction.

Question, Bug, or Feature?
Type: Bug

Enter Task Name: Visual Studio Test v2

Environment

Pool: OE Public Pool
Agent: Agent-APP-ADOBZ-105
Agent name: 'Agent-APP-ADOBZ-105'
Agent machine name: 'APP-ADOBZ-105'
Current agent version: '2.166.2'
Agent running as: 'localAgt'

Issue Description

I have enabled the Code Coverage in the VS Test task

steps:
- task: VSTest@2
  displayName: 'Run unit tests'
  inputs:
    testAssemblyVer2: |
     **\*unittests*.dll
     !**\obj\**
    testFiltercriteria: '(TestCategory!=LocalOnly)&(TestCategory!=IntegrationTests)'
    runSettingsFile: test/TestRunSettings/local.runsettings
    codeCoverageEnabled: true
    platform: '$(BuildPlatform)'
    configuration: '$(BuildConfiguration)'
    publishRunAttachments: false
    diagnosticsEnabled: True

Once the build completes, I could see an option to download the code coverage report on the Code Coverage Tab of the build - image But the below section is empty. I was wondering if it is possible to have the code coverage data visualized on the build itself in some tabular format ?

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Comments:13 (5 by maintainers)

github_iconTop GitHub Comments

1reaction
anshii03commented, Oct 14, 2020

As of now we will not be able to roll out this new feature.

For better viewing of coverage information you can use -

1.PCC task for coverage information stored in cobertura or jacoco format : https://docs.microsoft.com/en-us/azure/devops/pipelines/tasks/test/publish-code-coverage-results?view=azure-devops

2.Use report generator tool in the pipeline to generate the HTML report (which support good number of coverage formats as input) https://github.com/danielpalme/ReportGenerator

3.Furthermore, to convert .coverage format to .xml fromat : https://github.com/danielpalme/ReportGenerator/wiki/Visual-Studio-Coverage-Tools#vstestconsoleexe

0reactions
github-actions[bot]commented, Oct 13, 2021

This issue is stale because it has been open for 180 days with no activity. Remove the stale label or comment on the issue otherwise this will be closed in 5 days

Read more comments on GitHub >

github_iconTop Results From Across the Web

Code coverage reports - AWS CodeBuild
To create a code coverage report, you run a build project that is configured with at least one code coverage report group in...
Read more >
Review code coverage results - Azure Pipelines
The code coverage artifacts published during the build can be viewed under the Summary tab on the pipeline run summary.
Read more >
What is Code Coverage? | Atlassian
Code coverage is a metric that helps you understand how much of your source is tested. Learn how it is calculated & how...
Read more >
Code Coverage Summary · Actions · GitHub Marketplace
Code Coverage Summary is designed for use with any test framework that outputs coverage in Cobertura XML format including Coverlet, gcovr, simplecov and...
Read more >
Configuring Test Reports and Code Coverage | TeamCity On ...
The code coverage results can be viewed on the Overview tab of Build Results. A detailed report is displayed on the dedicated Code...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found