geronimo-scm mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ammul...@apache.org
Subject svn commit: r394542 - in /geronimo/branches/1.1/modules/service-builder/src: test-resources/empty.jar test/org/apache/geronimo/deployment/service/ServiceConfigBuilderTest.java
Date Sun, 16 Apr 2006 18:39:00 GMT
Author: ammulder
Date: Sun Apr 16 11:39:00 2006
New Revision: 394542

URL: http://svn.apache.org/viewcvs?rev=394542&view=rev
Log:
Add test to make sure the service builder ignores other types of
  deployments

Added:
    geronimo/branches/1.1/modules/service-builder/src/test-resources/empty.jar   (with props)
Modified:
    geronimo/branches/1.1/modules/service-builder/src/test/org/apache/geronimo/deployment/service/ServiceConfigBuilderTest.java

Added: geronimo/branches/1.1/modules/service-builder/src/test-resources/empty.jar
URL: http://svn.apache.org/viewcvs/geronimo/branches/1.1/modules/service-builder/src/test-resources/empty.jar?rev=394542&view=auto
==============================================================================
Binary file - no diff available.

Propchange: geronimo/branches/1.1/modules/service-builder/src/test-resources/empty.jar
------------------------------------------------------------------------------
    svn:mime-type = application/octet-stream

Modified: geronimo/branches/1.1/modules/service-builder/src/test/org/apache/geronimo/deployment/service/ServiceConfigBuilderTest.java
URL: http://svn.apache.org/viewcvs/geronimo/branches/1.1/modules/service-builder/src/test/org/apache/geronimo/deployment/service/ServiceConfigBuilderTest.java?rev=394542&r1=394541&r2=394542&view=diff
==============================================================================
--- geronimo/branches/1.1/modules/service-builder/src/test/org/apache/geronimo/deployment/service/ServiceConfigBuilderTest.java
(original)
+++ geronimo/branches/1.1/modules/service-builder/src/test/org/apache/geronimo/deployment/service/ServiceConfigBuilderTest.java
Sun Apr 16 11:39:00 2006
@@ -42,6 +42,7 @@
 import java.util.LinkedHashSet;
 import java.util.SortedSet;
 import java.util.TreeSet;
+import java.util.jar.JarFile;
 
 /**
  * @version $Rev$ $Date$
@@ -49,6 +50,16 @@
 public class ServiceConfigBuilderTest extends TestCase {
 
     private Environment parentEnvironment = new Environment();
+
+    public void testNonService() throws Exception {
+        URL url = getClass().getResource("/empty.jar");
+        File file = new File(url.getPath());
+        JarFile jar = new JarFile(file);
+        assertTrue(file.exists());
+        ServiceConfigBuilder builder = new ServiceConfigBuilder(parentEnvironment, null,
null, null, new Jsr77Naming());
+        assertNull(builder.getDeploymentPlan(null, jar));
+        jar.close();
+    }
 
     public void testJavaBeanXmlAttribute() throws Exception {
         ReferenceCollection referenceCollection = new MockReferenceCollection();



Mime
View raw message