continuum-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From c...@apache.org
Subject svn commit: r727150 [2/2] - in /continuum/branches/continuum-distributed-builds/continuum-distributed-build: ./ continuum-buildagent/continuum-buildagent-core/ continuum-distributed-build-transport/ continuum-distributed-build-transport/continuum-distr...
Date Tue, 16 Dec 2008 21:06:56 GMT
Added: continuum/branches/continuum-distributed-builds/continuum-distributed-build/continuum-distributed-build-transport/continuum-distributed-build-transport-tests/pom.xml
URL: http://svn.apache.org/viewvc/continuum/branches/continuum-distributed-builds/continuum-distributed-build/continuum-distributed-build-transport/continuum-distributed-build-transport-tests/pom.xml?rev=727150&view=auto
==============================================================================
--- continuum/branches/continuum-distributed-builds/continuum-distributed-build/continuum-distributed-build-transport/continuum-distributed-build-transport-tests/pom.xml
(added)
+++ continuum/branches/continuum-distributed-builds/continuum-distributed-build/continuum-distributed-build-transport/continuum-distributed-build-transport-tests/pom.xml
Tue Dec 16 13:06:53 2008
@@ -0,0 +1,123 @@
+<?xml version="1.0"?>
+<!--
+    Licensed to the Apache Software Foundation (ASF) under one
+    or more contributor license agreements.  See the NOTICE file
+    distributed with this work for additional information
+    regarding copyright ownership.  The ASF licenses this file
+    to you 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 xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
+  <parent>
+    <artifactId>continuum-distributed-build-transport</artifactId>
+    <groupId>org.apache.continuum</groupId>
+    <version>1.3.1-SNAPSHOT</version>
+  </parent>
+  <modelVersion>4.0.0</modelVersion>
+  <groupId>org.apache.continuum</groupId>
+  <artifactId>continuum-distributed-build-transport-tests</artifactId>
+  <packaging>war</packaging>
+  <name>Continuum :: Distributed Build :: Transport :: Tests</name>
+  <url>http://continuum.apache.org</url>
+  <dependencies>
+    <dependency>
+      <groupId>org.apache.continuum</groupId>
+      <artifactId>continuum-distributed-build-transport-slave-server</artifactId>
+      <version>1.3.1-SNAPSHOT</version>
+    </dependency>
+    <dependency>
+      <groupId>org.apache.continuum</groupId>
+      <artifactId>continuum-distributed-build-transport-slave-client</artifactId>
+      <version>1.3.1-SNAPSHOT</version>
+    </dependency>
+    <dependency>
+      <groupId>org.apache.continuum</groupId>
+      <artifactId>continuum-distributed-build-transport-master-server</artifactId>
+      <version>1.3.1-SNAPSHOT</version>
+    </dependency>
+    <dependency>
+      <groupId>org.apache.continuum</groupId>
+      <artifactId>continuum-distributed-build-transport-master-client</artifactId>
+      <version>1.3.1-SNAPSHOT</version>
+    </dependency>
+    <dependency>
+      <groupId>org.springframework</groupId>
+      <artifactId>spring-web</artifactId>
+      <version>2.5.4</version>
+    </dependency>
+  </dependencies>
+  
+  <build>
+    <testSourceDirectory>src/test/it</testSourceDirectory>
+    <plugins>
+      <plugin>
+        <groupId>org.mortbay.jetty</groupId>
+        <artifactId>maven-jetty-plugin</artifactId>
+        <version>6.1.11</version>
+        <configuration>
+          <scanIntervalSeconds>10</scanIntervalSeconds>
+          <contextPath>/</contextPath>
+          <stopKey>stopkey</stopKey>
+          <stopPort>9192</stopPort>
+          <jettyEnvXml>${basedir}/src/jetty-env.xml</jettyEnvXml>
+          <connectors>
+            <connector implementation="org.mortbay.jetty.nio.SelectChannelConnector">
+              <port>9191</port>
+              <maxIdleTime>60000</maxIdleTime>
+            </connector>
+          </connectors>
+        </configuration>
+        <executions>
+          <execution>
+            <id>start-jetty</id>
+            <phase>pre-integration-test</phase>
+            <goals>
+              <goal>run</goal>
+            </goals>
+            <configuration>
+              <scanIntervalSeconds>0</scanIntervalSeconds>
+              <daemon>true</daemon>
+            </configuration>
+          </execution>
+          <execution>
+            <id>stop-jetty</id>
+            <phase>post-integration-test</phase>
+            <goals>
+              <goal>stop</goal>
+            </goals>
+          </execution>
+        </executions>
+      </plugin>
+      <plugin>
+        <groupId>org.apache.maven.plugins</groupId>
+        <artifactId>maven-surefire-plugin</artifactId>
+        <version>2.4.3</version>
+        <configuration>
+          <skip>true</skip>
+        </configuration>
+        <executions>
+          <execution>
+            <id>integration-tests</id>
+            <phase>integration-test</phase>
+            <goals>
+              <goal>test</goal>
+            </goals>
+            <configuration>
+              <skip>false</skip>
+            </configuration>
+          </execution>
+        </executions>
+      </plugin>
+    </plugins>
+  </build>
+</project>

