{"id":15699130,"url":"https://github.com/stefh/coverageconverter","last_synced_at":"2025-05-09T02:20:35.100Z","repository":{"id":43377539,"uuid":"312333768","full_name":"StefH/CoverageConverter","owner":"StefH","description":"Convert .coverage files (binary format) to .coveragexml (xml format) files to support SonarCloud code-coverage when using VSTest@2","archived":false,"fork":false,"pushed_at":"2022-03-04T12:37:31.000Z","size":3366,"stargazers_count":7,"open_issues_count":1,"forks_count":1,"subscribers_count":2,"default_branch":"main","last_synced_at":"2025-05-06T22:25:25.160Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"C#","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/StefH.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2020-11-12T16:29:40.000Z","updated_at":"2024-07-17T12:17:06.000Z","dependencies_parsed_at":"2022-09-15T23:00:38.840Z","dependency_job_id":null,"html_url":"https://github.com/StefH/CoverageConverter","commit_stats":null,"previous_names":[],"tags_count":2,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/StefH%2FCoverageConverter","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/StefH%2FCoverageConverter/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/StefH%2FCoverageConverter/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/StefH%2FCoverageConverter/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/StefH","download_url":"https://codeload.github.com/StefH/CoverageConverter/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":253176620,"owners_count":21866172,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-10-03T19:38:34.532Z","updated_at":"2025-05-09T02:20:35.075Z","avatar_url":"https://github.com/StefH.png","language":"C#","funding_links":[],"categories":[],"sub_categories":[],"readme":"# dotnet-coverageconverter\nConvert `.coverage` (binary format) files to `.coveragexml` (xml format) files to support SonarCloud Code Coverage when using **VSTest@2**.\n\n[![NuGet Badgedotnet-coverageconverter](https://buildstats.info/nuget/dotnet-coverageconverter)](https://www.nuget.org/packages/dotnet-coverageconverter)\n\n## Installation\nInstall locally:\n``` cmd\ndotnet tool install --global dotnet-coverageconverter\n```\n\nor\n\nInstall the tool in your yml pipeline:\n``` yml\n- task: DotNetCoreCLI@2\n  displayName: \"Install tool: dotnet-coverageconverter\"\n  inputs:\n    command: 'custom'\n    custom: 'tool'\n    arguments: 'update --global dotnet-coverageconverter'\n```\n\n## Usage\n\n- Step 1: Define a **VSTest@2** task with `codeCoverageEnabled: true`\n- Step 2: Define a **CmdLine@2** task with the `dotnet-coverageconverter`-tool and provide the CoverageFilesFolder where the `.coverage` files are placed by vstest.console.exe\n\n#### Example YML pipeline tasks\n``` yml\n- task: VSTest@2\n  displayName: 'VsTest'\n  inputs:\n    testSelector: 'testAssemblies'\n    vsTestVersion: 16.0\n    diagnosticsEnabled: true\n    codeCoverageEnabled: true\n    testAssemblyVer2: |\n     **\\*tests.dll\n     !**\\*UITests.dll\n     !**\\*TestAdapter.dll\n     !**\\obj\\**\n\n- task: CmdLine@2\n  displayName: 'Convert .coverage to .coveragexml'\n  inputs:\n    script: 'dotnet-coverageconverter --CoverageFilesFolder \"$(Agent.TempDirectory)\\TestResults\"'\n```\n\n## Commandline Options\n```\n  -f, --CoverageFilesFolder            Required. The folder where the .coverage files are defined.\n\n  -d, --DotCoverageExtension           (Default: .coverage) The extension from the coverage files.\n\n  -a, --AllDirectories                 (Default: true) Includes also sub-folders in the search operation.\n\n  -p, --ProcessAllFiles                (Default: false) Process all .coverage files, if not set, then only folders which are a guid (that's the one VSTest creates) will be processed.\n\n  -o, --Overwrite                      (Default: true) Overwrite the existing .coveragexml files.\n\n  -r, --RemoveOriginalCoverageFiles    Remove the original .coverage files.\n\n  --help                               Display this help screen.\n\n  --version                            Display version information.\n```\n\n### Info\nThis project is inspired by [Visual-Studio-Coverage-Tools](https://github.com/danielpalme/ReportGenerator/wiki/Visual-Studio-Coverage-Tools).\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fstefh%2Fcoverageconverter","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fstefh%2Fcoverageconverter","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fstefh%2Fcoverageconverter/lists"}