File tree Expand file tree Collapse file tree 1 file changed +7
-0
lines changed Expand file tree Collapse file tree 1 file changed +7
-0
lines changed Original file line number Diff line number Diff line change @@ -515,6 +515,10 @@ extension KeyboardInput on WidgetTester {
515
515
}
516
516
517
517
String get _keyEventPlatform {
518
+ if (keyEventPlatformOverride != null ) {
519
+ return keyEventPlatformOverride! ;
520
+ }
521
+
518
522
switch (defaultTargetPlatform) {
519
523
case TargetPlatform .android:
520
524
return "android" ;
@@ -534,6 +538,9 @@ String get _keyEventPlatform {
534
538
///
535
539
/// When `null` , Flutter's `defaultTargetPlatform` determines the `platform` value
536
540
/// that's passed to every key simulation event.
541
+ ///
542
+ /// It is your responsibility to nullify this value when you're done with your
543
+ /// platform overrides.
537
544
String ? keyEventPlatformOverride;
538
545
539
546
/// Returns a physical keyboard key combination that expects to create the
You can’t perform that action at this time.
0 commit comments