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

Document how to install the CA cert on Android #10060

Merged
merged 1 commit into from
Mar 16, 2018
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
24 changes: 21 additions & 3 deletions docs/_running-tests/chrome_android.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,10 @@ To run WPT on Chrome on an Android device, some additional set up is required.
First of all, as usual Android development, we need to have `adb` and be able to
connect to the device.

Furthermore, until we find a better way, we need to root the Android device and
update the /etc/hosts file to include
## Hosts

Until we find a better way, we need to root the Android device and update the
/etc/hosts file to include

```
127.0.0.1 web-platform.test
Expand All @@ -20,7 +22,23 @@ update the /etc/hosts file to include
0.0.0.0 nonexistent-origin.web-platform.test
```

After this, we may run wpt with the `chrome_android` product
## CA certificate

In order to run HTTPS tests, we need to add
[WPT's CA](https://github.com/w3c/web-platform-tests/blob/master/tools/certs/cacert.pem)
to the phone. First, convert the certificate from PEM to CRT:

```
openssl x509 -outform der -in tools/certs/cacert.pem -out cacert.crt
```

Then copy `cacert.crt` to your phone's external storage (preferably to
Downloads/ as it'll be easier to find). Open Settings -> Security & location ->
Encryption & credentials -> Install from storage. Find and install `cacert.crt`.
(The setting entries might be slightly different based your Android version.)


Finally, we may run wpt with the `chrome_android` product

```
./wpt run chrome_android [test_list]
Expand Down