• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1# Run a VTS test directly
2
3First of all, if you have not done [VTS setup](../setup/index.md), that is required here.
4
5## Download required Python packages to local host
6
7`$ . test/vts/script/pypi-packages-local.sh`
8
9## Build Binaries
10
11`$ cd test/vts/script`
12
13`$ ./create-image.sh <build target>-userdebug`
14
15or
16
17`$ ./create-image.sh aosp_salifish-userdebug`
18
19## Copy Binaries
20
21`$ ./setup-local.sh <device name>`
22
23or
24
25`$ ./setup-local.sh sailfish`
26
27## Run a test direclty
28
29`$ PYTHONPATH=$PYTHONPATH:.. python -m vts.testcases.<test py package path> $ANDROID_BUILD_TOP/test/vts/testcases/<path to its config file>`
30
31For example, for SampleShellTest, please run:
32
33`PYTHONPATH=$PYTHONPATH:.. python -m vts.testcases.host.shell.SampleShellTest $ANDROID_BUILD_TOP/test/vts/testcases/host/shell/SampleShellTest.config`
34
35More examples are in `test/vts/script/run-local.sh`.
36
37## Additional Step for LTP and Linux-Kselftest
38
39Add `'data_file_path' : '<your android build top>/out/host/linux-x86/vts/android-vts/testcases'`
40to your config file (e.g., `VtsKernelLtpStaging.config`).
41
42## Add a new test
43
44In order to add a new test, the following two files needed to be extended.
45
46`test/vts/create-image.sh`
47
48`test/vts/setup-local.sh`
49
50Optionally, the command used to add a new test can be also added to:
51
52`test/vts/run-local.sh`
53