-
Notifications
You must be signed in to change notification settings - Fork 363
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fixes bullseye conditions to be shown in SQ UI #1237
Fixes bullseye conditions to be shown in SQ UI #1237
Conversation
👍 Thanks for this improvement. Did you also check it for SQ 5.6? We missed this information (https://docs.sonarqube.org/display/DEV/API+Changes):
|
import java.util.Map; | ||
import java.util.Set; | ||
import java.util.Map.Entry; | ||
import java.util.*; | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
squid:S2208 Wildcard imports should not be used
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fixed
try { | ||
if(type == CoverageMeasure.CoverageType.CONDITION) { | ||
newCoverage.lineHits(measure.getLine(), measure.getHits()); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
squid:IndentationCheck Make this line start at column 7
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fixed
The integration tests failed because the coverage values for SQ 5.6 changed (Travis and AppVeyor).
I found a comment in test_create_rules_and_bullseye_import.feature which documents a reduced coverage after SonarQube update.
|
@tomassdepakin thsnks for the fix. In general looks good. Coverage is increased after your fix. It's always hard to say if coverage values are correct or not because every tool is doing/counting it al little bit different. Can you compare the numbers of our integration tests with the values shown in Bullseye please. Are they better/same/worse? |
@tomassdepakin files you have to adapt the values if they are right are: |
553906d
to
504fef7
Compare
@tomassdepakin The integration tests still fail and you have to adapt the values within the scenarios for the Sonarqube 5.6 tests to pass the checks. https://github.com/SonarOpenCommunity/sonar-cxx/blob/master/integration-tests/features/importing_coverage.feature
|
Yep, I want to make more tests on coverage computing, and also with SQ5.6 |
The coverage values for SQ6.2 and newer have now to be adopted as well.
|
@tomassdepakin please rebase |
Refactors CoverageMeasure to not be divided to line and condition type
f7b1001
to
37c9fd3
Compare
@guwirth done |
@Bertk is final version also ok for you? |
@tomassdepakin looks good to me. Thanks for providing this PR. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
👍 Great job. Thanks for fixing the coverage indication in SQ source code UI.
Thank YOU guys for developing this plugin) My pleasure to participate. |
Hi. Fixing bug, when bullseye conditions are not shown in SonarQube UI.
Tested with 6.3
Removing unneeded CoverageType from CoverageMeasure. It successfully contains line hits and conditions simultaneously.
Here comes my paint madskillz:
This change is