How to get Cppunit report detail at sonarcloud?

I have a project in sonarcloud。

https://sonarcloud.io/component_measures?id=freeeyes&metric=tests

I used cppunit make reports.xml.

sonarcloud display my cppuit example count.

but can’t see cppuint file detail.

my report.xml like this

<?xml version="1.0" encoding='ISO-8859-1' standalone='yes' ?>
<TestRun>
  <FailedTests></FailedTests>
  <SuccessfulTests>
    <Test id="1">
      <Name>CUnit_ConsoleMessage::Test_Do_Message_PoolSet</Name>
    </Test>
  </SuccessfulTests>
  <Statistics>
    <Tests>1</Tests>
    <FailuresTotal>0</FailuresTotal>
    <Errors>0</Errors>
    <Failures>0</Failures>
  </Statistics>
</TestRun>

Is this a question of the format of the report?

thanks.

Hi,

I don’t believe so. Last time I checked, the behaviour is that only the overall number of tests, of errors and of failures are computed from the CPPUnit report.

I’m sorry, I may not have made it clear. I mean, can the CPpunit report show details in the sonarcloud, such as where the test failed, which lines, and so on? Now I uploaded the CPPUnit report. It seems that I can only see one number, how many successful ones and how many failures.

like this:
https://sonarcloud.io/component_measures?id=net.sf.flatpack%3Aflatpack-parent&metric=tests

my project is
https://sonarcloud.io/component_measures?id=freeeyes&metric=tests

i get “No results”

Negative, I confirm that CPPUnit import logic only captures the overall number of tests, of errors and of failures, meaning that the behaviour you’re seeing is expected.

That project is made of Java code and the test import logic is completely different there. So yes there are some subtle differences depending on the language. To be completely transparent: focus and investment now essentially targets bug/vulnerability detection, so it’s unlikely that the CPPUnit import will be further improved (beyond reporting overall numbers).

I know , thanks for your help.

Hi,
i used SonarQube 6.7.3 and i think that i have the same problem.
In my enterprise (Thales LAS Elancourt), it is important for some projects to have CppUnit report detail in SonarQube.
Have you got a tip to do that ? (conversion Cppunit to junit …)
Thanks for your help !

Frédéric Depale