-
Notifications
You must be signed in to change notification settings - Fork 28.9k
Open
Labels
P2Important issues not at the top of the work listImportant issues not at the top of the work lista: desktopRunning on desktopRunning on desktopa: tests"flutter test", flutter_test, or one of our tests"flutter test", flutter_test, or one of our testsplatform-linuxBuilding on or for Linux specificallyBuilding on or for Linux specificallyplatform-macBuilding on or for macOS specificallyBuilding on or for macOS specificallyteam-toolOwned by Flutter Tool teamOwned by Flutter Tool teamtoolAffects the "flutter" command-line tool. See also t: labels.Affects the "flutter" command-line tool. See also t: labels.tool-still-validIssues that have been deemed still valid as part of the Flutter Tools issue cleanup initiative.Issues that have been deemed still valid as part of the Flutter Tools issue cleanup initiative.triaged-toolTriaged by Flutter Tool teamTriaged by Flutter Tool team
Description
(This may well apply to the other desktop platform as well; I haven't tried them, but a lot of the flutter
code to run desktop apps is similar across platforms.)
STR:
- Check out flutter/packages and cd to
packages/video_player/video_player/example
- Run
flutter test -d macos integration_test/controller_swap_test.dart
- Run
flutter test -d macos integration_test/video_player_test.dart
- Run
flutter test -d macos integration_test/
Steps 2 and 3 work fine. Step 4 however, which should have essentially the same effect as 2+3 (those are the two test files in that directory), runs one set of tests—the app visibly launches, then quits—then when it tries to run the second launches the app but doesn't run tests, and instead logs:
TestDeviceException(Unable to start the app on the device.)
package:flutter_tools/src/test/integration_test_device.dart 63:7 IntegrationTestTestDevice.start
Bad state: Cannot add new events after calling close
dart:async/broadcast_stream_controller.dart 243:24 _BroadcastStreamController.add
dart:async/zone.dart 1407:47 _rootRunUnary
dart:async/zone.dart 1308:19 _CustomZone.runUnary
dart:async/zone.dart 1217:7 _CustomZone.runUnaryGuarded
dart:async/stream_impl.dart 339:11 _BufferingStreamSubscription._sendData
dart:async/stream_impl.dart 271:7 _BufferingStreamSubscription._add
dart:async/stream_controller.dart 784:19 _SyncStreamControllerDispatch._sendData
dart:async/stream_controller.dart 658:7 _StreamController._add
dart:async/stream_controller.dart 606:5 _StreamController.add
dart:io-patch/socket_patch.dart 2447:41 _Socket._onData
dart:async/zone.dart 1415:13 _rootRunUnary
dart:async/zone.dart 1308:19 _CustomZone.runUnary
dart:async/zone.dart 1217:7 _CustomZone.runUnaryGuarded
dart:async/stream_impl.dart 339:11 _BufferingStreamSubscription._sendData
dart:async/stream_impl.dart 271:7 _BufferingStreamSubscription._add
dart:async/stream_controller.dart 784:19 _SyncStreamControllerDispatch._sendData
dart:async/stream_controller.dart 658:7 _StreamController._add
dart:async/stream_controller.dart 606:5 _StreamController.add
dart:io-patch/socket_patch.dart 1936:33 new _RawSocket.<fn>
dart:io-patch/socket_patch.dart 1379:14 _NativeSocket.issueReadEvent.issue
dart:async/schedule_microtask.dart 40:21 _microtaskLoop
dart:async/schedule_microtask.dart 49:5 _startMicrotaskLoop
dart:isolate-patch/isolate_patch.dart 118:13 _runPendingImmediateCallback
dart:isolate-patch/isolate_patch.dart 185:5 _RawReceivePort._handleMessage
and then sits there doing nothing with the app still open.
It looks like something about the flutter test
logic for desktop is trying to re-use a stream when it does subsequent launches.
Maksimka101, f69, lamkr, paul-doherty, jeanplevesque and 4 moreMaksimka101 and jigar-f
Metadata
Metadata
Assignees
Labels
P2Important issues not at the top of the work listImportant issues not at the top of the work lista: desktopRunning on desktopRunning on desktopa: tests"flutter test", flutter_test, or one of our tests"flutter test", flutter_test, or one of our testsplatform-linuxBuilding on or for Linux specificallyBuilding on or for Linux specificallyplatform-macBuilding on or for macOS specificallyBuilding on or for macOS specificallyteam-toolOwned by Flutter Tool teamOwned by Flutter Tool teamtoolAffects the "flutter" command-line tool. See also t: labels.Affects the "flutter" command-line tool. See also t: labels.tool-still-validIssues that have been deemed still valid as part of the Flutter Tools issue cleanup initiative.Issues that have been deemed still valid as part of the Flutter Tools issue cleanup initiative.triaged-toolTriaged by Flutter Tool teamTriaged by Flutter Tool team