Repository navigation
Expand file tree
/
Copy pathbuild.xml
More file actions
247 lines (212 loc) · 10.6 KB
/
Copy pathbuild.xml
File metadata and controls
247 lines (212 loc) · 10.6 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
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
<?xml version="1.0"?>
<!--
~ Copyright 2004,2005 The Apache Software Foundation.
~
~ 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="interop-doclit" default="main" basedir=".">
<description>
Interop tests for doc-lit, code generated samples
</description>
<property name="dir.doclit" value="doclit-interop"/>
<property name="dir.wsdl" value="./itest-resources/WSDLs"/>
<property name="dir.temp" value="${dir.doclit}/temp"/>
<property name="dir.clients" value="${dir.doclit}/clients"/>
<property environment="env"/>
<property name="dir.src" value="${dir.doclit}/src"/>
<property name="dir.classes" value="${dir.doclit}/classes"/>
<property name="dir.home" value="${user.home}"/>
<!-- Allthe required jars here -->
<path id="jarpath.axis2">
<fileset dir="../../target/lib">
<include name="*.jar"/>
</fileset>
<!-- <fileset dir="${dir.home}/.maven/repository">-->
<!-- <include name="**/**/*.jar"/>-->
<!-- </fileset>-->
</path>
<!-- preparing paths -->
<target name="prepare">
<mkdir dir="${dir.classes}"/>
<mkdir dir="${dir.src}"/>
<mkdir dir="${dir.src}/test"/>
<mkdir dir="${dir.temp}"/>
</target>
<!-- This is where the classes are located for run-1-->
<path id="interop.path">
<path refid="classpath.interop"/>
<path refid="jarpath.axis2"/>
</path>
<!-- This is where the classes are located for run-2>-->
<path id="classpath.interop">
<pathelement path="${dir.classes}"/>
<fileset dir="${dir.classes}">
<include name="**/*.*"/>
</fileset>
</path>
<path id="classpath.interop2">
<!-- <pathelement path="${dir.classes}"/>-->
<fileset dir="${dir.classes}">
<include name="**/*.*"/>
</fileset>
</path>
<target name="clean">
<delete dir="${dir.classes}"/>
<delete dir="${dir.classes}"/>
<delete dir="${dir.classes}"/>
<delete dir="${dir.src}"/>
<delete dir="${dir.src}"/>
<delete dir="${dir.src}"/>
</target>
<target name="temp-clean">
<delete dir="${dir.src}/test"/>
<delete dir="${dir.classes}/schema**/*"/>
<delete dir="${dir.classes}/test"/>
</target>
<description>
////////////////////////////////// CodeGen with WSDL2Java /////////////////////////////////////////////////////////////////////////
</description>
<!-- generating the first file src files-->
<target name="gen" depends="prepare">
<java classname="org.apache.axis2.wsdl.WSDL2Java" fork="true">
<classpath refid="jarpath.axis2"/>
<arg value="-uri"/>
<arg file="./${dir.temp}/current.wsdl"/>
<arg value="-sd"/>
<arg value="-o"/>
<arg file="${dir.src}"/>
<arg value="-p"/>
<arg value="test.stub"/>
</java>
<move todir="${dir.classes}">
<fileset dir="${dir.src}">
<include name="**/schema**/**/*.class"/>
</fileset>
<fileset dir="${dir.src}/resources">
<include name="**/schema**/**/*.xsb"/>
</fileset>
</move>
<delete includeemptydirs="true">
<!-- <fileset dir="${dir.src}/schema**/*" includes="**/*"/>
<fileset dir="${dir.src}" includes="**/schema**/*.xsb"/> -->
<fileset dir="${dir.src}">
<include name="**/schema**/*.class"/>
<include name="**/schema**/*.xsb"/>
</fileset>
</delete>
<delete file="${dir.temp}/current.wsdl"/>
</target>
<description>
/////////////////////////////////// Compiling the generated codes ////////////////////////////////////////////////////////////////////////
</description>
<!-- compiling the first source generated from gen-1 to be used in run-1-->
<target name="compile" depends="gen">
<javac srcdir="${dir.src}" destdir="${dir.classes}">
<include name="**/*.*"/>
<classpath refid="interop.path"/>
</javac>
</target>
<description>
////////////////////////////////////// Compiling the testcases /////////////////////////////////////////////////////////////////////
</description>
<!-- compiling the test case1 to be used in run-1-->
<target name="compile-client1">
<javac srcdir="${dir.clients}" destdir="${dir.classes}">
<include name="**/**/WMRound3Compound1InteropTest.java"/>
<classpath refid="interop.path1"/>
</javac>
</target>
<description>
/////////////////////////////////// Running Tests ////////////////////////////////////////////////////////////////////////
</description>
<!-- runing first test case -->
<target name="run-test" depends="compile">
<junit fork="true" printsummary="false" haltonfailure="false"
failureproperty="tests.failed" showoutput="true">
<classpath>
<pathelement path="${dir.classes}"/>
<path>
<fileset dir="../../target/lib">
<include name="*.jar"/>
</fileset>
</path>
</classpath>
<formatter type="brief" usefile="false"/>
<batchtest>
<fileset dir="${dir.src}">
<include name="**/**/*Test.java"/>
</fileset>
</batchtest>
</junit>
<fail if="tests.failed"/>
<antcall target="temp-clean"/>
</target>
<target name="run" depends="run-test"/>
<target name="main">
<antcall target="clean"></antcall>
<!-- Server Whitemesa -->
<copy file="${dir.wsdl}/compound1.wsdl" tofile="${dir.temp}/current.wsdl"/>
<copy file="${dir.clients}/test/WMRound3Compound1InteropTest.java" todir="${dir.src}/test" />
<antcall target="run"/>
<copy file="${dir.wsdl}/compound2.wsdl" tofile="${dir.temp}/current.wsdl"/>
<copy file="${dir.clients}/test/WMRound3Compound2InteropTest.java" todir="${dir.src}/test" />
<antcall target="run"/>
<copy file="${dir.wsdl}/interoptestheaders.wsdl" tofile="${dir.temp}/current.wsdl"/>
<copy file="${dir.clients}/test/Round3DoclitHeadersInteropTest.java" todir="${dir.src}/test" />
<antcall target="run"/>
<!-- Server MS stk v3.0-->
<copy file="${dir.wsdl}/stkv3Compound1.wsdl" tofile="${dir.temp}/current.wsdl"/>
<copy file="${dir.clients}/test/MsStkv3Round3Compound1InteropTest.java" todir="${dir.src}/test" />
<antcall target="run"/>
<copy file="${dir.wsdl}/stkv3Compound2.wsdl" tofile="${dir.temp}/current.wsdl"/>
<copy file="${dir.clients}/test/MsStkv3Round3Compound2InteropTest.java" todir="${dir.src}/test" />
<antcall target="run"/>
<!-- Test Failed, JIRA 238 -->
<!-- <copy file="${dir.wsdl}/stkv3interopTestDocLit.wsdl" tofile="${dir.temp}/current.wsdl"/>-->
<!-- <copy file="${dir.clients}/test/WMRound3DoclitInteropTest.java" todir="${dir.src}/test" />-->
<!-- <antcall target="run"/>-->
<!-- Test Failed, JIRA 233 -->
<!-- <copy file="${dir.wsdl}/stkv3interopTestDocLitParameters.wsdl" tofile="${dir.temp}/current.wsdl"/>-->
<!-- <copy file="${dir.clients}/test/Round3DoclitparamInteropTest.java" todir="${dir.src}/test" />-->
<!-- <antcall target="run"/>-->
<!-- Server ASP.NET -->
<copy file="${dir.wsdl}/aspnetcompound1.wsdl" tofile="${dir.temp}/current.wsdl"/>
<copy file="${dir.clients}/test/ASPNetRound3Compound1InteropTest.java" todir="${dir.src}/test" />
<antcall target="run"/>
<copy file="${dir.wsdl}/aspnetcompound2.wsdl" tofile="${dir.temp}/current.wsdl"/>
<copy file="${dir.clients}/test/AspNetRound3Compound2InteropTest.java" todir="${dir.src}/test" />
<antcall target="run"/>
<copy file="${dir.wsdl}/aspnetInteropTestDocLit.wsdl" tofile="${dir.temp}/current.wsdl"/>
<copy file="${dir.clients}/test/AspNetRound3DoclitInteropTest.java" todir="${dir.src}/test" />
<antcall target="run"/>
<!-- this test failed, JIRA 233 -->
<!-- <copy file="${dir.wsdl}/aspnetInteropTestDocLitParameters.wsdl" tofile="${dir.temp}/current.wsdl"/>-->
<!-- <copy file="${dir.clients}/test/AspNetRound3DoclitparamInteropTest.java" todir="${dir.src}/test" />-->
<!-- <antcall target="run"/>-->
<!-- Sun Server -->
<copy file="${dir.wsdl}/suncompound1.wsdl" tofile="${dir.temp}/current.wsdl"/>
<copy file="${dir.clients}/test/SunRound3Compound1InteropTest.java" todir="${dir.src}/test" />
<antcall target="run"/>
<copy file="${dir.wsdl}/suncompound2.wsdl" tofile="${dir.temp}/current.wsdl"/>
<copy file="${dir.clients}/test/SunRound3Compound2InteropTest.java" todir="${dir.src}/test" />
<antcall target="run"/>
<!-- Test failed, JIRA 238 -->
<!-- <copy file="${dir.wsdl}/sundoclit.wsdl" tofile="${dir.temp}/current.wsdl"/>-->
<!-- <copy file="${dir.clients}/test/WMRound3DoclitInteropTest.java" todir="${dir.src}/test" />-->
<!-- <antcall target="run"/>-->
<!-- Test Failed, JIRA 233 -->
<!-- <copy file="${dir.wsdl}/sundoclitparams.wsdl" tofile="${dir.temp}/current.wsdl"/>-->
<!-- <copy file="${dir.clients}/test/SunRound3DoclitparamInteropTest.java" todir="${dir.src}/test"/>-->
<!-- <antcall target="run"/>-->
</target>
</project>