PlatformIO Community

Export PIO unit tests results to sonarqube

Hi.

As some of you might know, I created a full-fledged CI/CD for gitlab and sonarqube. See here.

My tests all run fine, but I’d like SonarQube to be aware of them. So far, code coverage indicator is stuck to 0 :frowning:

Can anyone help?

Thanks a lot!

1 Like

Could you provide more details?

Thank you so much for amazing guide! We will spread out it in our social network soon.

1 Like

Thank you so much for amazing guide! We will spread out it in our social network soon.

What an honor! Thank you so much! :smiling_face_with_three_hearts:

Back to the topic, here are the details. I have a projects that has unit tests. I use pio test, works great. But in this project, “desktop” tests are kind of irrelevant as many of these are tied to the platform. For example, some of these tests a feature that writes to EEPROM.

So I can’t use gcov, as I don’t compile desktop binaries and, AFAIK, can’t generate unit test coverage informations to be sent to SonarQube.

If needed I’d love to provide you with gitlab/sonar access to the mentioned project if for some reason you need to dive further in. Let me know it that option suits you.

Hi @ivankravets, any follow-up on both subjects?

Thank you :slightly_smiling_face:

1 Like

Do you mean this feature request?

Yes, and this (kind of old) one too:

1 Like