-
Notifications
You must be signed in to change notification settings - Fork 4
/
Copy pathanttest.xml
47 lines (43 loc) · 1.53 KB
/
anttest.xml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
<project name="Example" xmlns:jacoco="antlib:org.jacoco.ant">
<taskdef uri="antlib:org.jacoco.ant" resource="org/jacoco/ant/antlib.xml">
<classpath>
<fileset dir="jacoco/lib">
<include name="*.jar"/>
</fileset>
</classpath>
</taskdef>
<target name="test">
<jacoco:coverage>
<junit fork="true" forkmode="once" printsummary="true">
<classpath location="out/test/Calculator" />
<classpath>
<fileset dir="lib">
<include name="*.jar"/>
</fileset>
</classpath>
<batchtest fork="yes">
<fileset dir="test">
<include name="**/*Test*.java" />
</fileset>
</batchtest>
</junit>
</jacoco:coverage>
</target>
<taskdef name="testng" classname="org.testng.TestNGAntTask">
<classpath location="lib/testng-6.7.jar" />
</taskdef>
<target name="testng">
<jacoco:coverage>
<testng>
<classpath location="out/test/Calculator" />
<classpath location="test" />
<classpath>
<fileset dir="lib">
<include name="*.jar"/>
</fileset>
</classpath>
<classfileset dir="out/test/Calculator" includes="**/*TestNG.class" />
</testng>
</jacoco:coverage>
</target>
</project>