Skip to content
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

Have bazel coverage output Cobertura XML #17314

Open
noel-yap opened this issue Jan 25, 2023 · 9 comments
Open

Have bazel coverage output Cobertura XML #17314

noel-yap opened this issue Jan 25, 2023 · 9 comments
Labels
coverage P2 We'll consider working on this in future. (Assignee optional) team-Rules-Server Issues for serverside rules included with Bazel type: feature request

Comments

@noel-yap
Copy link

noel-yap commented Jan 25, 2023

Description of the feature request:

#1118 and #5246 mention having bazel coverage output Cobertura XML. What's the status of this?

What underlying problem are you trying to solve with this feature?

I'd like to use bazel coverage with https://bazel.build/configure/coverage.

Which operating system are you running Bazel on?

Linux, Mac

What is the output of bazel info release?

release 5.3.0

If bazel info release returns development version or (@non-git), tell us how you built Bazel.

No response

What's the output of git remote get-url origin; git rev-parse master; git rev-parse HEAD ?

Not applicable.

Have you found anything relevant by searching the web?

No

Any other information, logs, or outputs that you want to share?

Not applicable

@sgowroji
Copy link
Member

Hello @noel-yap, Could you please elaborate your query with complete details. Thanks!

@noel-yap
Copy link
Author

noel-yap commented Jan 25, 2023

My query is about the status of the work to have bazel coverage output Cobertura XML. I've updated the query and provided answers to the other questions. Any other details I can provide?

@sgowroji sgowroji added type: feature request team-Rules-Server Issues for serverside rules included with Bazel untriaged and removed more data needed labels Jan 29, 2023
@c-mita
Copy link
Member

c-mita commented Feb 14, 2023

There are currently no plans to add XML output support to Bazel; it may get some consideration in the future, but it would likely be just plugging in the genhtml step we advise in the documentation.

@c-mita c-mita closed this as not planned Won't fix, can't repro, duplicate, stale Feb 14, 2023
@imcdo
Copy link

imcdo commented May 15, 2023

+1 this request

@frbender
Copy link

This would be a huge help for python developers! :)

The use case is to use Bazel with code quality tools such as Sonarcloud/SonarQube. Unfortunately, tools like Sonarcloud expect XML coverage reports for languages such as Python, Java and Scala as for those languages, it's the more common output option. Of course, for C and similar languages this might be different.

(Just for reference, here's what I am referring to: https://docs.sonarcloud.io/enriching/test-coverage/test-coverage-parameters/)

@KarimH22
Copy link

KarimH22 commented Aug 2, 2023

Hello
+1 to get xml report and not .dat
some report generator tools prefer xml
thanks

@c-mita
Copy link
Member

c-mita commented Aug 2, 2023

I'm re-opening this because of the discussion I started here: #19144

@c-mita c-mita reopened this Aug 2, 2023
@c-mita c-mita added P2 We'll consider working on this in future. (Assignee optional) and removed untriaged labels Aug 8, 2023
@xiaozhi747
Copy link

Is there any new progress on this issue? @c-mita

@c-mita
Copy link
Member

c-mita commented May 7, 2024

No.

I don't think Bazel will ever "operate" on or with XML files (it's not a good format for cross-language operations, merging across multiple runs, etc).

It's possible that we may one day bundle an "lcov to XML" converter, but it's a low priority.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
coverage P2 We'll consider working on this in future. (Assignee optional) team-Rules-Server Issues for serverside rules included with Bazel type: feature request
Projects
None yet
Development

No branches or pull requests

7 participants