Daniel Erat | 599e024 | 2018-09-15 00:52:55 | [diff] [blame] | 1 | # Tast Test Dependencies (go/tast-deps) |
Daniel Erat | 5b270ed | 2018-05-02 05:37:54 | [diff] [blame] | 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 | |
Becca Hughes | 8247fde | 2018-11-09 18:50:03 | [diff] [blame] | 11 | * `android` - The ability to [run Android apps]. Any version of Android can be |
Eric Caruso | 6ca58ce | 2018-12-04 00:38:38 | [diff] [blame] | 12 | used. |
Becca Hughes | 8247fde | 2018-11-09 18:50:03 | [diff] [blame] | 13 | * `android_p` - The ability to [run Android apps] that require Android P or |
Eric Caruso | 6ca58ce | 2018-12-04 00:38:38 | [diff] [blame] | 14 | later. |
| 15 | * `aslr` - Address space layout randomization, which mitigates buffer-overflow |
| 16 | attacks, is functional (this is not true for builds with [AddressSanitizer] |
| 17 | instrumentation built in). |
Daniel Erat | 943de1b | 2018-07-03 17:32:16 | [diff] [blame] | 18 | * `audio_play` - The ability to play audio. |
| 19 | * `audio_record` - The ability to record audio. |
Daniel Erat | df04ea0 | 2018-09-19 21:31:24 | [diff] [blame] | 20 | * `autotest-capability:foo` - An [Autotest capability] named `foo`. See below. |
Keiichi Watanabe | c7acad0 | 2018-10-16 10:19:49 | [diff] [blame] | 21 | * `camera_720p` - The ability to capture video with frame size 1280x720. |
Daniel Erat | 5b270ed | 2018-05-02 05:37:54 | [diff] [blame] | 22 | * `chrome` - A Chrome process. |
Keiichi Watanabe | 7e0a96a | 2018-11-06 11:28:24 | [diff] [blame] | 23 | * `chrome_internal` - Features that are only available in official Chrome, |
| 24 | rather than Chromium. (e.g. proprietary codec like H.264) |
Daniel Erat | 5b270ed | 2018-05-02 05:37:54 | [diff] [blame] | 25 | * `chrome_login` - Implies `chrome` with the further requirement that user |
| 26 | login (i.e. using `session_manager` and `cryptohome`) is supported. |
Hidehiko Abe | c9c3413 | 2018-09-26 15:10:53 | [diff] [blame] | 27 | * `cups` - CUPS daemon. |
Shuhei Takahashi | dd13172 | 2018-08-01 06:53:21 | [diff] [blame] | 28 | * `display_backlight` - An internal display backlight. |
Daniel Erat | 92d132d | 2018-12-13 05:31:54 | [diff] [blame^] | 29 | * `gpu_sandboxing` - Chrome's GPU process is [sandboxed]. |
Luigi Semenzato | edde071 | 2018-11-14 18:26:46 | [diff] [blame] | 30 | * `memd` - [Memory stats collection daemon]. |
Andrew Moylan | e739f2e | 2018-09-20 22:34:53 | [diff] [blame] | 31 | * `ml_service` - ML Service daemon. |
Daniel Erat | 63de30d | 2018-11-20 00:48:34 | [diff] [blame] | 32 | * `no_android` - The inability to run Android apps. This is the opposite of |
| 33 | the `android` feature; DUTs will have exactly one of these two features. |
Daniel Erat | 9747888 | 2018-11-14 05:54:39 | [diff] [blame] | 34 | * `no_symlink_mount` - Symlink mounting is disabled via the |
| 35 | `CONFIG_SECURITY_CHROMIUMOS_NO_SYMLINK_MOUNT` kernel option. |
Daniel Erat | e758f64 | 2018-11-29 19:59:31 | [diff] [blame] | 36 | * `reboot` - The ability to reboot reliably during a remote test. |
Daniel Erat | 86c6437 | 2018-09-25 19:28:26 | [diff] [blame] | 37 | * `screenshot` - The [screenshot command] can save screenshots. |
Qijiang Fan | 7ced1b9 | 2018-09-07 04:08:16 | [diff] [blame] | 38 | * `selinux` - An SELinux-enabled board. All Android boards are |
| 39 | SELinux-enabled. |
Daniel Erat | 943de1b | 2018-07-03 17:32:16 | [diff] [blame] | 40 | * `tpm` - A [Trusted Platform Module] chip. |
Stephen Barber | e148256 | 2018-05-21 23:54:52 | [diff] [blame] | 41 | * `vm_host` - The ability to [run virtual machines]. |
Daniel Erat | 5b270ed | 2018-05-02 05:37:54 | [diff] [blame] | 42 | |
| 43 | Software features are composed from USE flags. [local_test_runner] lists boolean |
| 44 | expressions that are used to generate features; for example, an imaginary |
| 45 | feature named `hd_audio` with expression `cras && (audio_chipset_a || |
| 46 | audio_chipset_b) && !broken_headphone_jack` will be reported as available on |
| 47 | systems where the `cras` USE flag is set, either `audio_chipset_a` or |
| 48 | `audio_chipset_b` is set, and `broken_headphone_jack` is explicitly *not* set. |
| 49 | Before a new USE flag can be used in an expression, it must be added to `IUSE` |
| 50 | in the [tast-use-flags] package. |
| 51 | |
Daniel Erat | df04ea0 | 2018-09-19 21:31:24 | [diff] [blame] | 52 | The exception to the above are `autotest-capability:`-prefixed features, which |
| 53 | are added by the [autocaps package] as specified by YAML files in |
| 54 | `/usr/local/etc/autotest-capability`. This exists in order to support porting |
| 55 | existing Autotest-based video tests to Tast. Do not depend on capabilities from |
| 56 | outside of video tests. |
| 57 | |
Daniel Erat | 5b270ed | 2018-05-02 05:37:54 | [diff] [blame] | 58 | [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] | 59 | [run Android apps]: https://developer.android.com/topic/arc/ |
Eric Caruso | 6ca58ce | 2018-12-04 00:38:38 | [diff] [blame] | 60 | [AddressSanitizer]: https://github.com/google/sanitizers/wiki/AddressSanitizer |
Daniel Erat | df04ea0 | 2018-09-19 21:31:24 | [diff] [blame] | 61 | [Autotest capability]: https://chromium.googlesource.com/chromiumos/overlays/chromiumos-overlay/+/master/chromeos-base/autotest-capability-default/ |
Daniel Erat | 92d132d | 2018-12-13 05:31:54 | [diff] [blame^] | 62 | [sandboxed]: https://chromium.googlesource.com/chromium/src/+/HEAD/docs/linux_sandboxing.md |
Luigi Semenzato | edde071 | 2018-11-14 18:26:46 | [diff] [blame] | 63 | [Memory stats collection daemon]: https://chromium.googlesource.com/chromiumos/platform2/+/master/metrics/memd/ |
Daniel Erat | 86c6437 | 2018-09-25 19:28:26 | [diff] [blame] | 64 | [screenshot command]: https://chromium.googlesource.com/chromiumos/platform2/+/master/screenshot/ |
Daniel Erat | 943de1b | 2018-07-03 17:32:16 | [diff] [blame] | 65 | [Trusted Platform Module]: https://en.wikipedia.org/wiki/Trusted_Platform_Module |
Luigi Semenzato | edde071 | 2018-11-14 18:26:46 | [diff] [blame] | 66 | [run virtual machines]: https://chromium.googlesource.com/chromiumos/docs/+/master/containers_and_vms.md |
Daniel Erat | 5b270ed | 2018-05-02 05:37:54 | [diff] [blame] | 67 | [local_test_runner]: https://chromium.googlesource.com/chromiumos/platform/tast/+/master/src/chromiumos/cmd/local_test_runner/main.go |
| 68 | [tast-use-flags]: https://chromium.googlesource.com/chromiumos/overlays/chromiumos-overlay/+/master/chromeos-base/tast-use-flags/ |
Daniel Erat | df04ea0 | 2018-09-19 21:31:24 | [diff] [blame] | 69 | [autocaps package]: https://godoc.org/chromium.googlesource.com/chromiumos/platform/tast.git/src/chromiumos/tast/autocaps/ |