Unverified Commit 87c2ed18 authored by pdblasi-google's avatar pdblasi-google Committed by GitHub

Reland: Updates `flutter/test/gestures` to no longer reference `TestWindow` (#122619)

Reland: Updates `flutter/test/gestures` to no longer reference `TestWindow`
parent f41ae4f4
......@@ -90,7 +90,9 @@ class NestedDraggableCase extends StatelessWidget {
void main() {
testWidgets('Scroll Views get the same ScrollConfiguration as GestureDetectors', (WidgetTester tester) async {
tester.binding.window.gestureSettingsTestValue = const ui.GestureSettings(physicalTouchSlop: 4);
tester.view.gestureSettings = const ui.GestureSettings(physicalTouchSlop: 4);
addTearDown(tester.view.reset);
final TestResult result = TestResult();
await tester.pumpWidget(MaterialApp(
......@@ -108,11 +110,11 @@ void main() {
expect(result.dragStarted, true);
expect(result.dragUpdate, true);
tester.binding.window.clearGestureSettingsTestValue();
});
testWidgets('Scroll Views get the same ScrollConfiguration as Draggables', (WidgetTester tester) async {
tester.binding.window.gestureSettingsTestValue = const ui.GestureSettings(physicalTouchSlop: 4);
tester.view.gestureSettings = const ui.GestureSettings(physicalTouchSlop: 4);
addTearDown(tester.view.reset);
final TestResult result = TestResult();
......@@ -131,6 +133,5 @@ void main() {
expect(result.dragStarted, true);
expect(result.dragUpdate, true);
tester.binding.window.clearGestureSettingsTestValue();
});
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment