flutter/packages/flutter_tools/test
Matan Lurey 78cfc1ae9b
Plugin.isDevDependency if exclusively in dev_dependencies (#157462)
Work towards https://github.com/flutter/flutter/issues/56591.

I explicitly want an LGTM from @andrewkolos @jmagman @jonahwilliams before merging.

---

After this PR, `<Plugin>.isDevDependency` is resolved based on the following logic, IFF:

- The plugin comes from a package _A_ listed in the app's package's `dev_dependencies: ...`
- The package _A_ is not a normal dependency of any transitive non-dev dependency of the app

See [`compute_dev_dependencies_test.dart`](51676093a3/packages/flutter_tools/test/general.shard/compute_dev_dependencies_test.dart) for probably the best specification of this behavior.

We (still) do not write the property to disk (i.e. it never makes it to `.flutter-plugins-dependencies`), so there is no impact to build artifacts at this time; that would come in a follow-up PR (and then follow-up follow-up PRs for the various build systems in both Gradle and Xcode to actually use that value to omit dependencies).

Some tests had to be updated; for the most part it was updating the default `ProcessManager` because a call to `dart pub deps --json` is now made in code that computes what plugins are available, but there should be no change in behavior.

_/cc @jonasfj @sigurdm for FYI only (we talked on an internal thread about this; see https://github.com/dart-lang/sdk/issues/56968)._

_/cc @camsim99 @cbracken @johnmccutchan for visibility on the change._
2024-11-07 18:09:22 +00:00
..
android_java11_integration.shard Reland "Update template/test compileSdk, targetSdk, ndk versions" (#153795) 2024-08-21 18:27:00 +00:00
android_preview_integration.shard Use Gradle KTS in new Android app projects by default (2nd try) (#157195) 2024-10-22 17:28:31 +00:00
commands.shard Plugin.isDevDependency if exclusively in dev_dependencies (#157462) 2024-11-07 18:09:22 +00:00
data make asset_test.dart tests not dependent on context (#141331) 2024-01-11 18:08:07 +00:00
general.shard Plugin.isDevDependency if exclusively in dev_dependencies (#157462) 2024-11-07 18:09:22 +00:00
host_cross_arch.shard Test alternate correct macOS framework xcprivacy manifest location (#157318) 2024-10-22 19:41:14 +00:00
integration.shard Fix flakiness in hot_reload_test.dart (#158271) 2024-11-06 22:14:19 +00:00
src Reland1: "Revert "Add and plumb useImplicitPubspecResolution across flutter_tools."" (#158126) 2024-11-05 08:49:42 -08:00
web.shard Reland1: "Revert "Add and plumb useImplicitPubspecResolution across flutter_tools."" (#158126) 2024-11-05 08:49:42 -08:00