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

Enable more tests in flutter/packages #102851

Closed
stuartmorgan opened this issue Apr 29, 2022 · 3 comments · Fixed by flutter/packages#1726
Closed

Enable more tests in flutter/packages #102851

stuartmorgan opened this issue Apr 29, 2022 · 3 comments · Fixed by flutter/packages#1726
Assignees
Labels
a: tests "flutter test", flutter_test, or one of our tests P1 High-priority issues at the top of the work list package flutter/packages repository. See also p: labels. team Infra upgrades, team productivity, code health, technical debt. See also team: labels.

Comments

@stuartmorgan
Copy link
Contributor

Apparently we have some flutter driver tests in the repo; we don't currently run drive-examples on any platform. We also don't build examples on web or any of the desktop platforms.

We should add all of that to the CI so that anything that's added to the repo actually runs.

(I'll also audit for other differences; I happened to find today that readme-check was never turned on, and there may be other new checks that haven't been enabled for the packages repo.)

@stuartmorgan stuartmorgan added a: tests "flutter test", flutter_test, or one of our tests team Infra upgrades, team productivity, code health, technical debt. See also team: labels. package flutter/packages repository. See also p: labels. P1 High-priority issues at the top of the work list labels Apr 29, 2022
@stuartmorgan stuartmorgan self-assigned this Apr 29, 2022
@stuartmorgan
Copy link
Contributor Author

It turns out drive-examples skips anything that's not a plugin, so I'll need to change that in the tool. I'll also need to adjust the logic slightly so that it's fail-if-missing only for plugins, and skip-if-missing for packages, since unlike plugins the expectation isn't that packages need to have driver tests.

@stuartmorgan
Copy link
Contributor Author

We should add all of that to the CI so that anything that's added to the repo actually runs.

For drive, I'm only going to enable web at the moment. We may want to enable at least all of the host platforms at some point, but since setup is not trivial on Android or Linux, and we currently only need web, I'm just going to start with web and we can add other categories (host, mobile device) on demand.

stuartmorgan added a commit to stuartmorgan/packages that referenced this issue May 3, 2022
This brings the Cirrus configuration more in line with flutter/plugins,
to reduce testing diffs between the two repositories:
- Updates naming and grouping comments to match flutter/plugins to make
  them easier to compare.
- Enables building examples on all platforms. This was being done for
  Android, and iOS, and Windows, but not Linux, macOS, or web, which
  wasn't an intentional mismatch.
- Enables 'flutter drive' tests for web.
  - Does not enable them for other platforms as currently there is no
    need for them, and setup is non-trivial on some platforms (FTL
    secrets for Android, new Dockerfile dependencies for Linux).
- Enables native unit tests for all platforms. (In practice this is a
  no-op at the momement, but it's a very fast no-op that doesn't
  require extra setup.)

Rolls repo tooling forward to pick up support for `drive-examples` in
non-plugin packages, and for running Dart unit tests in examples.

Fixes flutter/flutter#102851
@github-actions
Copy link

This thread has been automatically locked since there has not been any recent activity after it was closed. If you are still experiencing a similar issue, please open a new bug, including the output of flutter doctor -v and a minimal reproduction of the issue.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators May 18, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
a: tests "flutter test", flutter_test, or one of our tests P1 High-priority issues at the top of the work list package flutter/packages repository. See also p: labels. team Infra upgrades, team productivity, code health, technical debt. See also team: labels.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant