flutter/packages/flutter_tools/test
Andrew Kolos c206a47505
[tool] make testUsingContext provide a Stdio (with hasTerminal unset) override by default (#151357)
While exploring https://github.com/flutter/flutter/issues/107607, I noticed that flutter_tools test results change based on whether `dart test` is run from a terminal or from a process (such as a Dart program). I also ran into this while writing tests for https://github.com/flutter/flutter/pull/150667.

This is due to tests that rely on the global `Stdio` instance, on which the `hasTerminal` property depends on whether the tool is being invoked from a terminal.

Ideally, `testUsingContext` would require any tests that depend on `globals.stdio` to define an override for `Stdio`, but this is not the case. Until a solution to this more general problem is figured out, I think we should have `testUsingContext` always provide a `Stdio` override by default.
2024-07-08 23:47:31 +00:00
..
android_preview_integration.shard Reverts "Upgrade template Gradle, App AGP, Module AGP, and Kotlin versions, and tests (#150969)" (#151147) 2024-07-01 23:31:26 +00:00
commands.shard [tool] make testUsingContext provide a Stdio (with hasTerminal unset) override by default (#151357) 2024-07-08 23:47:31 +00:00
data make asset_test.dart tests not dependent on context (#141331) 2024-01-11 18:08:07 +00:00
general.shard Fix invalid URL suggestion for gradle incompatability (#150999) 2024-07-03 20:38:11 +00:00
host_cross_arch.shard Switch to more reliable flutter.dev link destinations in the tool (#150587) 2024-06-26 23:30:39 +00:00
integration.shard [flutter_tools] Update the mapping for the Dart SDK internal URI (#151170) 2024-07-02 22:56:17 +00:00
src [tool] make testUsingContext provide a Stdio (with hasTerminal unset) override by default (#151357) 2024-07-08 23:47:31 +00:00
web.shard Handle a SocketException thrown when sending the browser close command to Chrome (#151197) 2024-07-03 13:23:20 +00:00