You are viewing a plain text version of this content. The canonical link for it is here.
Posted to axis-cvs@ws.apache.org by he...@apache.org on 2005/07/14 10:40:58 UTC
svn commit: r219013 - in /webservices/axis/trunk/java: maven.xml
modules/samples/script/wsdl-test.xml
modules/samples/test/org/apache/axis2/mail/UtilsMailServer.java
Author: hemapani
Date: Thu Jul 14 01:40:57 2005
New Revision: 219013
URL: http://svn.apache.org/viewcvs?rev=219013&view=rev
Log:
add the httpclient jar to the war and dist-bin
Added:
webservices/axis/trunk/java/modules/samples/script/wsdl-test.xml
webservices/axis/trunk/java/modules/samples/test/org/apache/axis2/mail/UtilsMailServer.java
Modified:
webservices/axis/trunk/java/maven.xml
Modified: webservices/axis/trunk/java/maven.xml
URL: http://svn.apache.org/viewcvs/webservices/axis/trunk/java/maven.xml?rev=219013&r1=219012&r2=219013&view=diff
==============================================================================
--- webservices/axis/trunk/java/maven.xml (original)
+++ webservices/axis/trunk/java/maven.xml Thu Jul 14 01:40:57 2005
@@ -330,7 +330,6 @@
<ant:lib dir="target/lib">
<ant:include name="**"/>
<ant:exclude name="**servlet**"/>
- <ant:exclude name="commons-httpclient-*.jar"/>
<ant:exclude name="ant*.jar"/>
</ant:lib>
<ant:classes dir="modules/core/conf">
@@ -376,7 +375,6 @@
<ant:fileset dir="target/lib">
<ant:include name="*.jar"/>
<ant:exclude name="**servlet**.jar"/>
- <ant:exclude name="commons-httpclient-*.jar"/>
<ant:exclude name="ant*.jar"/>
<ant:exclude name="commons-fileupload-*.jar"/>
</ant:fileset>
Added: webservices/axis/trunk/java/modules/samples/script/wsdl-test.xml
URL: http://svn.apache.org/viewcvs/webservices/axis/trunk/java/modules/samples/script/wsdl-test.xml?rev=219013&view=auto
==============================================================================
--- webservices/axis/trunk/java/modules/samples/script/wsdl-test.xml (added)
+++ webservices/axis/trunk/java/modules/samples/script/wsdl-test.xml Thu Jul 14 01:40:57 2005
@@ -0,0 +1,84 @@
+m<?xml version="1.0"?>
+<!-- ======================================================================
+ Feb 11, 2005 1:04:21 PM
+
+ This build file is intended to compile and run the Axis2 samples
+ provided here with the service being deployed at Tomcat or by
+ running a simple Axis2 server.
+
+
+
+ ====================================================================== -->
+<project name="samples" basedir=".." default="doInterop-test">
+ <property name="maven.repo.local" value="${user.home}/.maven/repository/" />
+ <property name="class.dir" value="${basedir}/target/test-classes" />
+ <property name="report.dir" value="${basedir}/target/test-reports" />
+ <property name="src.dir" value="${basedir}/test" />
+ <property name="interop3.dir" value="target/interop3"/>
+ <property name="work.dir" value="${interop3.dir}/work"/>
+ <property name="calss.dir" value="${interop3.dir}/classes"/>
+ <property name="wsdl.dir" value="${basedir}/../wsdl/test-resources/"/>
+
+
+ <path id="test.classpath">
+ <fileset dir="${maven.repo.local}">
+ <include name="j2ee/jars/activation.jar"/>
+ <include name="j2ee/jars/mail.jar"/>
+ <include name="axis/jars/axis2-core-0.9.jar"/>
+ <include name="axis/jars/axis2-tools-0.9.jar"/>
+ <include name="axis/jars/axis2-xml-0.9.jar"/>
+ <include name="axis/jars/axis2-wsdl-0.9.jar"/>
+ <include name="axis/jars/axis-wsdl4j-1.2.jar"/>
+ <include name="commons-logging/jars/commons-logging-1.0.3.jar"/>
+ <include name="commons-httpclient/jars/commons-httpclient-3.0-rc2.jar"/>
+ <include name="stax/jars/stax-1.1.1-dev.jar"/>
+ <include name="stax/jars/stax-api-1.0.jar"/>
+ <include name="log4j/jars/log4j-1.2.8.jar"/>
+ <include name="junit/jars/*.jar"/>
+ <include name="xmlbeans/jars/xbean-2.0.0-beta1.jar"/>
+ </fileset>
+ </path>
+
+ <taskdef name="wsdl2java"
+ classname="org.apache.axis2.tool.ant.AntCodegenTask"
+ classpathref="test.classpath"/>
+
+ <target name="doInterop-test">
+ <mkdir dir="${interop3.dir}"/>
+ <mkdir dir="${work.dir}"/>
+ <mkdir dir="${calss.dir}"/>
+
+ <wsdl2java WSDLFileName="${wsdl.dir}compound2.wsdl" output="${work.dir}"/>
+ <!--
+ <java classname="org.apache.axis2.wsdl.WSDL2Java">
+ <classpath refid="maven.dependency.classpath"/>
+ <arg value="-uri"/>
+ <arg file="${wsdl.dir}/compound2.wsdl"/>
+ <arg value="-o"/>
+ <arg file="${work.dir}"/>
+ </java>
+ -->
+ <copy file="${wsdl.dir}/InteropClient2.java" todir="${work.dir}" overwrite="true" />
+ <copy file="${wsdl.dir}/echoEmployeeDatabindingSupporter.java" todir="${work.dir}/org/soapinterop/databinding" overwrite="true" />
+
+ <move todir="${classes.dir}/schema">
+ <fileset dir="${work.dir}/schema"/>
+ </move>
+
+ <javac srcdir="${work.dir}" destdir="${classes.dir}" debug="on">
+ <classpath refid="maven.dependency.classpath" />
+ </javac>
+
+ <!-- Run the interop test -->
+ <java classname="Client">
+ <classpath refid="maven.dependency.classpath" />
+ </java>
+
+ <junit dir="${classes.dir}" printsummary="yes" haltonfailure="yes">
+ <classpath refid="maven.dependency.classpath" />
+ <formatter type="plain"/>
+ <test name="InteropClient2" />
+ </junit>
+ </target>
+</project>
+
Added: webservices/axis/trunk/java/modules/samples/test/org/apache/axis2/mail/UtilsMailServer.java
URL: http://svn.apache.org/viewcvs/webservices/axis/trunk/java/modules/samples/test/org/apache/axis2/mail/UtilsMailServer.java?rev=219013&view=auto
==============================================================================
--- webservices/axis/trunk/java/modules/samples/test/org/apache/axis2/mail/UtilsMailServer.java (added)
+++ webservices/axis/trunk/java/modules/samples/test/org/apache/axis2/mail/UtilsMailServer.java Thu Jul 14 01:40:57 2005
@@ -0,0 +1,61 @@
+/*
+ * 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.
+ *
+ * Runtime state of the engine
+ */
+package org.apache.axis2.mail;
+
+import java.io.File;
+
+import junit.framework.TestCase;
+
+import org.apache.axis2.Constants;
+import org.apache.axis2.context.ConfigurationContext;
+import org.apache.axis2.context.ConfigurationContextFactory;
+import org.apache.axis2.transport.mail.server.MailConstants;
+import org.apache.axis2.transport.mail.server.MailServer;
+
+public class UtilsMailServer {
+ private static final String MAIL_TRANSPORT_ENABLED_REPO_PATH =
+ Constants.TESTING_PATH + "mail-transport-enabledRepository";
+
+ private static MailServer server;
+ private static ConfigurationContext configContext;
+
+ public static ConfigurationContext start() throws Exception {
+
+ //start the mail server
+ if (server == null) {
+ configContext = createNewConfigurationContext();
+ MailServer server =
+ new MailServer(
+ configContext,
+ MailConstants.POP_SERVER_PORT,
+ MailConstants.SMTP_SERVER_PORT);
+ }
+ return configContext;
+ }
+ public static ConfigurationContext createNewConfigurationContext() throws Exception {
+ File file = new File(MAIL_TRANSPORT_ENABLED_REPO_PATH);
+ TestCase.assertTrue(
+ "Mail repository directory " + file.getAbsolutePath() + " does not exsist",
+ file.exists());
+ ConfigurationContextFactory builder = new ConfigurationContextFactory();
+ ConfigurationContext configContext =
+ builder.buildConfigurationContext(file.getAbsolutePath());
+ return configContext;
+ }
+ public static void stop(){}
+}