forked from deftlabs/mongodb-examples
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathbuild.xml
More file actions
112 lines (82 loc) · 4.17 KB
/
Copy pathbuild.xml
File metadata and controls
112 lines (82 loc) · 4.17 KB
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
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
<?xml version="1.0"?>
<!--
Copyright 2011, Deft Labs.
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at:
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
-->
<project name="mongo-java-setOnInsert-test" default="usage" basedir="./" xmlns:aspectj="antlib:org.aspectj">
<!-- ******************************************************************* -->
<!-- Set the base attributes. -->
<!-- ******************************************************************* -->
<property name="dir.build" value="build"/>
<property name="dir.build.java" value="${dir.build}/java/classes"/>
<property name="dir.src" value="src"/>
<property name="dir.src.java" value="src/main"/>
<property name="dir.lib" value="lib"/>
<property file="build.properties" prefix="build.conf"/>
<property environment="env"/>
<path id="classpath.all"><fileset dir="${dir.lib}"><include name="*.jar"/></fileset></path>
<path id="classpath.cp"><pathelement location="${dir.build.java}"/></path>
<!-- ******************************************************************* -->
<!-- Remove the build directory. -->
<!-- ******************************************************************* -->
<target name="clean"><delete dir="${dir.build}"/></target>
<!-- ******************************************************************* -->
<!-- Compile the java classes. -->
<!-- ******************************************************************* -->
<target name="compile">
<mkdir dir="${dir.build.java}"/>
<javac destdir="${dir.build.java}"
target="${build.conf.javac.source}"
debug="true" encoding="UTF-8"
classpathref="classpath.cp"
source="${build.conf.javac.source}"
includeantruntime="false"
debuglevel="lines,vars,source">
<src path="${dir.src.java}"/>
<compilerarg value="-Xlint:all,-fallthrough"/>
<classpath refid="classpath.all"/>
</javac>
</target>
<!-- ******************************************************************* -->
<!-- Run the examples. Mongo must be running to work. -->
<!-- ******************************************************************* -->
<target name="run" depends="compile">
<junit fork="yes" haltonfailure="true">
<jvmarg value="-Duser.timezone=GMT"/>
<jvmarg value="-Dfile.encoding=UTF-8"/>
<jvmarg value="-DsocksProxyHost"/>
<jvmarg value="-DsocksProxtPort"/>
<jvmarg value="-Dhttps.proxyHost"/>
<jvmarg value="-Dhttp.proxyHost"/>
<classpath refid="classpath.all"/>
<classpath><pathelement path="${dir.build.java}"/></classpath>
<formatter type="brief" usefile="false"/>
<batchtest todir=".">
<fileset dir="${dir.build.java}">
<include name="**/*Test.class"/>
</fileset>
</batchtest>
</junit>
</target>
<!-- ******************************************************************* -->
<!-- Describe the build file usage. -->
<!-- ******************************************************************* -->
<target name="usage">
<echo>
----------------------------------------
- Compile the Java files ......................... compile
- Clean the source tree .......................... clean
- Run the examples ............................... run
----------------------------------------
</echo>
</target>
<!-- ******************************************************************* -->
</project>