Daniel Erat | 5b270ed | 2018-05-02 05:37:54 | [diff] [blame] | 1 | # Tast Test Dependencies |
| 2 | |
| 3 | A test may specify software features that must be supported by the DUT's system |
| 4 | image in order for the test to run successfully. If one or more features aren't |
| 5 | supported by the DUT, the test will (usually) be skipped. See the `tast` |
| 6 | command's `-checktestdeps` flag to control this behavior. |
| 7 | |
| 8 | Tests specify dependencies through the `SoftwareDeps` field in [testing.Test]. |
| 9 | The following software features are defined: |
| 10 | |
Daniel Erat | d8c4c4c | 2018-05-08 00:35:12 | [diff] [blame] | 11 | * `android` - The ability to [run Android apps]. |
Daniel Erat | 943de1b | 2018-07-03 17:32:16 | [diff] [blame] | 12 | * `audio_play` - The ability to play audio. |
| 13 | * `audio_record` - The ability to record audio. |
Daniel Erat | 5b270ed | 2018-05-02 05:37:54 | [diff] [blame] | 14 | * `chrome` - A Chrome process. |
| 15 | * `chrome_login` - Implies `chrome` with the further requirement that user |
| 16 | login (i.e. using `session_manager` and `cryptohome`) is supported. |
Shuhei Takahashi | dd13172 | 2018-08-01 06:53:21 | [diff] [blame] | 17 | * `display_backlight` - An internal display backlight. |
Daniel Erat | 943de1b | 2018-07-03 17:32:16 | [diff] [blame] | 18 | * `tpm` - A [Trusted Platform Module] chip. |
Stephen Barber | e148256 | 2018-05-21 23:54:52 | [diff] [blame] | 19 | * `vm_host` - The ability to [run virtual machines]. |
Daniel Erat | 5b270ed | 2018-05-02 05:37:54 | [diff] [blame] | 20 | |
| 21 | Software features are composed from USE flags. [local_test_runner] lists boolean |
| 22 | expressions that are used to generate features; for example, an imaginary |
| 23 | feature named `hd_audio` with expression `cras && (audio_chipset_a || |
| 24 | audio_chipset_b) && !broken_headphone_jack` will be reported as available on |
| 25 | systems where the `cras` USE flag is set, either `audio_chipset_a` or |
| 26 | `audio_chipset_b` is set, and `broken_headphone_jack` is explicitly *not* set. |
| 27 | Before a new USE flag can be used in an expression, it must be added to `IUSE` |
| 28 | in the [tast-use-flags] package. |
| 29 | |
| 30 | [testing.Test]: https://godoc.org/chromium.googlesource.com/chromiumos/platform/tast.git/src/chromiumos/tast/testing#Test |
Daniel Erat | d8c4c4c | 2018-05-08 00:35:12 | [diff] [blame] | 31 | [run Android apps]: https://developer.android.com/topic/arc/ |
Stephen Barber | e148256 | 2018-05-21 23:54:52 | [diff] [blame] | 32 | [run virtual machines]: https://chromium.googlesource.com/chromiumos/docs/+/master/containers_and_vms.md |
Daniel Erat | 943de1b | 2018-07-03 17:32:16 | [diff] [blame] | 33 | [Trusted Platform Module]: https://en.wikipedia.org/wiki/Trusted_Platform_Module |
Daniel Erat | 5b270ed | 2018-05-02 05:37:54 | [diff] [blame] | 34 | [local_test_runner]: https://chromium.googlesource.com/chromiumos/platform/tast/+/master/src/chromiumos/cmd/local_test_runner/main.go |
| 35 | [tast-use-flags]: https://chromium.googlesource.com/chromiumos/overlays/chromiumos-overlay/+/master/chromeos-base/tast-use-flags/ |