Hi,
I am submitting the patch files for review for JIRA issue 131.
------------------------------------------------------------------------
Index:
C:/ApacheJDO/trunk/tck20/test/java/org/apache/jdo/tck/JDO_Test.java
===================================================================
---
C:/ApacheJDO/trunk/tck20/test/java/org/apache/jdo/tck/JDO_Test.java
(revision 279926)
+++
C:/ApacheJDO/trunk/tck20/test/java/org/apache/jdo/tck/JDO_Test.java
(working copy)
@@ -137,6 +137,11 @@
/** Name of the file contaninig the properties for the PMF. */
protected static String PMFProperties =
System.getProperty("PMFProperties");
+ /** String indicating whether to clean up data after tests or
not. The value can be either
+ * "true" or "false". If "false" then test will not clean up
data from database
+ */
+ protected static String cleanupData =
System.getProperty("cleanup.data");
+ /** The Properties object for the PersistenceManagerFactory. */
protected static Properties PMFPropertiesObject;
@@ -260,7 +265,9 @@
pmf = null;
try {
- localTearDown();
+ if (cleanupData.equalsIgnoreCase("true")) {
+ localTearDown();
+ }
} catch (Throwable t) {
setTearDownThrowable("localTearDown", t);
------------------------------------------------------------------------
Index: C:/ApacheJDO/trunk/tck20/maven.xml
===================================================================
--- C:/ApacheJDO/trunk/tck20/maven.xml (revision 279926)
+++ C:/ApacheJDO/trunk/tck20/maven.xml (working copy)
@@ -361,6 +361,8 @@
value="${jdo.tck.exclude}"/>
<sysproperty key="jdo.tck.log.directory"
value="${jdo.tck.log.directory}/${timestamp}"/>
+ <sysproperty key="cleanup.data"
+ value="${cleanup.data}"/>
<jvmarg line="${database.runtck.sysproperties}"/>
<jvmarg line="${jdo.runtck.sysproperties}"/>
<arg line="${jdo.tck.classes}"/>
------------------------------------------------------------------------
Index: C:/ApacheJDO/trunk/tck20/project.properties
===================================================================
--- C:/ApacheJDO/trunk/tck20/project.properties (revision 279926)
+++ C:/ApacheJDO/trunk/tck20/project.properties (working copy)
@@ -42,7 +42,8 @@
maven.junit.dir = ${jdo.tck.testdir}
maven.junit.sysproperties = PMFProperties
PMFProperties = jdori.properties
-
+# Setting this property to false will turn off cleanup of data from
database to inspect database contents after test run
+cleanup.data = true
# JDO TCK settings
jdo.tck.dblist=derby
jdo.tck.identitytypes=applicationidentity datastoreidentity