commit | bdfc4456d603b1e4b2cff034591a7ab50960be43 | [log] [tgz] |
---|---|---|
author | Yuexi Ma <yuexima@google.com> | Thu Dec 21 19:14:18 2017 -0800 |
committer | Yuexi Ma <yuexima@google.com> | Thu Dec 21 19:14:18 2017 -0800 |
tree | 13783937c0b2e5ea33abe9ce4e080f22e918406c | |
parent | 08e368e9c466a3e7fa98c8ee1e4290803d0b5ae4 [diff] |
Add owner to vts nbu Test: na Change-Id: I298294877ee5c790485bf2c2e633f47696a3c986
This suite includes tests that exercises Android connectivity APIs and verify device behaviors.
These tests simulate connectivity use cases critical to NBU market like peer-to-peer interactions.
We created these tests using tools from the open source project Mobly, if you want to learn more, see its Github page and tutorial.
The tests have two components, an agent apk running on the Android Device Under Test (DUT) and Python test scripts running on a computer to which the DUTs are connected via USB. The tests issue cmds to the agent on the device to trigger actions and read status, thus coordinating actions across multiple devices.
The tests by default write output to /tmp/logs
.
This section lists the components and steps required to create a setup to run these tests.
This is a zip file that you have downloaded.
The zip file includes:
android_snippet.apk
The two devices should be of the same model and build (identical fingerprint).
On each device:
>=26
.android_snippet.apk
with opition -g.Based on the two devices' serial numbers, we need to create a config file.
Create a plain text file config.yaml
in the following format, with the <>
blocks replaced with the information of your actual devices:
TestBeds: - Name: P2pTestBed Controllers: AndroidDevice: - serial: <DUT1 serial> - serial: <DUT2 serial>
We need the following packages:
To check your Python's version, use command $ python --version
.
In addition to those, we also need to install a few other tools:
$ sudo apt-get install python-setuptools python-pip $ pip install mobly
After all the tools are installed, connect the devices to the computer with USB cables and make sure they show up as "device" in the output of $ adb devices
First, you need to put the file config.yaml
in the same directory as the Python scripts. Then cd to that directory and run:
$ rm -rf /tmp/logs/ # Clear previous logs $ python xxx_test.py -c config.yaml
Execute all the *_test.py
files the same way. Once they all finish executing, all the logs will be collected in /tmp/logs/
. You can check the test results and debug info there.
Zip up the content of /tmp/logs/
and send it to your contact at Google.