Assert the last commit in the database
authorReto Buerki <reet@codelabs.ch>
Tue, 13 Mar 2012 20:39:14 +0000 (21:39 +0100)
committerReto Buerki <reet@codelabs.ch>
Tue, 13 Mar 2012 20:39:14 +0000 (21:39 +0100)
src/ch/codelabs/gitter/test/CommitDbAdapterTest.java

index 9c9ee1a..7bc9ce9 100644 (file)
@@ -44,7 +44,7 @@ public class CommitDbAdapterTest extends AndroidTestCase {
                final Cursor c = commitDbAdapter.fetchAllCommits();
                assertTrue(c.getCount() > 0);
 
-               c.moveToFirst();
+               c.moveToLast();
                assertEquals("Update TODO", c.getString
                                (c.getColumnIndexOrThrow(CommitDbAdapter.KEY_TITLE)));
                assertEquals("John Doe doe@example.com", c.getString