fix: fixed test

This commit is contained in:
Deven Joshi
2021-01-07 21:01:20 +05:30
parent 3b19fe6c36
commit b0e76a5408
+12 -4
View File
@@ -42,10 +42,18 @@ void main() {
user: User(id: 'user-id'),
),
]);
when(channelState.lastMessage).thenReturn(Message(
text: 'hello',
user: User(id: 'other-user'),
));
when(channelState.messages).thenReturn([
Message(
text: 'hello',
user: User(id: 'other-user'),
)
]);
when(channelState.messagesStream).thenAnswer((i) => Stream.value([
Message(
text: 'hello',
user: User(id: 'other-user'),
)
]));
await tester.pumpWidget(MaterialApp(
home: StreamChat(