]> source.dussan.org Git - jackcess.git/commitdiff
oops, actually test both rows
authorJames Ahlborn <jtahlborn@yahoo.com>
Wed, 17 Mar 2010 14:43:59 +0000 (14:43 +0000)
committerJames Ahlborn <jtahlborn@yahoo.com>
Wed, 17 Mar 2010 14:43:59 +0000 (14:43 +0000)
git-svn-id: https://svn.code.sf.net/p/jackcess/code/jackcess/branches/newformats@451 f203690c-595d-4dc9-a70b-905162fa7fd2

test/src/java/com/healthmarketscience/jackcess/DatabaseTest.java

index 837bd2ac8459238b669f31a4ae179b6ceccbc8ca..cd8732375ccb147cfdd3ad17c1acc3a50945e263 100644 (file)
@@ -199,13 +199,17 @@ public class DatabaseTest extends TestCase {
       assertEquals(4, db.getTableNames().size());
       final Table table = db.getTable("Table1");
 
-      final Map<String, Object> row = table.getNextRow();
+      Map<String, Object> row1 = table.getNextRow();
+      Map<String, Object> row2 = table.getNextRow();
 
-      if("abcdefg".equals(row.get("A"))) {
-        checkTestDBTable1RowABCDEFG(testDB, table, row);
-      } else {
-        checkTestDBTable1RowA(testDB, table, row);
+      if(!"abcdefg".equals(row1.get("A"))) {
+        Map<String, Object> tmpRow = row1;
+        row1 = row2;
+        row2 = tmpRow;
       }
+
+      checkTestDBTable1RowABCDEFG(testDB, table, row1);
+      checkTestDBTable1RowA(testDB, table, row2);
     }
   }