Propchange: continuum/branches/continuum-distributed-builds/continuum-distributed-build/continuum-distributed-build-transport/continuum-distributed-build-transport-tests/pom.xml
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: continuum/branches/continuum-distributed-builds/continuum-distributed-build/continuum-distributed-build-transport/continuum-distributed-build-transport-tests/pom.xml
------------------------------------------------------------------------------
    svn:keywords = Author Date Id Revision

Added: continuum/branches/continuum-distributed-builds/continuum-distributed-build/continuum-distributed-build-transport/continuum-distributed-build-transport-tests/src/jetty-env.xml
URL: http://svn.apache.org/viewvc/continuum/branches/continuum-distributed-builds/continuum-distributed-build/continuum-distributed-build-transport/continuum-distributed-build-transport-tests/src/jetty-env.xml?rev=727150&view=auto
==============================================================================
--- continuum/branches/continuum-distributed-builds/continuum-distributed-build/continuum-distributed-build-transport/continuum-distributed-build-transport-tests/src/jetty-env.xml
(added)
+++ continuum/branches/continuum-distributed-builds/continuum-distributed-build/continuum-distributed-build-transport/continuum-distributed-build-transport-tests/src/jetty-env.xml
Tue Dec 16 13:06:53 2008
@@ -0,0 +1,23 @@
+<?xml version="1.0"?>
+<!--
+  ~ Licensed to the Apache Software Foundation (ASF) under one
+  ~ or more contributor license agreements.  See the NOTICE file
+  ~ distributed with this work for additional information
+  ~ regarding copyright ownership.  The ASF licenses this file
+  ~ to you 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.
+  -->
+
+<!DOCTYPE Configure PUBLIC "-//Mort Bay Consulting//DTD Configure//EN" "http://jetty.mortbay.org/configure.dtd">
+
+<Configure class="org.mortbay.jetty.webapp.WebAppContext" />

Propchange: continuum/branches/continuum-distributed-builds/continuum-distributed-build/continuum-distributed-build-transport/continuum-distributed-build-transport-tests/src/jetty-env.xml
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: continuum/branches/continuum-distributed-builds/continuum-distributed-build/continuum-distributed-build-transport/continuum-distributed-build-transport-tests/src/jetty-env.xml
------------------------------------------------------------------------------
    svn:keywords = Author Date Id Revision

