fixes RawDialogRoute
memory leak (#147817)
part of #141198 - Fixes memory leak on `RawDialogRoute` - Adds opt-in test
This commit is contained in:
parent
1fee18760e
commit
4abd7352f8
@ -2286,10 +2286,7 @@ class RawDialogRoute<T> extends PopupRoute<T> {
|
||||
if (_transitionBuilder == null) {
|
||||
// Some default transition.
|
||||
return FadeTransition(
|
||||
opacity: CurvedAnimation(
|
||||
parent: animation,
|
||||
curve: Curves.linear,
|
||||
),
|
||||
opacity: animation,
|
||||
child: child,
|
||||
);
|
||||
}
|
||||
|
@ -8,6 +8,7 @@ import 'dart:ui';
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:flutter/services.dart';
|
||||
import 'package:flutter_test/flutter_test.dart';
|
||||
import 'package:leak_tracker_flutter_testing/leak_tracker_flutter_testing.dart';
|
||||
|
||||
import 'semantics_tester.dart';
|
||||
|
||||
@ -974,7 +975,10 @@ void main() {
|
||||
expect(secondaryAnimationOfRouteOne.value, primaryAnimationOfRouteTwo.value);
|
||||
});
|
||||
|
||||
testWidgets('showGeneralDialog handles transparent barrier color', (WidgetTester tester) async {
|
||||
testWidgets('showGeneralDialog handles transparent barrier color',
|
||||
// TODO(polina-c): remove when fixed https://github.com/flutter/flutter/issues/145600 [leak-tracking-opt-in]
|
||||
experimentalLeakTesting: LeakTesting.settings.withTracked(classes: <String>['CurvedAnimation']),
|
||||
(WidgetTester tester) async {
|
||||
await tester.pumpWidget(MaterialApp(
|
||||
home: Builder(
|
||||
builder: (BuildContext context) {
|
||||
|
Loading…
x
Reference in New Issue
Block a user