Repository: flutter
Issue: Web unit tests `text_editing_test.dart` and `composition_test.dart` fail on Firefox for Mac
Labels: a: tests,engine,platform-mac,platform-web,browser: firefox,P2,team-web,triaged-web

Two different tests fail on Firefox on my M1 Macbook Pro:
```
00:03 +130 ~5 -1: test/text_editing_test.dart: HybridTextEditing focus and connection with blur [E]                                                                                         
  Expected: HtmlElement:<input>
    Actual: <null>
  
  org-dartlang-sdk:///lib/_internal/js_runtime/lib/js_helper.dart 1172:37             wrapException
  org-dartlang-sdk:///lib/_internal/js_runtime/lib/js_helper.dart 1203:25             throwExpression
  /Users/.pub-cache/hosted/pub.dev/test_api-0.4.17/lib/src/expect/expect.dart 134:31  fail
  /Users/.pub-cache/hosted/pub.dev/test_api-0.4.17/lib/src/expect/expect.dart 129:3   _expect
  /Users/.pub-cache/hosted/pub.dev/test_api-0.4.17/lib/src/expect/expect.dart 46:3    expect
  ../../../../flutter/lib/web_ui/test/text_editing_test.dart 708:7                     0.<fn>
  org-dartlang-sdk:///lib/_internal/js_runtime/lib/async_patch.dart 308:19            _wrapJsFunctionForAsync.<fn>
  org-dartlang-sdk:///lib/_internal/js_runtime/lib/async_patch.dart 333:23            call
  org-dartlang-sdk:///lib/_internal/js_runtime/lib/async_patch.dart 284:19            call
  org-dartlang-sdk:///lib/async/zone.dart 1406:39                                     _rootRunUnary
  org-dartlang-sdk:///lib/async/zone.dart 1306:34                                     runUnary
  org-dartlang-sdk:///lib/async/future_impl.dart 147:18                               handleValue
  org-dartlang-sdk:///lib/async/future_impl.dart 784:36                               call
  org-dartlang-sdk:///lib/async/future_impl.dart 813:13                               _Future._propagateToListeners
  org-dartlang-sdk:///lib/async/future_impl.dart 575:7                                _complete
  org-dartlang-sdk:///lib/async/future.dart 423:9                                     call
  org-dartlang-sdk:///lib/async/zone.dart 1390:39                                     _rootRun
  org-dartlang-sdk:///lib/async/zone.dart 1299:34                                     run
  org-dartlang-sdk:///lib/async/zone.dart 1208:7                                      runGuarded
  org-dartlang-sdk:///lib/async/zone.dart 1248:23                                     call
  org-dartlang-sdk:///lib/async/zone.dart 1398:12                                     _rootRun
  org-dartlang-sdk:///lib/async/zone.dart 1299:34                                     run
  org-dartlang-sdk:///lib/async/zone.dart 1232:23                                     call
  org-dartlang-sdk:///lib/_internal/js_runtime/lib/async_patch.dart 122:9             call
  org-dartlang-sdk:///lib/_internal/js_runtime/lib/js_helper.dart 1881:20             invokeClosure
  org-dartlang-sdk:///lib/_internal/js_runtime/lib/js_helper.dart 1911:1              convertDartClosureToJS.<fn>
  

To run this test again: /Users/jacksongardner/Source/flutter/engine/src/flutter/prebuilts/macos-arm64/dart-sdk/bin/dart test test/text_editing_test.dart -p firefox --plain-name 'HybridTextEditing focus and connection with blur'
```

and 

```
00:43 +494 ~43 -2: test/composition_test.dart: Text Editing Delta Model should have newly entered composing characters [E]                                                                  
  TimeoutException after 0:00:30.000000: Test timed out after 30 seconds. See https://pub.dev/packages/test#timeouts
  /Users/.pub-cache/hosted/pub.dev/test_api-0.4.17/lib/src/backend/invoker.dart 334:9   call
  org-dartlang-sdk:///lib/async/zone.dart 1390:39                                       _rootRun
  org-dartlang-sdk:///lib/async/zone.dart 1299:34                                       run
  /Users/.pub-cache/hosted/pub.dev/test_api-0.4.17/lib/src/backend/invoker.dart 332:5   _handleError
  /Users/.pub-cache/hosted/pub.dev/test_api-0.4.17/lib/src/backend/invoker.dart 327:8   _handleError
  /Users/.pub-cache/hosted/pub.dev/test_api-0.4.17/lib/src/backend/invoker.dart 288:9   call
  org-dartlang-sdk:///lib/async/zone.dart 1398:12                                       _rootRun
  org-dartlang-sdk:///lib/async/zone.dart 1299:34                                       run
  /Users/.pub-cache/hosted/pub.dev/test_api-0.4.17/lib/src/backend/invoker.dart 287:38  call
  org-dartlang-sdk:///lib/_internal/js_runtime/lib/async_patch.dart 122:9               call
  org-dartlang-sdk:///lib/_internal/js_runtime/lib/js_helper.dart 1881:20               invokeClosure
  org-dartlang-sdk:///lib/_internal/js_runtime/lib/js_helper.dart 1911:1                convertDartClosureToJS.<fn>
  

To run this test again: /Users/jacksongardner/Source/flutter/engine/src/flutter/prebuilts/macos-arm64/dart-sdk/bin/dart test test/composition_test.dart -p firefox --plain-name 'Text Editing Delta Model should have newly entered composing characters'
```

This seems Mac specific, since we run these tests on Firefox on Linux in CI and they appear to pass.