Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Newer
Older
100644 157 lines (131 sloc) 5.307 kB
9cf0836 hibernate
schuler authored
1 <project name="Mutation Test" default="compile" basedir=".">
2
3 <!-- Name of project and version -->
4 <property name="proj.name" value="Mutation Test" />
5 <property name="proj.shortname" value="mutation" />
6 <property name="version" value="1.0" />
7
8 <!-- Global properties for this build -->
9 <property name="database.dir" value="database" />
10 <property name="src.java.dir" value="src/main/java" />
11 <property name="lib.dir" value="lib" />
12 <property name="build.dir" value="target" />
13
14 <!-- Classpath declaration -->
15 <path id="project.classpath">
4b67a2d
schuler authored
16 <fileset dir="target/lib/">
9cf0836 hibernate
schuler authored
17 <include name="**/*.jar" />
18 <include name="**/*.zip" />
19 </fileset>
faaf7c2 touch for mutation works
schuler authored
20 <pathelement location="target/mutationTest-1.0-SNAPSHOT-dist.dir/lib/mysql-connector-java-5.0.3.jar"/>
9cf0836 hibernate
schuler authored
21 </path>
22
8e0395f
schuler authored
23 <path id="mutation.classpath">
24 <fileset dir="target/mutationTest-1.0-SNAPSHOT-dist.dir/lib">
25 <include name="**/*.jar" />
26 <include name="**/*.zip" />
27 </fileset>
28 </path>
29
30
9cf0836 hibernate
schuler authored
31 <!-- Useful shortcuts -->
32 <patternset id="meta.files">
33 <include name="**/*.xml" />
34 <include name="**/*.properties" />
35 </patternset>
36
37 <!-- Clean up -->
38 <target name="clean" description="Clean the build directory">
39 <delete dir="${build.dir}" />
40 <mkdir dir="${build.dir}" />
41 </target>
42
43 <!-- Compile Java source -->
44 <target name="compile">
45 <mkdir dir="${build.dir}" />
46 <javac srcdir="${src.java.dir}" destdir="${build.dir}" debug="true" classpathref="project.classpath" />
47 </target>
48
49 <!-- Copy metadata to build classpath -->
50 <target name="copymetafiles">
51 <mkdir dir="${build.dir}" />
52 <copy todir="${build.dir}">
53 <fileset dir="${src.java.dir}">
54 <patternset refid="meta.files" />
55 </fileset>
56 </copy>
57 </target>
58
59 <!-- Run HelloWorld -->
60 <target name="run" depends="compile, copymetafiles" description="Build and run HelloWorld">
61 <java fork="true" classname="hello.HelloWorld" classpathref="project.classpath">
62 <classpath path="${build.dir}" />
63 </java>
64 </target>
65
66 <!-- Hibernate Tools import -->
67 <taskdef name="hibernatetool" classname="org.hibernate.tool.ant.HibernateToolTask" classpathref="project.classpath" />
68
69 <!-- Export the database schema -->
70 <target name="schemaexport" depends="" description="Exports a generated schema to DB and file">
71 <hibernatetool destdir="${basedir}">
faaf7c2 touch for mutation works
schuler authored
72 <classpath>
73 <pathelement path="target/classes/" />
74 <pathelement location="target/mutationTest-1.0-SNAPSHOT-dist.dir/lib/mysql-connector-java-5.0.3.jar"/>
75
76 <!--
77 <fileset dir="target/mutationTest-1.0-SNAPSHOT-dist.dir/lib">
78 <include name="*.jar"/>
79 </fileset>
80 -->
81 </classpath>
4b67a2d
schuler authored
82 <annotationconfiguration configurationfile="src/main/resources/hibernate.cfg.xml" />
9cf0836 hibernate
schuler authored
83 <hbm2ddl drop="true" create="true" export="true" outputfilename="${proj.shortname}-ddl.sql" delimiter=";" format="true" />
84 </hibernatetool>
85 </target>
86
87 <!-- Start the HSQL DB server -->
1befae2 vacation
schuler authored
88 <target name="startdb" description="Run HSQL database server">
9cf0836 hibernate
schuler authored
89 <!-- Delete database files -->
90 <!-- <delete dir="${database.dir}"/>-->
91 <java classname="org.hsqldb.Server" fork="yes" classpathref="project.classpath" failonerror="true">
8e0395f
schuler authored
92 <jvmarg value="-Xmx1024m" />
7c407bf switch coverage results to db
schuler authored
93 <arg value="-database.0" />
9cf0836 hibernate
schuler authored
94 <arg value="file:${database.dir}/db" />
95 </java>
96 </target>
97
7c407bf switch coverage results to db
schuler authored
98
99 <!-- Start the HSQL DB server -->
100 <target name="deletedb" description="delete the db files">
8e0395f
schuler authored
101 <delete dir="${database.dir}" />
7c407bf switch coverage results to db
schuler authored
102 </target>
103
9cf0836 hibernate
schuler authored
104 <!-- Start the HSQL DB browser tool -->
105 <target name="dbmanager" description="Start HSQL DB manager">
106 <java classname="org.hsqldb.util.DatabaseManagerSwing" fork="yes" classpathref="project.classpath" failonerror="true">
107 <arg value="-url" />
108 <arg value="jdbc:hsqldb:hsql://localhost/" />
109 <arg value="-driver" />
110 <arg value="org.hsqldb.jdbcDriver" />
111 </java>
112 </target>
113
114
115
116 <target name="generateDDL" depends="">
117 <mkdir dir="${basedir}/target/generated-sources/schema" />
118 <hibernatetool destdir="${basedir}/target/generated-sources">
119 <classpath refid="maven.compile.classpath" />
120 <classpath refid="maven.plugin.classpath" />
121 <classpath path="target/classes/" />
122 <annotationconfiguration configurationfile="${basedir}/src/main/resources/hibernate.cfg.xml" />
123 <hbm2ddl drop="true" create="true" export="false" outputfilename="schema.ddl" delimiter=";" format="true" />
124 </hibernatetool>
8e0395f
schuler authored
125 <echo message="ddl build" />
126 </target>
127
128
129 <target name="generateCoverageEntries" description="generate the coverage entries for aspectj">
faaf7c2 touch for mutation works
schuler authored
130 <java classname="org.softevo.mutation.coverageResults.TestSuiteCoverageResult" maxmemory="1536m" fork="true">
8e0395f
schuler authored
131 <classpath>
132 <path refid="mutation.classpath" />
133 <path location="target/classes" />
134 </classpath>
135 </java>
9cf0836 hibernate
schuler authored
136 </target>
137
f3e0d0e
schuler authored
138 <target name="showMutationResults" description="prints all mutation results to console">
139 <java classname="org.softevo.mutation.run.PrintResults" maxmemory="1024m" fork="true">
140 <classpath>
141 <path refid="mutation.classpath" />
142 <path location="target/classes" />
143 </classpath>
144 </java>
145 </target>
146
faaf7c2 touch for mutation works
schuler authored
147 <target name="runThreaded" description="run mutation tests multithreaded">
148 <java classname="org.softevo.mutation.run.ThreadPool" maxmemory="1024m" fork="true">
149 <classpath>
150 <path refid="mutation.classpath" />
151 <path location="target/classes" />
152 </classpath>
153 </java>
154 </target>
155
9cf0836 hibernate
schuler authored
156 </project>
Something went wrong with that request. Please try again.