Added: continuum/branches/continuum-distributed-builds/continuum-distributed-build/continuum-distributed-build-transport/continuum-distributed-build-transport-tests/src/main/resources/applicationContext.xml
URL: http://svn.apache.org/viewvc/continuum/branches/continuum-distributed-builds/continuum-distributed-build/continuum-distributed-build-transport/continuum-distributed-build-transport-tests/src/main/resources/applicationContext.xml?rev=727150&view=auto
==============================================================================
--- continuum/branches/continuum-distributed-builds/continuum-distributed-build/continuum-distributed-build-transport/continuum-distributed-build-transport-tests/src/main/resources/applicationContext.xml
(added)
+++ continuum/branches/continuum-distributed-builds/continuum-distributed-build/continuum-distributed-build-transport/continuum-distributed-build-transport-tests/src/main/resources/applicationContext.xml
Tue Dec 16 13:06:53 2008
@@ -0,0 +1,34 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<beans xmlns="http://www.springframework.org/schema/beans"
+       xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+       xsi:schemaLocation="http://www.springframework.org/schema/beans
+           http://www.springframework.org/schema/beans/spring-beans-2.5.xsd">
+
+  <bean id="masterBuildAgentTransportServer" class="org.apache.continuum.distributed.transport.master.MasterBuildAgentTransportServer"/>
+  
+  <bean id="slaveBuildAgentTransportServer" class="org.apache.continuum.distributed.transport.slave.SlaveBuildAgentTransportServer">
+    <constructor-arg ref="continuumBuildAgentService"/>
+  </bean>
+  
+  <bean id="continuumBuildAgentService" class="org.apache.continuum.buildagent.ContinuumBuildAgentServiceImpl">
+    <property name="configurationService" ref="buildAgentConfigurationService"/>
+  </bean>
+  
+  <bean id="buildAgentConfigurationService" class="org.apache.continuum.buildagent.configuration.DefaultConfigurationService">
+    <property name="configuration" ref="continuumConfiguration" />
+  </bean>
+  
+  <bean id="continuumConfiguration" class="org.apache.continuum.buildagent.configuration.DefaultContinuumConfiguration">
+    <property name="configurationFile" value="file:${appserver.base}/conf/continuum.xml"
/>
+  </bean>
+  
+  <bean name="xmlrpcServicesList" class="java.util.ArrayList">
+    <constructor-arg>
+      <list>
+        <ref bean="slaveBuildAgentTransportServer"/>
+        <ref bean="masterBuildAgentTransportServer"/>
+      </list>
+    </constructor-arg>
+  </bean>
+  
+</beans>

Propchange: continuum/branches/continuum-distributed-builds/continuum-distributed-build/continuum-distributed-build-transport/continuum-distributed-build-transport-tests/src/main/resources/applicationContext.xml
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: continuum/branches/continuum-distributed-builds/continuum-distributed-build/continuum-distributed-build-transport/continuum-distributed-build-transport-tests/src/main/resources/applicationContext.xml
------------------------------------------------------------------------------
    svn:keywords = Author Date Id Revision

Added: continuum/branches/continuum-distributed-builds/continuum-distributed-build/continuum-distributed-build-transport/continuum-distributed-build-transport-tests/src/main/resources/log4j.xml
URL: http://svn.apache.org/viewvc/continuum/branches/continuum-distributed-builds/continuum-distributed-build/continuum-distributed-build-transport/continuum-distributed-build-transport-tests/src/main/resources/log4j.xml?rev=727150&view=auto
==============================================================================
--- continuum/branches/continuum-distributed-builds/continuum-distributed-build/continuum-distributed-build-transport/continuum-distributed-build-transport-tests/src/main/resources/log4j.xml
(added)
+++ continuum/branches/continuum-distributed-builds/continuum-distributed-build/continuum-distributed-build-transport/continuum-distributed-build-transport-tests/src/main/resources/log4j.xml
Tue Dec 16 13:06:53 2008
@@ -0,0 +1,21 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<!DOCTYPE log4j:configuration SYSTEM "log4j.dtd">
+
+<log4j:configuration xmlns:log4j="http://jakarta.apache.org/log4j/">
+  <appender name="console" class="org.apache.log4j.ConsoleAppender">
+    <param name="Target" value="System.out"/>
+    <layout class="org.apache.log4j.PatternLayout">
+      <param name="ConversionPattern" value="[%p] %-30c{1} - %m%n"/>
+    </layout>
+  </appender>
+  <logger name="org.apache.continuum.distributed">
+    <level value="info"/>
+  </logger>
+  <logger name="org.springframework">
+    <level value="error"/>
+  </logger>
+  <root>
+    <priority value ="info" />
+    <appender-ref ref="console" />
+  </root>
+</log4j:configuration>

Propchange: continuum/branches/continuum-distributed-builds/continuum-distributed-build/continuum-distributed-build-transport/continuum-distributed-build-transport-tests/src/main/resources/log4j.xml
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: continuum/branches/continuum-distributed-builds/continuum-distributed-build/continuum-distributed-build-transport/continuum-distributed-build-transport-tests/src/main/resources/log4j.xml
------------------------------------------------------------------------------
    svn:keywords = Author Date Id Revision

