@@ -155,7 +155,7 @@ void main() {
155
155
testWidgets ('unread badge shows with unreads' , (tester) async {
156
156
final stream = eg.stream ();
157
157
final unreadMsgs = eg.unreadMsgs (channels: [
158
- UnreadChannelSnapshot (streamId: stream.streamId, topic: 'a' , unreadMessageIds: [1 , 2 ]),
158
+ eg. unreadChannelMsgs (streamId: stream.streamId, topic: 'a' , unreadMessageIds: [1 , 2 ]),
159
159
]);
160
160
await setupStreamListPage (tester, subscriptions: [
161
161
eg.subscription (stream),
@@ -167,8 +167,8 @@ void main() {
167
167
testWidgets ('unread badge counts unmuted only' , (tester) async {
168
168
final stream = eg.stream ();
169
169
final unreadMsgs = eg.unreadMsgs (channels: [
170
- UnreadChannelSnapshot (streamId: stream.streamId, topic: 'a' , unreadMessageIds: [1 , 2 ]),
171
- UnreadChannelSnapshot (streamId: stream.streamId, topic: 'b' , unreadMessageIds: [3 ]),
170
+ eg. unreadChannelMsgs (streamId: stream.streamId, topic: 'a' , unreadMessageIds: [1 , 2 ]),
171
+ eg. unreadChannelMsgs (streamId: stream.streamId, topic: 'b' , unreadMessageIds: [3 ]),
172
172
]);
173
173
await setupStreamListPage (tester,
174
174
subscriptions: [eg.subscription (stream, isMuted: true )],
@@ -198,7 +198,7 @@ void main() {
198
198
testWidgets ('muted unread badge shows when unreads are visible in channel but not inbox' , (tester) async {
199
199
final stream = eg.stream ();
200
200
final unreadMsgs = eg.unreadMsgs (channels: [
201
- UnreadChannelSnapshot (streamId: stream.streamId, topic: 'b' , unreadMessageIds: [3 ]),
201
+ eg. unreadChannelMsgs (streamId: stream.streamId, topic: 'b' , unreadMessageIds: [3 ]),
202
202
]);
203
203
await setupStreamListPage (tester,
204
204
subscriptions: [eg.subscription (stream, isMuted: true )],
@@ -211,7 +211,7 @@ void main() {
211
211
testWidgets ('muted unread badge does not show when unreads are visible in both channel & inbox' , (tester) async {
212
212
final stream = eg.stream ();
213
213
final unreadMsgs = eg.unreadMsgs (channels: [
214
- UnreadChannelSnapshot (streamId: stream.streamId, topic: 'b' , unreadMessageIds: [3 ]),
214
+ eg. unreadChannelMsgs (streamId: stream.streamId, topic: 'b' , unreadMessageIds: [3 ]),
215
215
]);
216
216
await setupStreamListPage (tester,
217
217
subscriptions: [eg.subscription (stream, isMuted: false )],
@@ -224,7 +224,7 @@ void main() {
224
224
testWidgets ('muted unread badge does not show when unreads are not visible in channel nor inbox' , (tester) async {
225
225
final stream = eg.stream ();
226
226
final unreadMsgs = eg.unreadMsgs (channels: [
227
- UnreadChannelSnapshot (streamId: stream.streamId, topic: 'b' , unreadMessageIds: [3 ]),
227
+ eg. unreadChannelMsgs (streamId: stream.streamId, topic: 'b' , unreadMessageIds: [3 ]),
228
228
]);
229
229
await setupStreamListPage (tester,
230
230
subscriptions: [eg.subscription (stream, isMuted: true )],
@@ -237,7 +237,7 @@ void main() {
237
237
testWidgets ('color propagates to icon and badge' , (tester) async {
238
238
final stream = eg.stream ();
239
239
final unreadMsgs = eg.unreadMsgs (channels: [
240
- UnreadChannelSnapshot (streamId: stream.streamId, topic: 'a' , unreadMessageIds: [1 , 2 ]),
240
+ eg. unreadChannelMsgs (streamId: stream.streamId, topic: 'a' , unreadMessageIds: [1 , 2 ]),
241
241
]);
242
242
final subscription = eg.subscription (stream, color: Colors .red.argbInt);
243
243
final swatch = ChannelColorSwatch .light (subscription.color);
@@ -275,8 +275,8 @@ void main() {
275
275
eg.userTopicItem (stream2, 'b' , UserTopicVisibilityPolicy .unmuted),
276
276
],
277
277
unreadMsgs: eg.unreadMsgs (channels: [
278
- UnreadChannelSnapshot (streamId: stream1.streamId, topic: 'a' , unreadMessageIds: [1 , 2 ]),
279
- UnreadChannelSnapshot (streamId: stream2.streamId, topic: 'b' , unreadMessageIds: [3 ]),
278
+ eg. unreadChannelMsgs (streamId: stream1.streamId, topic: 'a' , unreadMessageIds: [1 , 2 ]),
279
+ eg. unreadChannelMsgs (streamId: stream2.streamId, topic: 'b' , unreadMessageIds: [3 ]),
280
280
]),
281
281
);
282
282
@@ -310,10 +310,10 @@ void main() {
310
310
eg.userTopicItem (mutedStreamWithNoUnmutedUnreads, 'd' , UserTopicVisibilityPolicy .muted),
311
311
],
312
312
unreadMsgs: eg.unreadMsgs (channels: [
313
- UnreadChannelSnapshot (streamId: unmutedStreamWithUnmutedUnreads.streamId, topic: 'a' , unreadMessageIds: [1 ]),
314
- UnreadChannelSnapshot (streamId: unmutedStreamWithNoUnmutedUnreads.streamId, topic: 'b' , unreadMessageIds: [2 ]),
315
- UnreadChannelSnapshot (streamId: mutedStreamWithUnmutedUnreads.streamId, topic: 'c' , unreadMessageIds: [3 ]),
316
- UnreadChannelSnapshot (streamId: mutedStreamWithNoUnmutedUnreads.streamId, topic: 'd' , unreadMessageIds: [4 ]),
313
+ eg. unreadChannelMsgs (streamId: unmutedStreamWithUnmutedUnreads.streamId, topic: 'a' , unreadMessageIds: [1 ]),
314
+ eg. unreadChannelMsgs (streamId: unmutedStreamWithNoUnmutedUnreads.streamId, topic: 'b' , unreadMessageIds: [2 ]),
315
+ eg. unreadChannelMsgs (streamId: mutedStreamWithUnmutedUnreads.streamId, topic: 'c' , unreadMessageIds: [3 ]),
316
+ eg. unreadChannelMsgs (streamId: mutedStreamWithNoUnmutedUnreads.streamId, topic: 'd' , unreadMessageIds: [4 ]),
317
317
]),
318
318
);
319
319
0 commit comments