Repository navigation
test(dart): stub the Flutter device probes in the default-io factory case (#1101) - #1104
Open
debugmcpdev wants to merge 1 commit into
Open
debugmcpdev wants to merge 1 commit into
debugmcpdev wants to merge 1 commit into
Conversation
…case (#1101) The "finds a DART_SDK on disk" case runs the real locator on purpose and stubbed probeDartVersion and probeFlutterVersion because they would spawn the SDK — but not probeFlutterDevices or probeFlutterEmulators. Deleting FLUTTER_ROOT does not hide a Flutter the locator finds through `which` or a known install dir, so on a developer machine with Flutter installed describeToolchain ran a real `flutter devices --machine` and `flutter emulators` with the default budget: a cold Flutter tool start plus device discovery, seconds past the case's budget (seen by a contributor on macOS arm64 while running the unit suite for #1099, identical on main). CI never saw it because its runners have no Flutter. All four probes are stubbed now; the case keeps what it is for — the real file system and `which` under an explicit DART_SDK. Closes #1101. Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Codecov Report✅ All modified and coverable lines are covered by tests. 📢 Thoughts on this report? Let us know! |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Closes #1101.
packages/adapter-dart/tests/unit/dart-adapter-factory.default-io.test.ts, case "finds a DART_SDK on disk through the real file system": it runs the real locator on purpose and stubbedprobeDartVersionandprobeFlutterVersion("they would spawn the SDK"), but notprobeFlutterDevicesorprobeFlutterEmulators. DeletingFLUTTER_ROOTdoes not hide a Flutter the locator finds throughwhichor a known install directory, so on a machine with Flutter installeddescribeToolchainran a realflutter devices --machineandflutter emulatorswith the default budget — a cold Flutter tool start plus device discovery, seconds past the case budget. Seen by a contributor on macOS arm64 while running the unit suite for #1099, identical onmain; CI never saw it because its runners have no Flutter.Two stub lines (
async () => nullfor both device probes) and the header sentence now says all four probes are stubbed and why. The case keeps what it is for: the real file system andwhichunder an explicitDART_SDK.Test-only, no behaviour change:
no-changelog.🤖 Generated with Claude Code