blob: 4e104ded08d4fd3d684e3521cd5255d0bd2c18e4 [file] [log] [blame] [view]
David Dorwinfe186dd2022-05-20 18:35:131# Deploying content_shell and running web_tests on Fuchsia
2
3[TOC]
Chong Gu4749ec12021-02-17 01:41:064
5General instruction on running and debugging web_tests can be found
6[here](../testing/web_tests.md).
7
Chong Gu70ee43a12022-12-08 22:57:378Unlike on other platforms, where tests are directly invoked via the
9[blink test script](third_party/blink/tools/blinkpy/web_tests/run_web_tests.py),
10Fuchsia layers on top [its own test script] (../../build/fuchsia/test/run_test.py),
11which handles preparation such as installing the content_shell binary.
12
Chong Gu4749ec12021-02-17 01:41:0613Currently, only
An Sung65d9eab2023-07-26 01:38:4314[a small subset of web tests](../../third_party/blink/web_tests/TestLists/Default.txt)
Chong Gu70ee43a12022-12-08 22:57:3715can be run on Fuchsia. Build the target `blink_web_tests` first before running any
Chong Gu4749ec12021-02-17 01:41:0616of the commands below:
17
18## Hermetic emulation
19
20The test script brings up an emulator, runs the tests on it, and shuts the
21emulator down when finished.
22```bash
Chong Gu70ee43a12022-12-08 22:57:3723$ <output-dir>/bin/run_blink_web_tests
Chong Gu4749ec12021-02-17 01:41:0624```
25
26## Run on an physical device.
27
Chong Gu4749ec12021-02-17 01:41:0628```bash
Chong Gu70ee43a12022-12-08 22:57:3729$ <output-dir>/bin/run_blink_web_tests --target-id=<device-target-id>
Weizhong Xiaa33c6162022-05-03 02:11:2730```