Ok, this is the problem. So you need to specify source files rooted on module level.

Regards,
-marc

On 25.02.16 09:58, [email protected] wrote:
Inside src folder I have different modules like
src ---
      --- module1
               ----com (packages start)
      ----module2
              ------com(packages start)
      -----test(test folder)
              -----module1
                       -----java
                             ------com(package)


On Thursday, 25 February 2016 11:13:24 UTC+5:30, [email protected]  wrote:
Thanks Marc,
In my html I am getting Line Covered Column also.
I am using Mockito framework for unit testing and getting warning also like 
"execution data not matching with runtime class files"
is this is the reason for not showing source file links.

Please help me how to handle this warning and get the source file link.

Thanks
On Wednesday, 24 February 2016 23:00:20 UTC+5:30, Marc R. Hoffmann  wrote:
Hi,

there are two common problems:

1) Missing debug information: Your class files needs to be compiled with
debug information. You check in the JaCoCo report whether line coverage
is reported in the tables.

2) The source files must be properly provided starting from the Java
package root. In your case the package root seems to be more likely
$aps_home/src/test, maybe even $aps_home/src/test/java

Regards,
-marc

On 24.02.16 12:30, [email protected] wrote:
Hi,
Using jacoco to generate report.
Report getting generated .
But no link is coming for Source files.

Please find the below source code for report

task testJacocoReport(type: JacocoReport){

sourceDirectories = fileTree(dir: "$aps_home/src", exclude: 'test/**/*.java')
classDirectories = fileTree(dir: "$buildDir", exclude: 
'test-classes/**/*.class')
executionData files("$aps_home/build/jacoco/jacoco.exec")
def reportDir = "build/jacocoReport"
        reports {
                xml{
                        enabled true
                        destination "$aps_home/build/jacoco.xml"
                }
                csv{
                        enabled true
                        destination "$aps_home/build/jacoco.csv"
                }
                html.destination = reportDir
                }
        doLast {
                println "Jacoco report for client created: 
file://${reportDir.toURI().path}"
        }
}


Please let me know where I am missing .
Regards
SS


--
You received this message because you are subscribed to the Google Groups "JaCoCo 
and EclEmma Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/jacoco/56CF7A71.5060201%40mountainminds.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to