mirror of
https://github.com/oxen-io/session-android.git
synced 2024-11-23 18:15:22 +00:00
Fixing broken unit test for ConversationAdapter
The unit test for ConversationAdapter.getItemId() was
broken by this change: 7286fd9
Fixes #6088
// FREEBIE
This commit is contained in:
parent
53d590947e
commit
11463d410d
@ -24,14 +24,11 @@ public class ConversationAdapterTest extends BaseUnitTest {
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testGetItemIdEquals() throws Exception {
|
||||
when(cursor.getString(anyInt())).thenReturn("SMS::1::1");
|
||||
public void testGetItemIdEquals() {
|
||||
when(cursor.getLong(anyInt())).thenReturn(1234L);
|
||||
long firstId = adapter.getItemId(cursor);
|
||||
when(cursor.getString(anyInt())).thenReturn("MMS::1::1");
|
||||
when(cursor.getLong(anyInt())).thenReturn(4321L);
|
||||
long secondId = adapter.getItemId(cursor);
|
||||
assertNotEquals(firstId, secondId);
|
||||
when(cursor.getString(anyInt())).thenReturn("MMS::2::1");
|
||||
long thirdId = adapter.getItemId(cursor);
|
||||
assertNotEquals(secondId, thirdId);
|
||||
}
|
||||
}
|
Loading…
Reference in New Issue
Block a user