Quantcast

Coverage bug on java code with sonar 3.2

classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Coverage bug on java code with sonar 3.2

Alexandre Victoor-2
Hello all
On the sonar c# projects, a class/file looks untested whereas it is pretty well covered by unit tests.
Below a link to nemo:



With a prior version of sonar (I am using 3.1-RC2 on my local PC), the coverage seems correct.
This only think that is a little bit unusual with the unit test for this class is the usage of mockito with powermock...
Sorry to report this a little bit late after the release
Regards

Alex

Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Coverage bug on java code with sonar 3.2

Evgeny Mandrikov
Hi,

I believe that this is a consequence of making JaCoCo as default coverage engine together with usage of powermock, which also transforms classes on-the-fly.

On Thu, Aug 9, 2012 at 12:03 PM, Alexandre Victoor <[hidden email]> wrote:
Hello all
On the sonar c# projects, a class/file looks untested whereas it is pretty well covered by unit tests.
Below a link to nemo:



With a prior version of sonar (I am using 3.1-RC2 on my local PC), the coverage seems correct.
This only think that is a little bit unusual with the unit test for this class is the usage of mockito with powermock...
Sorry to report this a little bit late after the release
Regards

Alex




--
Best regards,
Evgeny Mandrikov aka Godin <http://godin.net.ru>
http://twitter.com/_godin_
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Coverage bug on java code with sonar 3.2

Alexandre Victoor-2

Thanks for your response
You are right, when I switch to cobertura I get a proper coverage.
Do you think we can change the conf in order to use cobertura on this specific project on nemo?
Regards

Alex

Le 9 août 2012 08:11, "Evgeny Mandrikov" <[hidden email]> a écrit :
Hi,

I believe that this is a consequence of making JaCoCo as default coverage engine together with usage of powermock, which also transforms classes on-the-fly.

On Thu, Aug 9, 2012 at 12:03 PM, Alexandre Victoor <[hidden email]> wrote:
Hello all
On the sonar c# projects, a class/file looks untested whereas it is pretty well covered by unit tests.
Below a link to nemo:



With a prior version of sonar (I am using 3.1-RC2 on my local PC), the coverage seems correct.
This only think that is a little bit unusual with the unit test for this class is the usage of mockito with powermock...
Sorry to report this a little bit late after the release
Regards

Alex




--
Best regards,
Evgeny Mandrikov aka Godin <http://godin.net.ru>
http://twitter.com/_godin_
Loading...