db-jdo-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From c..@apache.org
Subject svn commit: r178822 - in /incubator/jdo/trunk/tck20/test/java/org/apache/jdo/tck: JDO_Test.java pc/company/CompanyModelReader.java
Date Fri, 27 May 2005 21:30:37 GMT
Author: clr
Date: Fri May 27 14:30:35 2005
New Revision: 178822

URL: http://svn.apache.org/viewcvs?rev=178822&view=rev
Log:
add method for adding Class[] to teardown class list; add method to get all Classes from company
model reader

Modified:
    incubator/jdo/trunk/tck20/test/java/org/apache/jdo/tck/JDO_Test.java
    incubator/jdo/trunk/tck20/test/java/org/apache/jdo/tck/pc/company/CompanyModelReader.java

Modified: incubator/jdo/trunk/tck20/test/java/org/apache/jdo/tck/JDO_Test.java
URL: http://svn.apache.org/viewcvs/incubator/jdo/trunk/tck20/test/java/org/apache/jdo/tck/JDO_Test.java?rev=178822&r1=178821&r2=178822&view=diff
==============================================================================
--- incubator/jdo/trunk/tck20/test/java/org/apache/jdo/tck/JDO_Test.java (original)
+++ incubator/jdo/trunk/tck20/test/java/org/apache/jdo/tck/JDO_Test.java Fri May 27 14:30:35
2005
@@ -284,6 +284,13 @@
         this.pcClasses.add(pcClass);
     }
     
+    protected void addTearDownClass(Class[] pcClasses) {
+        if (pcClasses == null) return;
+        for (int i = 0; i < pcClasses.length; ++i) {
+            addTearDownClass(pcClasses[i]);
+        }
+    }
+    
     /**
      * Deletes and unregistres all registered pc instances. 
      */

Modified: incubator/jdo/trunk/tck20/test/java/org/apache/jdo/tck/pc/company/CompanyModelReader.java
URL: http://svn.apache.org/viewcvs/incubator/jdo/trunk/tck20/test/java/org/apache/jdo/tck/pc/company/CompanyModelReader.java?rev=178822&r1=178821&r2=178822&view=diff
==============================================================================
--- incubator/jdo/trunk/tck20/test/java/org/apache/jdo/tck/pc/company/CompanyModelReader.java
(original)
+++ incubator/jdo/trunk/tck20/test/java/org/apache/jdo/tck/pc/company/CompanyModelReader.java
Fri May 27 14:30:35 2005
@@ -38,6 +38,15 @@
     /** The format of date values in the xml representation */
     public static final String DATE_PATTERN = "d/MMM/yyyy";
     
+    /** All classes in the model 
+     */
+    private static final Class[] allClasses = new Class[] {
+        Address.class, Company.class, 
+        DentalInsurance.class, Department.class, Employee.class,
+        FullTimeEmployee.class, Insurance.class, 
+        MedicalInsurance.class, Person.class, Project.class
+    };
+    
     /** 
      * Create a CompanyModelReader for the specified resourceName. 
      * @param resourceName the name of the resource
@@ -210,6 +219,10 @@
      */
     public Project getProject(String name) {
         return (Project)getBean(name, Project.class);
+    }
+    
+    public Class[] getAllClasses() {
+        return allClasses;
     }
     
 }



Mime
View raw message