Added: continuum/branches/continuum-distributed-builds/continuum-distributed-build/continuum-distributed-build-transport/continuum-distributed-build-transport-tests/src/main/webapp/WEB-INF/web.xml
URL: http://svn.apache.org/viewvc/continuum/branches/continuum-distributed-builds/continuum-distributed-build/continuum-distributed-build-transport/continuum-distributed-build-transport-tests/src/main/webapp/WEB-INF/web.xml?rev=727150&view=auto
==============================================================================
--- continuum/branches/continuum-distributed-builds/continuum-distributed-build/continuum-distributed-build-transport/continuum-distributed-build-transport-tests/src/main/webapp/WEB-INF/web.xml
(added)
+++ continuum/branches/continuum-distributed-builds/continuum-distributed-build/continuum-distributed-build-transport/continuum-distributed-build-transport-tests/src/main/webapp/WEB-INF/web.xml
Tue Dec 16 13:06:53 2008
@@ -0,0 +1,61 @@
+<!DOCTYPE web-app PUBLIC
+ "-//Sun Microsystems, Inc.//DTD Web Application 2.3//EN"
+ "http://java.sun.com/dtd/web-app_2_3.dtd" >
+
+<web-app>
+  <display-name>Continuum Distributed Build Transport Tests</display-name>
+  
+  <listener>
+    <listener-class>org.springframework.web.context.ContextLoaderListener</listener-class>
+  </listener>
+  
+  <context-param>
+    <param-name>contextConfigLocation</param-name>
+    <param-value>
+      classpath*:/META-INF/spring-context.xml
+      classpath*:/applicationContext.xml
+    </param-value>
+  </context-param>
+  
+  <servlet>
+    <servlet-name>MasterXmlRpcServlet</servlet-name>
+    <servlet-class>
+      com.atlassian.xmlrpc.spring.BinderSpringXmlRpcServlet
+    </servlet-class>
+    <init-param>
+      <param-name>serviceListBeanName</param-name>
+      <param-value>xmlrpcServicesList</param-value>
+    </init-param>
+    <init-param>
+      <param-name>enabledForExtensions</param-name>
+      <param-value>true</param-value>
+    </init-param>
+    <load-on-startup>1</load-on-startup>
+  </servlet>
+  
+  <servlet>
+    <servlet-name>SlaveXmlRpcServlet</servlet-name>
+    <servlet-class>
+      com.atlassian.xmlrpc.spring.BinderSpringXmlRpcServlet
+    </servlet-class>
+    <init-param>
+      <param-name>serviceListBeanName</param-name>
+      <param-value>xmlrpcServicesList</param-value>
+    </init-param>
+    <init-param>
+      <param-name>enabledForExtensions</param-name>
+      <param-value>true</param-value>
+    </init-param>
+    <load-on-startup>1</load-on-startup>
+  </servlet>
+  
+  <servlet-mapping>
+    <servlet-name>MasterXmlRpcServlet</servlet-name>
+    <url-pattern>/master-xmlrpc</url-pattern>
+  </servlet-mapping>
+  
+  <servlet-mapping>
+    <servlet-name>SlaveXmlRpcServlet</servlet-name>
+    <url-pattern>/slave-xmlrpc</url-pattern>
+  </servlet-mapping>
+</web-app>

Propchange: continuum/branches/continuum-distributed-builds/continuum-distributed-build/continuum-distributed-build-transport/continuum-distributed-build-transport-tests/src/main/webapp/WEB-INF/web.xml
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: continuum/branches/continuum-distributed-builds/continuum-distributed-build/continuum-distributed-build-transport/continuum-distributed-build-transport-tests/src/main/webapp/WEB-INF/web.xml
------------------------------------------------------------------------------
    svn:keywords = Author Date Id Revision

