diff --git a/packages/flutter_test/lib/src/controller.dart b/packages/flutter_test/lib/src/controller.dart index 2dbbfbb42b..44ddba2f1b 100644 --- a/packages/flutter_test/lib/src/controller.dart +++ b/packages/flutter_test/lib/src/controller.dart @@ -132,12 +132,12 @@ class SemanticsController { /// See also: /// /// * [containsSemantics] and [matchesSemantics], which can be used to match - /// against a single node in the traversal + /// against a single node in the traversal. /// * [containsAllInOrder], which can be given an [Iterable] to fuzzy /// match the order allowing extra nodes before after and between matching - /// parts of the traversal + /// parts of the traversal. /// * [orderedEquals], which can be given an [Iterable] to exactly - /// match the order of the traversal + /// match the order of the traversal. Iterable simulatedAccessibilityTraversal({Finder? start, Finder? end}) { TestAsyncUtils.guardSync(); final List traversal = []; @@ -784,8 +784,10 @@ abstract class WidgetController { /// /// The [WidgetTester] subclass implements this by deferring to the [binding]. /// - /// See also [SchedulerBinding.endOfFrame], which returns a future that could - /// be appropriate to return in the implementation of this method. + /// See also: + /// + /// * [SchedulerBinding.endOfFrame], which returns a future that could be + /// appropriate to return in the implementation of this method. Future pump([Duration duration]); /// Repeatedly calls [pump] with the given `duration` until there are no @@ -1110,8 +1112,9 @@ abstract class WidgetController { /// /// See also: /// * [WidgetController.drag], a method to simulate a drag. - /// * [WidgetController.timedDrag], a method to simulate the drag of a given widget in a given duration. - /// It sends move events at a given frequency and it is useful when there are listeners involved. + /// * [WidgetController.timedDrag], a method to simulate the drag of a given + /// widget in a given duration. It sends move events at a given frequency and + /// it is useful when there are listeners involved. /// * [WidgetController.fling], a method to simulate a fling. Future startGesture( Offset downLocation, { @@ -1313,8 +1316,7 @@ abstract class WidgetController { /// Specify `platform` as one of the platforms allowed in /// [platform.Platform.operatingSystem] to make the event appear to be from /// that type of system. Defaults to "web" on web, and "android" everywhere - /// else. Must not be null. Some platforms (e.g. Windows, iOS) are not yet - /// supported. + /// else. Must not be null. /// /// Specify the `physicalKey` for the event to override what is included in /// the simulated event. If not specified, it uses a default from the US @@ -1359,8 +1361,7 @@ abstract class WidgetController { /// Specify `platform` as one of the platforms allowed in /// [platform.Platform.operatingSystem] to make the event appear to be from /// that type of system. Defaults to "web" on web, and "android" everywhere - /// else. Must not be null. Some platforms (e.g. Windows, iOS) are not yet - /// supported. + /// else. Must not be null. /// /// Specify the `physicalKey` for the event to override what is included in /// the simulated event. If not specified, it uses a default from the US @@ -1433,7 +1434,7 @@ abstract class WidgetController { /// Specify `platform` as one of the platforms allowed in /// [platform.Platform.operatingSystem] to make the event appear to be from that type /// of system. Defaults to "web" on web, and "android" everywhere else. Must not be - /// null. Some platforms (e.g. Windows, iOS) are not yet supported. + /// null. /// /// Specify the `physicalKey` for the event to override what is included in /// the simulated event. If not specified, it uses a default from the US @@ -1639,12 +1640,12 @@ class LiveWidgetController extends WidgetController { for (final PointerEventRecord record in records) { final DateTime now = clock.now(); startTime ??= now; - // So that the first event is promised to receive a zero timeDiff + // So that the first event is promised to receive a zero timeDiff. final Duration timeDiff = record.timeDelay - now.difference(startTime); if (timeDiff.isNegative) { // This happens when something (e.g. GC) takes a long time during the // processing of the events. - // Flush all past events + // Flush all past events. handleTimeStampDiff.add(-timeDiff); record.events.forEach(binding.handlePointerEvent); } else { diff --git a/packages/flutter_test/lib/src/event_simulation.dart b/packages/flutter_test/lib/src/event_simulation.dart index bb7029ed62..db7309a265 100644 --- a/packages/flutter_test/lib/src/event_simulation.dart +++ b/packages/flutter_test/lib/src/event_simulation.dart @@ -742,8 +742,7 @@ class KeyEventSimulator { /// /// Specify `platform` as one of the platforms allowed in /// [Platform.operatingSystem] to make the event appear to be from that type of - /// system. Defaults to the operating system that the test is running on. Some - /// platforms (e.g. Windows, iOS) are not yet supported. + /// system. Defaults to the operating system that the test is running on. /// /// Keys that are down when the test completes are cleared after each test. /// @@ -790,8 +789,7 @@ class KeyEventSimulator { /// /// Specify `platform` as one of the platforms allowed in /// [Platform.operatingSystem] to make the event appear to be from that type of - /// system. Defaults to the operating system that the test is running on. Some - /// platforms (e.g. Windows, iOS) are not yet supported. + /// system. Defaults to the operating system that the test is running on. /// /// Returns true if the key event was handled by the framework. /// @@ -835,8 +833,7 @@ class KeyEventSimulator { /// /// Specify `platform` as one of the platforms allowed in /// [Platform.operatingSystem] to make the event appear to be from that type of - /// system. Defaults to the operating system that the test is running on. Some - /// platforms (e.g. Windows, iOS) are not yet supported. + /// system. Defaults to the operating system that the test is running on. /// /// Returns true if the key event was handled by the framework. /// @@ -885,8 +882,7 @@ class KeyEventSimulator { /// /// Specify `platform` as one of the platforms allowed in /// [Platform.operatingSystem] to make the event appear to be from that type of -/// system. Defaults to the operating system that the test is running on. Some -/// platforms (e.g. Windows, iOS) are not yet supported. +/// system. Defaults to the operating system that the test is running on. /// /// Keys that are down when the test completes are cleared after each test. /// @@ -920,8 +916,7 @@ Future simulateKeyDownEvent( /// /// Specify `platform` as one of the platforms allowed in /// [Platform.operatingSystem] to make the event appear to be from that type of -/// system. Defaults to the operating system that the test is running on. Some -/// platforms (e.g. Windows, iOS) are not yet supported. +/// system. Defaults to the operating system that the test is running on. /// /// Returns true if the key event was handled by the framework. /// @@ -949,8 +944,7 @@ Future simulateKeyUpEvent( /// /// Specify `platform` as one of the platforms allowed in /// [Platform.operatingSystem] to make the event appear to be from that type of -/// system. Defaults to the operating system that the test is running on. Some -/// platforms (e.g. Windows, iOS) are not yet supported. +/// system. Defaults to the operating system that the test is running on. /// /// Returns true if the key event was handled by the framework. ///