Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit d73db0fa authored by Marcus Hagerott's avatar Marcus Hagerott Committed by Android (Google) Code Review
Browse files

Merge "Fix logic error in GroupsDaoIntegrationTests." into ub-contactsdialer-g-dev

parents 41c6886c d3cc63db
Loading
Loading
Loading
Loading
+5 −4
Original line number Diff line number Diff line
@@ -237,11 +237,12 @@ public class GroupsDaoIntegrationTests extends InstrumentationTestCase {

    private void assertGroupWithTitleExists(String title) {
        final Cursor cursor = cr.query(ContactsContract.Groups.CONTENT_URI, null,
                ContactsContract.Groups.TITLE + "=? AND " + ContactsContract.Groups.DELETED + "=?",
                new String[] { title, "0" }, null, null);

                ContactsContract.Groups.TITLE + "=? AND " +
                        ContactsContract.Groups.DELETED + "=? AND " +
                        ContactsContract.Groups.ACCOUNT_NAME + "=?",
                new String[] { title, "0", mAccount.name }, null, null);
        try {
            assertEquals(2, cursor.getCount());
            assertTrue("No group exists with title \"" + title + "\"", cursor.getCount() > 0);
        } finally {
            cursor.close();
        }