Revert "Fixing broken unit test for ConversationAdapter"

Fixes #6250
Commit 7286fd9 that broke this unit test was reverted so the change to
this unit test has also to be reverted since the unit test currently
fails.

Closes #6308
This reverts commit 11463d410dca3fc4757b9f476f77f8a72be08f17.
This commit is contained in:
Siloportem 2017-02-26 17:20:11 +01:00 committed by Moxie Marlinspike
parent 25daf01307
commit 1d3f1cc79e

View File

@ -24,11 +24,14 @@ public class ConversationAdapterTest extends BaseUnitTest {
} }
@Test @Test
public void testGetItemIdEquals() { public void testGetItemIdEquals() throws Exception {
when(cursor.getLong(anyInt())).thenReturn(1234L); when(cursor.getString(anyInt())).thenReturn("SMS::1::1");
long firstId = adapter.getItemId(cursor); long firstId = adapter.getItemId(cursor);
when(cursor.getLong(anyInt())).thenReturn(4321L); when(cursor.getString(anyInt())).thenReturn("MMS::1::1");
long secondId = adapter.getItemId(cursor); long secondId = adapter.getItemId(cursor);
assertNotEquals(firstId, secondId); assertNotEquals(firstId, secondId);
when(cursor.getString(anyInt())).thenReturn("MMS::2::1");
long thirdId = adapter.getItemId(cursor);
assertNotEquals(secondId, thirdId);
} }
} }