diff options
Diffstat (limited to '.nant/local.include')
-rw-r--r-- | .nant/local.include | 104 |
1 files changed, 76 insertions, 28 deletions
diff --git a/.nant/local.include b/.nant/local.include index 1e1c030..510bdc6 100644 --- a/.nant/local.include +++ b/.nant/local.include | |||
@@ -1,6 +1,7 @@ | |||
1 | <!-- -*- xml -*- --> | 1 | <!-- -*- xml -*- --> |
2 | <!-- please leve the top comment for us emacs folks --> | 2 | <!-- please leave the top comment for us emacs folks --> |
3 | <property name="projectdir" value="opensim-0.5.5" /> | 3 | <property name="projectdir" value="opensim-0.5.5" /> |
4 | <property name="nunitcmd" value="nunit-console" /> | ||
4 | 5 | ||
5 | <target name="distdir"> | 6 | <target name="distdir"> |
6 | <delete dir="${projectdir}" /> | 7 | <delete dir="${projectdir}" /> |
@@ -29,24 +30,56 @@ | |||
29 | <touch file="${projectdir}/bin/startup_commands.txt" /> | 30 | <touch file="${projectdir}/bin/startup_commands.txt" /> |
30 | </target> | 31 | </target> |
31 | 32 | ||
32 | <target name="test" depends="build"> | 33 | <target name="test" depends="build, find-nunit"> |
33 | <setenv name="MONO_THREADS_PER_CPU" value="100" /> | 34 | <setenv name="MONO_THREADS_PER_CPU" value="100" /> |
34 | <nunit2 failonerror="true" verbose="true"> | 35 | |
35 | <formatter type="Plain" /> | 36 | <!-- Unit Test Assembly --> |
36 | <test> | 37 | <exec program="${nunitcmd}" failonerror="false" resultproperty="testresult.opensim.framework.tests"> |
37 | <assemblies> | 38 | <arg value="./bin/OpenSim.Framework.Tests.dll" /> |
38 | <include name="./bin/OpenSim.Framework.Tests.dll" /> | 39 | </exec> |
39 | <include name="./bin/OpenSim.Framework.Communications.Tests.dll"/> | 40 | |
40 | <include name="./bin/OpenSim.Framework.Servers.Tests.dll" /> | 41 | <exec program="${nunitcmd}" failonerror="false" resultproperty="testresult.opensim.framework.communications.tests"> |
41 | <include name="./bin/OpenSim.Region.ClientStack.LindenUDP.Tests.dll" /> | 42 | <arg value="./bin/OpenSim.Framework.Communications.Tests.dll" /> |
42 | <include name="./bin/OpenSim.Region.ScriptEngine.Tests.dll" /> | 43 | </exec> |
43 | <include name="./bin/OpenSim.Region.CoreModules.Tests.dll" /> | 44 | |
44 | <include name="./bin/OpenSim.Region.Framework.Tests.dll" /> | 45 | <exec program="${nunitcmd}" failonerror="false" resultproperty="testresult.opensim.framework.servers.tests"> |
45 | <include name="./bin/OpenSim.Data.SQLite.Tests.dll" /> | 46 | <arg value="./bin/OpenSim.Framework.Servers.Tests.dll" /> |
46 | <include name="./bin/OpenSim.Data.MySQL.Tests.dll" /> | 47 | </exec> |
47 | </assemblies> | 48 | |
48 | </test> | 49 | <exec program="${nunitcmd}" failonerror="false" resultproperty="testresult.opensim.region.clientstack.lindenudp.tests"> |
49 | </nunit2> | 50 | <arg value="./bin/OpenSim.Region.ClientStack.LindenUDP.Tests.dll" /> |
51 | </exec> | ||
52 | |||
53 | <exec program="${nunitcmd}" failonerror="false" resultproperty="testresult.opensim.region.scriptengine.tests"> | ||
54 | <arg value="./bin/OpenSim.Region.ScriptEngine.Tests.dll" /> | ||
55 | </exec> | ||
56 | |||
57 | <exec program="${nunitcmd}" failonerror="false" resultproperty="testresult.opensim.region.coremodules.tests"> | ||
58 | <arg value="./bin/OpenSim.Region.CoreModules.Tests.dll" /> | ||
59 | </exec> | ||
60 | |||
61 | <exec program="${nunitcmd}" failonerror="false" resultproperty="testresult.opensim.region.framework.tests"> | ||
62 | <arg value="./bin/OpenSim.Region.Framework.Tests.dll" /> | ||
63 | </exec> | ||
64 | |||
65 | <exec program="${nunitcmd}" failonerror="false" resultproperty="testresult.opensim.data.sqlite.tests"> | ||
66 | <arg value="./bin/OpenSim.Data.SQLite.Tests.dll" /> | ||
67 | </exec> | ||
68 | |||
69 | <exec program="${nunitcmd}" failonerror="false" resultproperty="testresult.opensim.data.mysql.tests"> | ||
70 | <arg value="./bin/OpenSim.Data.MySQL.Tests.dll" /> | ||
71 | </exec> | ||
72 | |||
73 | <fail message="Failures reported in unit tests." unless="${int::parse(testresult.opensim.framework.tests)==0}" /> | ||
74 | <fail message="Failures reported in unit tests." unless="${int::parse(testresult.opensim.framework.communications.tests)==0}" /> | ||
75 | <fail message="Failures reported in unit tests." unless="${int::parse(testresult.opensim.framework.servers.tests)==0}" /> | ||
76 | <fail message="Failures reported in unit tests." unless="${int::parse(testresult.opensim.region.clientstack.lindenudp.tests)==0}" /> | ||
77 | <fail message="Failures reported in unit tests." unless="${int::parse(testresult.opensim.region.scriptengine.tests)==0}" /> | ||
78 | <fail message="Failures reported in unit tests." unless="${int::parse(testresult.opensim.region.coremodules.tests)==0}" /> | ||
79 | <fail message="Failures reported in unit tests." unless="${int::parse(testresult.opensim.region.framework.tests)==0}" /> | ||
80 | <fail message="Failures reported in unit tests." unless="${int::parse(testresult.opensim.data.sqlite.tests)==0}" /> | ||
81 | <fail message="Failures reported in unit tests." unless="${int::parse(testresult.opensim.data.mysql.tests)==0}" /> | ||
82 | |||
50 | </target> | 83 | </target> |
51 | 84 | ||
52 | <target name="test-cov" depends="build"> | 85 | <target name="test-cov" depends="build"> |
@@ -156,53 +189,68 @@ | |||
156 | 189 | ||
157 | </target> | 190 | </target> |
158 | 191 | ||
192 | <target name="find-nunit"> | ||
193 | <exec program="which" failonerror="false" | ||
194 | resultproperty="hasnunit2"> | ||
195 | <arg value="nunit-console2" /> | ||
196 | </exec> | ||
197 | |||
198 | <property name="nunitcmd" value="nunit-console2" | ||
199 | if="${int::parse(hasnunit2)==0}" /> | ||
200 | <property name="nunitcmd" value="nunit-console" | ||
201 | if="${int::parse(hasnunit2)==1}" /> | ||
202 | |||
203 | </target> | ||
204 | |||
159 | <!-- this is used for panda test execution --> | 205 | <!-- this is used for panda test execution --> |
160 | <!-- work in progress --> | 206 | <!-- work in progress --> |
161 | 207 | ||
162 | <target name="test-xml" depends="build"> | 208 | <target name="test-xml" depends="build, find-nunit"> |
209 | |||
210 | |||
163 | <mkdir dir="test-results" failonerror="false" /> | 211 | <mkdir dir="test-results" failonerror="false" /> |
164 | <!-- Unit Test Assembly --> | 212 | <!-- Unit Test Assembly --> |
165 | <exec program="nunit-console2" failonerror="false" resultproperty="testresult.opensim.framework.tests"> | 213 | <exec program="${nunitcmd}" failonerror="false" resultproperty="testresult.opensim.framework.tests"> |
166 | <arg value="./bin/OpenSim.Framework.Tests.dll" /> | 214 | <arg value="./bin/OpenSim.Framework.Tests.dll" /> |
167 | <arg value="-xml=test-results/OpenSim.Framework.Tests.dll-Results.xml" /> | 215 | <arg value="-xml=test-results/OpenSim.Framework.Tests.dll-Results.xml" /> |
168 | </exec> | 216 | </exec> |
169 | 217 | ||
170 | <exec program="nunit-console2" failonerror="false" resultproperty="testresult.opensim.framework.communications.tests"> | 218 | <exec program="${nunitcmd}" failonerror="false" resultproperty="testresult.opensim.framework.communications.tests"> |
171 | <arg value="./bin/OpenSim.Framework.Communications.Tests.dll" /> | 219 | <arg value="./bin/OpenSim.Framework.Communications.Tests.dll" /> |
172 | <arg value="-xml=test-results/OpenSim.Framework.Communications.Tests.dll-Results.xml" /> | 220 | <arg value="-xml=test-results/OpenSim.Framework.Communications.Tests.dll-Results.xml" /> |
173 | </exec> | 221 | </exec> |
174 | 222 | ||
175 | <exec program="nunit-console2" failonerror="false" resultproperty="testresult.opensim.framework.servers.tests"> | 223 | <exec program="${nunitcmd}" failonerror="false" resultproperty="testresult.opensim.framework.servers.tests"> |
176 | <arg value="./bin/OpenSim.Framework.Servers.Tests.dll" /> | 224 | <arg value="./bin/OpenSim.Framework.Servers.Tests.dll" /> |
177 | <arg value="-xml=test-results/OpenSim.Framework.Servers.Tests.dll-Results.xml" /> | 225 | <arg value="-xml=test-results/OpenSim.Framework.Servers.Tests.dll-Results.xml" /> |
178 | </exec> | 226 | </exec> |
179 | 227 | ||
180 | <exec program="nunit-console2" failonerror="false" resultproperty="testresult.opensim.region.clientstack.lindenudp.tests"> | 228 | <exec program="${nunitcmd}" failonerror="false" resultproperty="testresult.opensim.region.clientstack.lindenudp.tests"> |
181 | <arg value="./bin/OpenSim.Region.ClientStack.LindenUDP.Tests.dll" /> | 229 | <arg value="./bin/OpenSim.Region.ClientStack.LindenUDP.Tests.dll" /> |
182 | <arg value="-xml=test-results/OpenSim.Region.ClientStack.LindenUDP.Tests.dll-Results.xml" /> | 230 | <arg value="-xml=test-results/OpenSim.Region.ClientStack.LindenUDP.Tests.dll-Results.xml" /> |
183 | </exec> | 231 | </exec> |
184 | 232 | ||
185 | <exec program="nunit-console2" failonerror="false" resultproperty="testresult.opensim.region.scriptengine.tests"> | 233 | <exec program="${nunitcmd}" failonerror="false" resultproperty="testresult.opensim.region.scriptengine.tests"> |
186 | <arg value="./bin/OpenSim.Region.ScriptEngine.Tests.dll" /> | 234 | <arg value="./bin/OpenSim.Region.ScriptEngine.Tests.dll" /> |
187 | <arg value="-xml=test-results/OpenSim.Region.ScriptEngine.Tests.dll-Results.xml" /> | 235 | <arg value="-xml=test-results/OpenSim.Region.ScriptEngine.Tests.dll-Results.xml" /> |
188 | </exec> | 236 | </exec> |
189 | 237 | ||
190 | <exec program="nunit-console2" failonerror="false" resultproperty="testresult.opensim.region.coremodules.tests"> | 238 | <exec program="${nunitcmd}" failonerror="false" resultproperty="testresult.opensim.region.coremodules.tests"> |
191 | <arg value="./bin/OpenSim.Region.CoreModules.Tests.dll" /> | 239 | <arg value="./bin/OpenSim.Region.CoreModules.Tests.dll" /> |
192 | <arg value="-xml=test-results/OpenSim.Region.CoreModules.Tests.dll-Results.xml" /> | 240 | <arg value="-xml=test-results/OpenSim.Region.CoreModules.Tests.dll-Results.xml" /> |
193 | </exec> | 241 | </exec> |
194 | 242 | ||
195 | <exec program="nunit-console2" failonerror="false" resultproperty="testresult.opensim.region.framework.tests"> | 243 | <exec program="${nunitcmd}" failonerror="false" resultproperty="testresult.opensim.region.framework.tests"> |
196 | <arg value="./bin/OpenSim.Region.Framework.Tests.dll" /> | 244 | <arg value="./bin/OpenSim.Region.Framework.Tests.dll" /> |
197 | <arg value="-xml=test-results/OpenSim.Region.Framework.Tests.dll-Results.xml" /> | 245 | <arg value="-xml=test-results/OpenSim.Region.Framework.Tests.dll-Results.xml" /> |
198 | </exec> | 246 | </exec> |
199 | 247 | ||
200 | <exec program="nunit-console2" failonerror="false" resultproperty="testresult.opensim.data.sqlite.tests"> | 248 | <exec program="${nunitcmd}" failonerror="false" resultproperty="testresult.opensim.data.sqlite.tests"> |
201 | <arg value="./bin/OpenSim.Data.SQLite.Tests.dll" /> | 249 | <arg value="./bin/OpenSim.Data.SQLite.Tests.dll" /> |
202 | <arg value="-xml=test-results/OpenSim.Data.SQLite.Tests.dll-Results.xml" /> | 250 | <arg value="-xml=test-results/OpenSim.Data.SQLite.Tests.dll-Results.xml" /> |
203 | </exec> | 251 | </exec> |
204 | 252 | ||
205 | <exec program="nunit-console2" failonerror="false" resultproperty="testresult.opensim.data.mysql.tests"> | 253 | <exec program="${nunitcmd}" failonerror="false" resultproperty="testresult.opensim.data.mysql.tests"> |
206 | <arg value="./bin/OpenSim.Data.MySQL.Tests.dll" /> | 254 | <arg value="./bin/OpenSim.Data.MySQL.Tests.dll" /> |
207 | <arg value="-xml=test-results/OpenSim.Data.MySQL.Tests.dll-Results.xml" /> | 255 | <arg value="-xml=test-results/OpenSim.Data.MySQL.Tests.dll-Results.xml" /> |
208 | </exec> | 256 | </exec> |