Thanks Jitendra and Evgeny for answering my questions. You guys are very
helpful and supportive.

I would give example project a try and investigate more into it my issue,
would update if find anything interesting specific to my issue.

Thanks,
JK

On Thu, Mar 7, 2019 at 7:31 PM 'Jitendra Kumar' via JaCoCo and EclEmma
Users <[email protected]> wrote:

> Wonderful interpretation Evgeny, sort & sweet, I don't think so anything
> is left to explain.
>
> On Friday, March 8, 2019 at 1:48:41 AM UTC+5:30, Evgeny Mandrikov wrote:
>>
>>
>> On Thursday, March 7, 2019 at 7:43:41 PM UTC+1, jk wrote:
>>>
>>>
>>> I tried to run with the CATALINA_OPTS="${CATALINA_OPTS} ${JACOCO_OPTS}"
>>> but after which the jacoco.exec file generated is of 0 size.
>>>
>>
>> Using examples that come with Tomcat as following:
>>
>> java -version
>>
>> openjdk version "11.0.1" 2018-10-16
>> OpenJDK Runtime Environment 18.9 (build 11.0.1+13)
>> OpenJDK 64-Bit Server VM 18.9 (build 11.0.1+13, mixed mode)
>>
>> mkdir /tmp/j
>> cd /tmp/j
>>
>> wget "
>> http://repo1.maven.org/maven2/org/jacoco/jacoco/0.8.3/jacoco-0.8.3.zip";
>> aunpack jacoco-0.8.3.zip
>>
>> wget "
>> https://archive.apache.org/dist/tomcat/tomcat-8/v8.5.29/bin/apache-tomcat-8.5.29.tar.gz
>> "
>> aunpack apache-tomcat-8.5.29.tar.gz
>>
>> cat <<END >./apache-tomcat-8.5.29/bin/setenv.sh
>> CATALINA_OPTS="\${CATALINA_OPTS}
>> -javaagent:/tmp/j/jacoco-0.8.3/lib/jacocoagent.jar=destfile=/tmp/j/jacoco.exec"
>> END
>>
>> ./apache-tomcat-8.5.29/bin/catalina.sh start
>>
>> curl http://localhost:8080/examples/servlets/servlet/HelloWorldExample
>>
>> ./apache-tomcat-8.5.29/bin/catalina.sh stop 60
>>
>> I just got non zero file:
>>
>> ls -l jacoco.exec
>>
>> -rw-r----- 1 evgeny.mandrikov wheel 38463 Mar  7 20:53 jacoco.exec
>>
>> That includes information about execution of HelloWorldExample :
>>
>> java -jar jacoco-0.8.3/lib/jacococli.jar execinfo jacoco.exec | grep
>> HelloWorldExample
>>
>> f4baf7db7add6fb6   19 of  19   HelloWorldExample
>>
>> Among many other class files:
>>
>> java -jar jacoco-0.8.3/lib/jacococli.jar execinfo jacoco.exec | wc -l
>>
>> 703
>>
>> And got following report:
>>
>> java -jar jacoco-0.8.3/lib/jacococli.jar report jacoco.exec --classfiles
>> apache-tomcat-8.5.29/webapps/examples/WEB-INF/classes/ --html report
>>
>>
>> [image: report.png]
>>
>>
>> --
> You received this message because you are subscribed to a topic in the
> Google Groups "JaCoCo and EclEmma Users" group.
> To unsubscribe from this topic, visit
> https://groups.google.com/d/topic/jacoco/DZNqIGaoPKQ/unsubscribe.
> To unsubscribe from this group and all its topics, send an email to
> [email protected].
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/jacoco/360af5af-c1e5-442b-946b-82191734b92e%40googlegroups.com
> <https://groups.google.com/d/msgid/jacoco/360af5af-c1e5-442b-946b-82191734b92e%40googlegroups.com?utm_medium=email&utm_source=footer>
> .
> For more options, visit https://groups.google.com/d/optout.
>

-- 
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/CAGUsWg6WYWkKFVtqqhb87wcfUDnoj9HdO0uUyddVyhd4PLNNFQ%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to