Skip to content

Commit 97bada7

Browse files
committed
fixup auto-register, but with new debugAutoPause name
1 parent 1b5b086 commit 97bada7

File tree

2 files changed

+6
-0
lines changed

2 files changed

+6
-0
lines changed

test/model/actions_test.dart

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@ import 'package:flutter_test/flutter_test.dart';
77
import 'package:http/http.dart' as http;
88
import 'package:http/testing.dart' as http_testing;
99
import 'package:zulip/model/actions.dart';
10+
import 'package:zulip/model/push_device.dart';
1011
import 'package:zulip/model/store.dart';
1112
import 'package:zulip/notifications/receive.dart';
1213

@@ -147,6 +148,8 @@ void main() {
147148
}));
148149

149150
test('notifications are removed after logout', () => awaitFakeAsync((async) async {
151+
PushDeviceManager.debugAutoPause = true;
152+
addTearDown(() => PushDeviceManager.debugAutoPause = false);
150153
await prepare();
151154
testBinding.firebaseMessagingInitialToken = '123';
152155
addTearDown(NotificationService.debugReset);

test/notifications/open_test.dart

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@ import 'package:zulip/host/notifications.dart';
1010
import 'package:zulip/model/database.dart';
1111
import 'package:zulip/model/localizations.dart';
1212
import 'package:zulip/model/narrow.dart';
13+
import 'package:zulip/model/push_device.dart';
1314
import 'package:zulip/notifications/open.dart';
1415
import 'package:zulip/notifications/receive.dart';
1516
import 'package:zulip/widgets/app.dart';
@@ -80,6 +81,8 @@ void main() {
8081
testBinding.firebaseMessagingInitialToken = '012abc';
8182
addTearDown(NotificationService.debugReset);
8283
NotificationService.debugBackgroundIsolateIsLive = false;
84+
PushDeviceManager.debugAutoPause = true;
85+
addTearDown(() => PushDeviceManager.debugAutoPause = false);
8386
await NotificationService.instance.start();
8487
}
8588

0 commit comments

Comments
 (0)