How to run vts for specific device when multiple devices are connected

897 Views Asked by At

I am having a AOSP VTS (version 9) setup which works fine on Linux when one device is connected. However, when two devices are connected to the computer, is there an option that let us choose the device on which the VTS should be run?

I notice that "I/DeviceManager: Detected new device " comes up when the vts-tradefed application is being run.

VTS should be run only on specific device and not on both the devices. We could assume that the other device is performing some other operation and should not be disturbed. Is this possible?

Thanks in advance

1

There are 1 best solutions below

3
On

VTS help:

vts-tf > help run
r(?:un)? help:
    command <config> [options]        Run the specified command
    <config> [options]                Shortcut for the above: run specified command
    cmdfile <cmdfile.txt>             Run the specified commandfile
    commandAndExit <config> [options] Run the specified command, and run 'exit -c' immediately afterward
    cmdfileAndExit <cmdfile.txt>      Run the specified commandfile, and run 'exit -c' immediately afterward

    ----- Vendor Test Suite specific options ----- 
    <plan> --module/-m <module>       Run a test module
    <plan> --module/-m <module> --test/-t <test_name>    Run a specific test from the module. Test name can be <package>.<class>, <package>.<class>#<method> or <native_binary_name>
        Available Options:
            --serial/-s <device_id>: The device to run the test on
            --abi/-a <abi>         : The ABI to run the test against
            --logcat-on-failure    : Capture logcat when a test fails
            --bugreport-on-failure : Capture a bugreport when a test fails
            --screenshot-on-failure: Capture a screenshot when a test fails
            --shard-count <shards>: Shards a run into the given number of independent chunks, to run on multiple devices in parallel.
     ----- In order to retry a previous run -----
    retry --retry <session id to retry> [--retry-type <FAILED | NOT_EXECUTED>]
        Without --retry-type, retry will run both FAIL and NOT_EXECUTED tests

The device to run the test on can be specified with --serial