Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Could flutter_test replace integration_test #148105

Open
matanlurey opened this issue May 10, 2024 · 1 comment
Open

Could flutter_test replace integration_test #148105

matanlurey opened this issue May 10, 2024 · 1 comment
Labels
a: tests "flutter test", flutter_test, or one of our tests c: proposal A detailed proposal for a change to Flutter f: integration_test The flutter/packages/integration_test plugin P3 Issues that are less important to the Flutter project team-framework Owned by Framework team triaged-framework Triaged by Framework team

Comments

@matanlurey
Copy link
Contributor

matanlurey commented May 10, 2024

@goderbauer @jonahwilliams @johnmccutchan and @matanlurey met today to discuss Flutter testing.

One of the topics that came up, but we don't plan to act on in the near term, is the differences between flutter_test and integration_test: both of them run in the same process (and isolate) of the running app, compared to an external test through flutter_driver, and what would it take for flutter_test to just subsume integration_test.

A non-exhaustive list might include:

  • flutter_test would need to formally support running on a device1
  • Plugins and platform views would need to be enabled (versus be stubs)
  • Test results would need to be reported1
  • Re-building something like an APK continuously sucks when iterating, so supporting something like hot restart

The general feel is that most of these changes are tooling related, but of course devil is in the details.

It's also worth mentioning this effort would have to come after we decide that flutter_driver should be the "external" testing story (right now both flutter_driver and integration_test attempt to be our external testing story).

Footnotes

  1. It works today if you run flutter run test/path_to_test.dart but there are no test results reported 2

@matanlurey matanlurey added a: tests "flutter test", flutter_test, or one of our tests c: proposal A detailed proposal for a change to Flutter f: integration_test The flutter/packages/integration_test plugin P3 Issues that are less important to the Flutter project team-framework Owned by Framework team labels May 10, 2024
@jonahwilliams
Copy link
Member

The fun thing is, 1 2 3 and 4 are all tooling issues that could be fixed without any changes to the test library.

@goderbauer goderbauer added the triaged-framework Triaged by Framework team label May 14, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
a: tests "flutter test", flutter_test, or one of our tests c: proposal A detailed proposal for a change to Flutter f: integration_test The flutter/packages/integration_test plugin P3 Issues that are less important to the Flutter project team-framework Owned by Framework team triaged-framework Triaged by Framework team
Projects
None yet
Development

No branches or pull requests

3 participants