cake-build / cake-build/cake

Code coverage result with multiple test project

Open
#1,629 2 comments 0 reactions 0 assignees View on GitHub
Dominant language
C#
Stars
4.2k
Forks
778
Avg merge
1h 15m
Merged PRs (30d)
19

Description

I have the one source project and this source project contains the 2 test project. In both test projects contains some list of the test cases. Please find the structure of my projects below,

Core
--------Src
--------Test
------------Test1
------------Test2

In Test1 and Test2 are the test projects which contains the Nunit test cases for the Src project. Now how I can get the code coverage result based on the above two test projects. For example, if the code coverage for Test1 is 30 and Test is 40 percent, when independently run the above cases. If i added the above two values it gives 70 percent of code coverage. But this is wrong, because for some API's both two test cases may contains the NUnit test cases.

So I need to calculate the code coverage percentage based on the two test projects. So can you please suggest how can I calculate the code coverage percentage of the source project based on the above two test projects?

Contributor guide

Open the contributing guide

Research direction

The issue mentions one source project with NUnit test projects Test1 and Test2, but no repository files, entry points, or existing tests. Start by locating the coverage workflow in the Cake repository and determine whether this request belongs in the build tooling; done would require an agreed approach for combined coverage that handles overlapping APIs without simply adding percentages.

Written by the indexing model from the issue text.

Assessment

Tech stack
csharp
Domain
testing-qa
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
15/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.