I'm trying to get coverage data remotely with jacoco agent and reset execution info on server with reset=true;
jacoco java agent on server:
JAVA_OPTIONS="${JAVA_OPTIONS} -javaagent:applications/jacoco/lib/jacocoagent.jar=output=tcpserver,address=*,port=36320"
Ant task on local machine:
<project name="Ant Report Build with JaCoCo" default="get_data" xmlns:jacoco="antlib:org.jacoco.ant">
<property name="result.exec.file" value="test_data.exec"/>
<property name="server" value="my-server.com" />
<property name="port" value ="36320" />
<taskdef uri="antlib:org.jacoco.ant" resource="org/jacoco/ant/antlib.xml">
<classpath path="jacoco\lib\jacocoant.jar"/>
</taskdef>
<target name="get_data">
<jacoco:dump address="${server}" port="${port}" reset="true" append="false" destfile="${result.exec.file}"/>
</target>
</project>
My problem is in resetting execution info after I get dump. If I do some actions on server and then call my ant target "get_data" twice,deleting test_data.exec file between the executions, I get the same coverege data. So it seems that reset=true doesn't work.
How can I make Jacoco to reset coverega data info after I dump it? Would appreciate any help.