Added: continuum/branches/continuum-distributed-builds/continuum-distributed-build/continuum-distributed-build-transport/continuum-distributed-build-transport-tests/src/main/webapp/index.jsp
URL: http://svn.apache.org/viewvc/continuum/branches/continuum-distributed-builds/continuum-distributed-build/continuum-distributed-build-transport/continuum-distributed-build-transport-tests/src/main/webapp/index.jsp?rev=727150&view=auto
==============================================================================
--- continuum/branches/continuum-distributed-builds/continuum-distributed-build/continuum-distributed-build-transport/continuum-distributed-build-transport-tests/src/main/webapp/index.jsp
(added)
+++ continuum/branches/continuum-distributed-builds/continuum-distributed-build/continuum-distributed-build-transport/continuum-distributed-build-transport-tests/src/main/webapp/index.jsp
Tue Dec 16 13:06:53 2008
@@ -0,0 +1,5 @@
+<html>
+<body>
+<h2>Hello World!</h2>
+</body>
+</html>

Propchange: continuum/branches/continuum-distributed-builds/continuum-distributed-build/continuum-distributed-build-transport/continuum-distributed-build-transport-tests/src/main/webapp/index.jsp
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: continuum/branches/continuum-distributed-builds/continuum-distributed-build/continuum-distributed-build-transport/continuum-distributed-build-transport-tests/src/main/webapp/index.jsp
------------------------------------------------------------------------------
    svn:keywords = Author Date Id Revision

Added: continuum/branches/continuum-distributed-builds/continuum-distributed-build/continuum-distributed-build-transport/continuum-distributed-build-transport-tests/src/test/it/org/apache/continuum/distributed/transport/tests/MasterBuildAgentTransportServiceTest.java
URL: http://svn.apache.org/viewvc/continuum/branches/continuum-distributed-builds/continuum-distributed-build/continuum-distributed-build-transport/continuum-distributed-build-transport-tests/src/test/it/org/apache/continuum/distributed/transport/tests/MasterBuildAgentTransportServiceTest.java?rev=727150&view=auto
==============================================================================
--- continuum/branches/continuum-distributed-builds/continuum-distributed-build/continuum-distributed-build-transport/continuum-distributed-build-transport-tests/src/test/it/org/apache/continuum/distributed/transport/tests/MasterBuildAgentTransportServiceTest.java
(added)
+++ continuum/branches/continuum-distributed-builds/continuum-distributed-build/continuum-distributed-build-transport/continuum-distributed-build-transport-tests/src/test/it/org/apache/continuum/distributed/transport/tests/MasterBuildAgentTransportServiceTest.java
Tue Dec 16 13:06:53 2008
@@ -0,0 +1,86 @@
+package org.apache.continuum.distributed.transport.tests;
+
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you 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.
+ */
+
+import java.net.URL;
+import java.util.HashMap;
+
+import junit.framework.TestCase;
+
+import org.apache.continuum.distributed.transport.master.MasterBuildAgentTransportClient;
+import org.apache.continuum.distributed.transport.master.MasterBuildAgentTransportService;
+import org.springframework.beans.factory.BeanFactory;
+import org.springframework.beans.factory.xml.XmlBeanFactory;
+import org.springframework.core.io.ClassPathResource;
+
+/**
+ * MasterBuildAgentTransportServiceTest
+ */
+public class MasterBuildAgentTransportServiceTest
+    extends TestCase
+{
+    private MasterBuildAgentTransportService masterProxy;
+    
+    private BeanFactory beanFactory = new XmlBeanFactory( new ClassPathResource( "applicationContext.xml"
) );
+    
+    protected void setUp()
+        throws Exception
+    {
+        super.setUp();
+        
+        masterProxy = new MasterBuildAgentTransportClient( new URL( "http://localhost:9191/master-xmlrpc"),
null , null );
+    }
+    
+    public void testReturnBuildResult()
+    {
+        try
+        {
+            masterProxy.returnBuildResult( new HashMap() );
+        }
+        catch ( Exception e )
+        {
+            fail( e.getMessage() );
+        }
+    }
+    
+    public void testReturnScmResult()
+    {
+        try
+        {
+            masterProxy.returnScmResult( new HashMap() );
+        }
+        catch ( Exception e )
+        {
+            fail( e.getMessage() );
+        }
+    }
+
+    public void testPing()
+    {
+        try
+        {
+            masterProxy.ping();
+        }
+        catch ( Exception e )
+        {
+            fail( e.getMessage() );
+        }
+    }
+}

