Mark ReastaurationManager not disposed (#134832)

This commit is contained in:
derdilla 2023-09-21 01:46:14 +02:00 committed by GitHub
parent 237db2bb2a
commit a0406cccb1
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -18,7 +18,7 @@ void main() {
});
group('RestorationManager', () {
testWidgets('root bucket retrieval', (WidgetTester tester) async {
testWidgetsWithLeakTracking('root bucket retrieval', (WidgetTester tester) async {
final List<MethodCall> callsToEngine = <MethodCall>[];
final Completer<Map<dynamic, dynamic>> result = Completer<Map<dynamic, dynamic>>();
tester.binding.defaultBinaryMessenger.setMockMethodCallHandler(SystemChannels.restoration, (MethodCall call) {
@ -62,7 +62,11 @@ void main() {
});
expect(synchronousBucket, isNotNull);
expect(synchronousBucket, same(rootBucket));
});
},
// TODO(NobodyForNothing): Remove after fixing and cover remaining file
// with leak tests https://github.com/flutter/flutter/issues/134831
leakTrackingTestConfig: const LeakTrackingTestConfig(notDisposedAllowList:
<String, int?>{'RestorationManager': 1}));
testWidgets('root bucket received from engine before retrieval', (WidgetTester tester) async {
SystemChannels.restoration.setMethodCallHandler(null);