这是indexloc提供的服务,不要输入任何密码
Skip to content

[devicelab] Refresh documentation #80064

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

Merged
merged 6 commits into from
Apr 14, 2021
Merged

Conversation

CaseyHillers
Copy link
Contributor

@CaseyHillers CaseyHillers commented Apr 8, 2021

Issues

Fixes #79972
#74660

Pre-launch Checklist

  • I read the [Contributor Guide] and followed the process outlined there for submitting PRs.
  • I read the [Tree Hygiene] wiki page, which explains my responsibilities.
  • I read and followed the [Flutter Style Guide], including [Features we expect every widget to implement].
  • I signed the [CLA].
  • I listed at least one issue that this PR fixes in the description above.
  • I updated/added relevant documentation (doc comments with ///).
  • I added new tests to check the change I am making or feature I am adding, or Hixie said the PR is test-exempt.
  • All existing and new tests are passing.

@flutter-dashboard flutter-dashboard bot added the c: contributor-productivity Team-specific productivity, code health, technical debt. label Apr 8, 2021
@google-cla google-cla bot added the cla: yes label Apr 8, 2021

This defaults to only running tests supported by your host device's platform
(`--match-host-platform`) and exiting after the first failure (`--exit`).
`TODO(chillers): Update to use .ci.yaml. https://github.com/flutter/flutter/issues/74660`

### Running specific tests
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

test_runner.dart currently does not support this. Should this be ported over or removed?

1. Add prod builder to [flutter/infra devicelab_config.star](https://github.com/flutter/infra/blob/master/config/devicelab_config.star)
- Example PR: https://github.com/flutter/infra/pull/401/files
- This will need to soak for 15 minutes after merged to propagate
- There are various lists for the different testbeds a test can run on
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

In flutter/cocoon, I plan to add a more robust testbed document listing what there is in the devicelab after we move from the luci-scheduler to the cocoon-scheduler

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What are these various lists?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

linux_tasks, linux_vm_tasks, mac_android_tasks, and mac_ios_tasks. I'd to formalize these testbeds in cocoon when we start using the cocoon-scheduler

for information on using the dashboards.

## How the DeviceLab runs tasks
## Table of Contents
* [How the DeviceLab runs tests](#how-the-devicelab-runs-tasks)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

#how-the-devicelab-runs-tests

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice catch!


This defaults to only running tests supported by your host device's platform
(`--match-host-platform`) and exiting after the first failure (`--exit`).
`TODO(chillers): Update to use .ci.yaml. https://github.com/flutter/flutter/issues/74660`
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

May as well leave off this section until it's done, or you'll get pinged about it in 10 years.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks, removed


1. Add prod builder to [flutter/infra devicelab_config.star](https://github.com/flutter/infra/blob/master/config/devicelab_config.star)
- Example PR: https://github.com/flutter/infra/pull/401/files
- This will need to soak for 15 minutes after merged to propagate
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Maybe instructions for how you can tell it's ready?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done - Check LUCI console for devicelab tasks


Flutter's DeviceLab does not currently have capacity to run tests against physical devices in presubmit.

Host only tests are okay. First add them to [continuous-integration](#adding-tests-to-ci), and after marked blocking add them to presubmit.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Whoa, I didn't know this, neat.

In general I think we want to discourage these kinds of tests except in rare situations. See #65790.

Maybe we can encourage people to consider adding a flutter_tools test instead?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If that's the approach, i'll give the advice of adding them as flutter_tools tests. Is there documentation I should refer to?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No, I think there are good use cases for adding host tests the devicelab, (for example the devicelab machines have the Apple development provisioning profiles set up, so #77428 for example can't been a flutter_tools test), and maybe some more desktop test reasons.

Maybe what you had before, but with a caveat like:

Also consider creating your integration test in packages/flutter_tools/test/integration.shard to avoid using limited DeviceLab scheduling resources. Example: https://github.com/flutter/flutter/pull/73577/files"

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Great! Added

1. Add prod builder to [flutter/infra devicelab_config.star](https://github.com/flutter/infra/blob/master/config/devicelab_config.star)
- Example PR: https://github.com/flutter/infra/pull/401/files
- This will need to soak for 15 minutes after merged to propagate
- There are various lists for the different testbeds a test can run on
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What are these various lists?

Copy link
Contributor

@keyonghan keyonghan left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM with nit.
Leave approval to jmagman@


## Adding tests to presubmit

Flutter's DeviceLab does not currently have capacity to run tests against physical devices in presubmit.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I liked your previous instructions to add to presubmit, I'm going to use them now that I know this feature exists!

stage: {STAGE}
required_agent_capabilities: {CAPABILITIES}
```
Host only tests should be added to `flutter_tools`.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It sounds like the following instructions are to add it to flutter_tools but the rest of this section is how to not add it to flutter_tools...

How about removing this sentence and add at the bottom of the section something like:
"Note that DeviceLab tests should generally require a tethered device. If you are adding host-only tests, considering adding your test to packages/flutter_tools/test/integration.shard ."

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks, updated.

@CaseyHillers
Copy link
Contributor Author

Friendly ping

Copy link
Member

@jmagman jmagman left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, thanks @CaseyHillers!

@fluttergithubbot fluttergithubbot merged commit d55b8c0 into master Apr 14, 2021
@fluttergithubbot fluttergithubbot deleted the CaseyHillers-patch-1 branch April 14, 2021 20:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
c: contributor-productivity Team-specific productivity, code health, technical debt. team-infra Owned by Infrastructure team
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Update devicelab readme doc
5 participants