Propchange: continuum/branches/continuum-distributed-builds/continuum-distributed-build/continuum-distributed-build-transport/continuum-distributed-build-transport-tests/src/test/it/org/apache/continuum/distributed/transport/tests/MasterBuildAgentTransportServiceTest.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: continuum/branches/continuum-distributed-builds/continuum-distributed-build/continuum-distributed-build-transport/continuum-distributed-build-transport-tests/src/test/it/org/apache/continuum/distributed/transport/tests/MasterBuildAgentTransportServiceTest.java
------------------------------------------------------------------------------
    svn:keywords = Author Date Id Revision

Added: continuum/branches/continuum-distributed-builds/continuum-distributed-build/continuum-distributed-build-transport/continuum-distributed-build-transport-tests/src/test/it/org/apache/continuum/distributed/transport/tests/SlaveBuildAgentTransportServiceTest.java
URL: http://svn.apache.org/viewvc/continuum/branches/continuum-distributed-builds/continuum-distributed-build/continuum-distributed-build-transport/continuum-distributed-build-transport-tests/src/test/it/org/apache/continuum/distributed/transport/tests/SlaveBuildAgentTransportServiceTest.java?rev=727150&view=auto
==============================================================================
--- continuum/branches/continuum-distributed-builds/continuum-distributed-build/continuum-distributed-build-transport/continuum-distributed-build-transport-tests/src/test/it/org/apache/continuum/distributed/transport/tests/SlaveBuildAgentTransportServiceTest.java
(added)
+++ continuum/branches/continuum-distributed-builds/continuum-distributed-build/continuum-distributed-build-transport/continuum-distributed-build-transport-tests/src/test/it/org/apache/continuum/distributed/transport/tests/SlaveBuildAgentTransportServiceTest.java
Tue Dec 16 13:06:53 2008
@@ -0,0 +1,122 @@
+package org.apache.continuum.distributed.transport.tests;
+
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you 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.
+ */
+
+import java.net.URL;
+import java.util.Collections;
+
+import junit.framework.TestCase;
+
+import org.apache.continuum.distributed.transport.slave.SlaveBuildAgentTransportClient;
+import org.apache.continuum.distributed.transport.slave.SlaveBuildAgentTransportService;
+import org.springframework.beans.factory.BeanFactory;
+import org.springframework.beans.factory.xml.XmlBeanFactory;
+import org.springframework.core.io.ClassPathResource;
+
+/**
+ * SlaveBuildAgentTransportServiceTest
+ */
+public class SlaveBuildAgentTransportServiceTest
+    extends TestCase
+{
+    private SlaveBuildAgentTransportService slaveProxy;
+    
+    private BeanFactory beanFactory = new XmlBeanFactory( new ClassPathResource( "applicationContext.xml"
) );
+    
+    protected void setUp()
+        throws Exception
+    {
+        super.setUp();
+        
+        slaveProxy = new SlaveBuildAgentTransportClient( new URL( "http://localhost:9191/slave-xmlrpc"),
null , null );
+    }
+
+    public void testBuildProjects()
+    {
+        try
+        {
+            slaveProxy.buildProjects( Collections.EMPTY_LIST );
+        }
+        catch ( Exception e )
+        {
+            fail( e.getMessage() );
+        }
+    }
+
+    public void testGetAvailableInstallations()
+    {
+        try
+        {
+            slaveProxy.getAvailableInstallations();
+        }
+        catch ( Exception e )
+        {
+            fail( e.getMessage() );
+        }
+    }
+
+    public void testGetBuildResult()
+    {
+        try
+        {
+            slaveProxy.getBuildResult( 0 );
+        }
+        catch ( Exception e )
+        {
+            fail( e.getMessage() );
+        }
+    }
+
+    public void testGetProjectCurrentlyBuilding()
+    {
+        try
+        {
+            slaveProxy.getProjectCurrentlyBuilding();
+        }
+        catch ( Exception e )
+        {
+            fail( e.getMessage() );
+        }
+    }
+
+    public void testIsBusy()
+    {
+        try
+        {
+            slaveProxy.isBusy().booleanValue();
+        }
+        catch ( Exception e )
+        {
+            fail( e.getMessage() );
+        }
+    }
+
+    public void testPing()
+    {
+        try
+        {
+            slaveProxy.ping();
+        }
+        catch ( Exception e )
+        {
+            fail( e.getMessage() );
+        }
+    }
+}

Propchange: continuum/branches/continuum-distributed-builds/continuum-distributed-build/continuum-distributed-build-transport/continuum-distributed-build-transport-tests/src/test/it/org/apache/continuum/distributed/transport/tests/SlaveBuildAgentTransportServiceTest.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: continuum/branches/continuum-distributed-builds/continuum-distributed-build/continuum-distributed-build-transport/continuum-distributed-build-transport-tests/src/test/it/org/apache/continuum/distributed/transport/tests/SlaveBuildAgentTransportServiceTest.java
------------------------------------------------------------------------------
    svn:keywords = Author Date Id Revision

Added: continuum/branches/continuum-distributed-builds/continuum-distributed-build/continuum-distributed-build-transport/pom.xml
URL: http://svn.apache.org/viewvc/continuum/branches/continuum-distributed-builds/continuum-distributed-build/continuum-distributed-build-transport/pom.xml?rev=727150&view=auto
==============================================================================
--- continuum/branches/continuum-distributed-builds/continuum-distributed-build/continuum-distributed-build-transport/pom.xml
(added)
+++ continuum/branches/continuum-distributed-builds/continuum-distributed-build/continuum-distributed-build-transport/pom.xml
Tue Dec 16 13:06:53 2008
@@ -0,0 +1,63 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+Licensed to the Apache Software Foundation (ASF) under one
+or more contributor license agreements.  See the NOTICE file
+distributed with this work for additional information
+regarding copyright ownership.  The ASF licenses this file
+to you 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 xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
+  <parent>
+    <artifactId>continuum-distributed-build</artifactId>
+    <groupId>org.apache.continuum</groupId>
+    <version>1.3.1-SNAPSHOT</version>
+  </parent>
+  <modelVersion>4.0.0</modelVersion>
+  <artifactId>continuum-distributed-build-transport</artifactId>
+  <name>Continuum :: Distributed Build :: Transport</name>
+  <packaging>pom</packaging>
+  <modules>
+    <module>continuum-distributed-build-transport-master</module>
+    <module>continuum-distributed-build-transport-slave</module>
+    <module>continuum-distributed-build-transport-tests</module>
+  </modules>
+  <dependencies>
+    <dependency>
+      <groupId>org.slf4j</groupId>
+      <artifactId>slf4j-api</artifactId>
+    </dependency>
+    <dependency>
+      <groupId>org.slf4j</groupId>
+      <artifactId>slf4j-log4j12</artifactId>
+      <version>1.5.0</version>
+    </dependency>
+    <dependency>
+      <groupId>junit</groupId>
+      <artifactId>junit</artifactId>
+      <version>3.8.1</version>
+      <scope>test</scope>
+    </dependency>
+    <dependency>
+      <groupId>easymock</groupId>
+      <artifactId>easymock</artifactId>
+      <version>1.2_Java1.3</version>
+      <scope>test</scope>
+    </dependency>
+    <dependency>
+      <groupId>easymock</groupId>
+      <artifactId>easymockclassextension</artifactId>
+      <version>1.2</version>
+      <scope>test</scope>
+    </dependency>
+  </dependencies>
+</project>

Propchange: continuum/branches/continuum-distributed-builds/continuum-distributed-build/continuum-distributed-build-transport/pom.xml
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: continuum/branches/continuum-distributed-builds/continuum-distributed-build/continuum-distributed-build-transport/pom.xml
------------------------------------------------------------------------------
    svn:keywords = Author Date Id Revision

Modified: continuum/branches/continuum-distributed-builds/continuum-distributed-build/pom.xml
URL: http://svn.apache.org/viewvc/continuum/branches/continuum-distributed-builds/continuum-distributed-build/pom.xml?rev=727150&r1=727149&r2=727150&view=diff
==============================================================================
--- continuum/branches/continuum-distributed-builds/continuum-distributed-build/pom.xml (original)
+++ continuum/branches/continuum-distributed-builds/continuum-distributed-build/pom.xml Tue
Dec 16 13:06:53 2008
@@ -31,5 +31,6 @@
   <name>Continuum :: Distributed Build</name>
   <modules>
     <module>continuum-buildagent</module>
+    <module>continuum-distributed-build-transport</module>
   </modules>
 </project>



Mime
View raw message