portals-jetspeed-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From wea...@apache.org
Subject cvs commit: jakarta-jetspeed-2/components/persistence project.xml
Date Thu, 20 May 2004 21:10:08 GMT
weaver      2004/05/20 14:10:08

  Modified:    components/persistence/src/test/org/apache/jetspeed/components/persistence
                        TestPersistenceContainer.java
               components/persistence project.xml
  Added:       components/persistence/src/test log4j.properties
  Removed:     components/persistence/src/test/org/apache/jetspeed/containers
                        test.persistence.groovy
               components/persistence/src/java/org/apache/jetspeed/components/persistence/store/ojb
                        OJBTypeIntializer.java
               components/persistence/src/test Log4j.properties
  Log:
  - A little clean up of the source tree.
  - Test cases no longer use a container, they just directly build the required component.
  - The Datasource is now handled by the DatasourceTestCase.
  
  Revision  Changes    Path
  1.2       +43 -0     jakarta-jetspeed-2/components/persistence/src/test/log4j.properties
  
  
  
  
  1.11      +9 -33     jakarta-jetspeed-2/components/persistence/src/test/org/apache/jetspeed/components/persistence/TestPersistenceContainer.java
  
  Index: TestPersistenceContainer.java
  ===================================================================
  RCS file: /home/cvs/jakarta-jetspeed-2/components/persistence/src/test/org/apache/jetspeed/components/persistence/TestPersistenceContainer.java,v
  retrieving revision 1.10
  retrieving revision 1.11
  diff -u -r1.10 -r1.11
  --- TestPersistenceContainer.java	9 Mar 2004 16:15:37 -0000	1.10
  +++ TestPersistenceContainer.java	20 May 2004 21:10:08 -0000	1.11
  @@ -17,13 +17,12 @@
   import java.util.ArrayList;
   
   import junit.framework.Test;
  +import junit.framework.TestSuite;
   
  -import org.apache.jetspeed.components.AbstractComponentAwareTestCase;
  -import org.apache.jetspeed.components.ComponentAwareTestSuite;
   import org.apache.jetspeed.components.persistence.store.Filter;
   import org.apache.jetspeed.components.persistence.store.PersistenceStore;
  -import org.apache.jetspeed.components.persistence.store.PersistenceStoreContainer;
  -import org.picocontainer.MutablePicoContainer;
  +import org.apache.jetspeed.components.persistence.store.ojb.pb.PBStore;
  +import org.apache.jetspeed.components.util.DatasourceTestCase;
   
   /**
    * <p>
  @@ -34,39 +33,18 @@
    * @version $ $
    *  
    */
  -public class TestPersistenceContainer extends AbstractComponentAwareTestCase
  +public class TestPersistenceContainer extends DatasourceTestCase
   {
       
  -    private MutablePicoContainer rdbmsContainer;
  -    private PersistenceStoreContainer persistenceContainer;
  -    private MutablePicoContainer parent;
  -    private PersistenceStore store;
  -
  -
  -    /**
  -     * @param arg0
  -     */
  -    public TestPersistenceContainer(String arg0)
  -    {
  -        super(arg0, "./src/test/Log4j.properties");
  -        // TODO Auto-generated constructor stub
  -    }
  +    private PersistenceStore store; 
   
       public static Test suite()
       {
  -        ComponentAwareTestSuite suite = new ComponentAwareTestSuite(TestPersistenceContainer.class);
  -        suite.setScript("org/apache/jetspeed/containers/test.persistence.groovy");
  -        
  -        return suite;
  -    }
  -
  -    public void testStartContainer()
  -    {
  -        assertNotNull(parent);
  -        assertNotNull(persistenceContainer);
  -        assertNotNull(store);
  +        // All methods starting with "test" will be executed in the test suite.
  +        return new TestSuite(TestPersistenceContainer.class);
       }
   
  +   
       public void test001() throws Exception
       {
           try
  @@ -139,8 +117,6 @@
       protected void setUp() throws Exception
       {
           super.setUp();
  -        parent = (MutablePicoContainer) getContainer();
  -        persistenceContainer = (PersistenceStoreContainer) parent.getComponentInstance(PersistenceStoreContainer.class);
  -        store = persistenceContainer.getStore("jetspeed");
  +        store = new PBStore("jetspeed");        
       }
   }
  
  
  
  1.13      +2 -39     jakarta-jetspeed-2/components/persistence/project.xml
  
  Index: project.xml
  ===================================================================
  RCS file: /home/cvs/jakarta-jetspeed-2/components/persistence/project.xml,v
  retrieving revision 1.12
  retrieving revision 1.13
  diff -u -r1.12 -r1.13
  --- project.xml	20 May 2004 19:44:26 -0000	1.12
  +++ project.xml	20 May 2004 21:10:08 -0000	1.13
  @@ -32,11 +32,6 @@
     </repository>
   
     <dependencies>
  -  	<dependency>
  -      <id>jetspeed-cm</id>
  -      <groupId>jetspeed2</groupId>
  -      <version>2.0-a1-dev</version>
  -    </dependency>
        <dependency>
         <id>jetspeed-commons</id>
         <groupId>jetspeed2</groupId>
  @@ -83,22 +78,7 @@
         <id>ojb:db-ojb</id>
         <version>1.0.rc6</version>
       </dependency>
  -      <!--
  -	<dependency>
  -      <id>ojb:db-ojb</id>
  -      <version>1.0.rc5-PATCHED</version>
  -      <properties>
  -        <war.bundle.jar>true</war.bundle.jar>
  -      </properties>
  -    </dependency>
     
  -    <dependency>
  -      <id>ojb</id>
  -      <version>1.0.rc4</version>
  -      <properties>
  -        <war.bundle.jar>true</war.bundle.jar>
  -      </properties>
  -    </dependency>-->
        <dependency>
         <id>commons-pool</id>
         <version>1.1</version>
  @@ -118,16 +98,11 @@
       <dependency>
         <id>xml-apis</id>
         <version>2.0.2</version>
  -      <properties>
  -        <war.bundle.jar>true</war.bundle.jar>
  -      </properties>
       </dependency>
        <dependency>
         <id>jdom</id>
         <version>b8</version>
  -      <properties>
  -        <war.bundle.jar>true</war.bundle.jar>
  -      </properties>
  +
       </dependency>
       <!-- This is only a test dependency -->
       <dependency>
  @@ -137,19 +112,7 @@
       <dependency>
         <id>picocontainer</id>
         <version>1.0-beta-5</version>
  -    </dependency>
  -    <dependency>
  -      <id>nanocontainer</id>
  -      <version>1.0-beta-1</version>
  -    </dependency>
  -     <dependency>
  -      <id>groovy</id>
  -     <version>1.0-beta-4-snapshot</version>
  -    </dependency>
  -     <dependency>
  -      <id>asm</id>
  -      <version>1.4.1</version>
  -    </dependency>
  +    </dependency>    
       <dependency>
         <id>jta</id>
         <jar>jta1.0.1.jar</jar>
  
  
  

---------------------------------------------------------------------
To unsubscribe, e-mail: jetspeed-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: jetspeed-dev-help@jakarta.apache.org


Mime
View raw message