You are viewing a plain text version of this content. The canonical link for it is here.
Posted to derby-commits@db.apache.org by my...@apache.org on 2014/02/13 02:53:10 UTC

svn commit: r1567826 - in /db/derby/code/branches/10.9: ./ java/testing/org/apache/derbyTesting/functionTests/tests/store/UpdateLocksTest.java java/testing/org/apache/derbyTesting/junit/JDBC.java

Author: myrnavl
Date: Thu Feb 13 01:53:10 2014
New Revision: 1567826

URL: http://svn.apache.org/r1567826
Log:
DERBY-5667; testReadCommitted(org.apache.derbyTesting.functionTests.tests.store.UpdateLocksTest)junit.framework.AssertionFailedError: Missing rows in ResultSet
   backport of revision 1567823 from trunk, not a clean merge of JDBC.java

Modified:
    db/derby/code/branches/10.9/   (props changed)
    db/derby/code/branches/10.9/java/testing/org/apache/derbyTesting/functionTests/tests/store/UpdateLocksTest.java
    db/derby/code/branches/10.9/java/testing/org/apache/derbyTesting/junit/JDBC.java

Propchange: db/derby/code/branches/10.9/
------------------------------------------------------------------------------
  Merged /db/derby/code/trunk:r1567787

Modified: db/derby/code/branches/10.9/java/testing/org/apache/derbyTesting/functionTests/tests/store/UpdateLocksTest.java
URL: http://svn.apache.org/viewvc/db/derby/code/branches/10.9/java/testing/org/apache/derbyTesting/functionTests/tests/store/UpdateLocksTest.java?rev=1567826&r1=1567825&r2=1567826&view=diff
==============================================================================
--- db/derby/code/branches/10.9/java/testing/org/apache/derbyTesting/functionTests/tests/store/UpdateLocksTest.java (original)
+++ db/derby/code/branches/10.9/java/testing/org/apache/derbyTesting/functionTests/tests/store/UpdateLocksTest.java Thu Feb 13 01:53:10 2014
@@ -68,6 +68,8 @@ public class UpdateLocksTest extends Bas
 
         try {
             dropTable("a");
+            // commit to prevent message 'table/view a already exists'
+            commit();
         } catch (SQLException e) {
             assertSQLState("42Y55", e);
         }

Modified: db/derby/code/branches/10.9/java/testing/org/apache/derbyTesting/junit/JDBC.java
URL: http://svn.apache.org/viewvc/db/derby/code/branches/10.9/java/testing/org/apache/derbyTesting/junit/JDBC.java?rev=1567826&r1=1567825&r2=1567826&view=diff
==============================================================================
--- db/derby/code/branches/10.9/java/testing/org/apache/derbyTesting/junit/JDBC.java (original)
+++ db/derby/code/branches/10.9/java/testing/org/apache/derbyTesting/junit/JDBC.java Thu Feb 13 01:53:10 2014
@@ -1365,9 +1365,13 @@ public class JDBC {
         }
         rs.close();
 
-        Assert.assertEquals("Unexpected row count",
+        String message = "Unexpected row count, expected: " + expectedRows.length +
+                ", actual: " + actual.size() + "\n" +
+                "\t expected rows: \n\t\t" 
+                + expected + "\n\t actual result: \n\t\t" + actual;
+        Assert.assertEquals(message,
                             expectedRows.length, actual.size());
-        String message = "Missing rows in ResultSet; \n\t expected rows: \n\t\t" 
+        message = "Missing rows in ResultSet; \n\t expected rows: \n\t\t" 
                 + expected + "\n\t actual result: \n\t\t" + actual;
         Assert.assertTrue(message,
                           actual.containsAll(expected));