Questions tagged [code-coverage]
"Code coverage" (synonym: test coverage) is a measure of the amount of application source code that has been exercised, usually by some testing regime, often by unit testing.
code-coverage
5,386
questions
1
vote
0
answers
14
views
Partial line coverage report with dotnet-coverage
I am working on a C# project and would like to find out which lines are "to cover" with unit tests.
I run the following commands to execute the tests and upload them to sonarqube
dotnet ...
0
votes
0
answers
20
views
Why is SonarQube ignoring coverage data by gcovr from C++ files?
I have a project that is structured like this:
- 3rdParty_Lib1
- 3rdParty_Lib2
- Project_Root
--- apps/
--- include/
------ project_headers/
------ boost_headers/
--- src/
------- module1/
------- ...
0
votes
2
answers
44
views
Why does Fine Code Coverage tell me the portion of tests being run instead of portion of source code being tested?
I am new to unit testing C# in Visual Studio. I want to get the coverage report but I don't have Visual Studio Enterprise so I installed Fine Code Coverage. What I don't understand is it seems like ...
-1
votes
0
answers
11
views
.NET Code coverage SonarCloud github actions yml file
build.yml
`on:
push:
branches: [ "main" ]
pull_request:
branches: [ "main" ]
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Setup .NET
uses: ...
0
votes
0
answers
12
views
Get code coverage report path from SonarQube
We have a giant monolith application. We are using SonarQube for static code coverage. We have an internal requirement to showcase code coverage as per feature level.
We have created a program which ...
2
votes
1
answer
53
views
Generate code coverage for a single test suite
I wish to determine which files are covered by each of my test suites separately. I am using PHPUnit 10.5 with Xdebug for code coverage on my PHP 8.1 project.
Here is what my phpunit.xml configuration ...
-2
votes
0
answers
41
views
Is it possible to have 100% statement coverage but less than 100% branch coverage?
I think it's impossible, because you would need to follow every branch to cover every statement, but I'm entirely not certain..
0
votes
1
answer
64
views
"Code Coverage Results" Missing in Visual Studio
I'm really new to testing, just starting out. I understood there should be a tab "Code Coverage Results" which can be opened from the Test tab, or by right-clicking on a test, but it doesn't ...
0
votes
1
answer
32
views
System Verilog: Biitwise coverage for multibit signal
I'm beginner in System Verilog. I want to implement a coverage such that a user will send a signal - lets call it input_signal[Width-1 :0] Where width is variable. I want to have bitwise toggle ...
1
vote
0
answers
33
views
Code coverage for Attributes with dotCover and C#
We use dotCover (by Jetbrains). We have some custom attributes on properties of models and dotCover shows they are not covered by tests. I tried a number of ways to make tests for them but dotCover ...
0
votes
1
answer
67
views
How to ignore lines of code from coverage in vitest?
I have my unit tests setup with vitest and I am looking for a way to ignore specific lines of code from vitest coverage.
Looking for something similar to /* istanbul ignore next */.
Is there something ...
0
votes
0
answers
51
views
How to address the Compose UI negative impacts on the Code Coverage, even after writing tests for it?
I recently migrated my Android pet project from View to Compose UI and at the begining I was excited about all the @Compose and @Preview functions but righ away noticed a segnificant drop in the repo'...
-1
votes
0
answers
22
views
Facing issue while running Evosuite tutorial stack as port and java net exception
I am new to evosuite,facing issues with the sample class provided on official site.When i am running the command from CMD by following the complete step mentioned in [https://www.evosuite.org/...
0
votes
0
answers
33
views
How to fix "module was not instrumented." Reason:"path_is_excluded" error in Microsoft.CodeCoverage.Console tool?
I'm receiving the following problem while trying to instrument my dll with Microsoft.CodeCoverage.Console tool. module was not instrumented. Reason: path_is_excluded."
I'm using Microsoft....
1
vote
0
answers
26
views
gitlab-ce does not show test coverage on the project badged, always 'unkown'
I'm trying to make the coverage badged work on gitlab-ce, but no success so far.
My badge still unknown:
The badged configuration is:
I tried with both job-related URL and without specifying the job....