Here I build a vts test environment both on ubuntu 16.04 and windows 10. I have installed the python's packages and build vts source in the AOSP according to the website "https://codelabs.developers.google.com/codelabs/android-vts/#1".

My adb version is :

Android Debug Bridge version 1.0.41
Version 29.0.2-5738569

Java version is:

java version "1.8.0_241"
Java(TM) SE Runtime Environment (build 1.8.0_241-b07)
Java HotSpot(TM) 64-Bit Server VM (build 25.241-b07, mixed mode)

Python version is:

Python 2.7.17

But when I try the command run vts -m VtsHalNeuralnetworksV1_0Target on the console after entering the vts-tradefed environment, the logs show it just couldn't find my android device, which are as below.

It detects my android device 10.190.0.22:5555 when first stepping into the vts-tradefed environment, but when running vts module, the manager couldn't find available device.

user@AIRD01-SZ:~/android_4.9srccode/android$ vts-tradefed
Android Vendor Test Suite 9.0_R5 (eng.hayley.20200226.150234)
Use "help" or "help all" to get more information on running commands.
03-02 15:00:29 I/DeviceManager: Detected new device 10.190.0.22:5555
vts-tf >
vts-tf > run vts -m VtsHalNeuralnetworksV1_0Target
03-02 15:00:47 I/TestInvocation: Starting invocation for 'vts' with '[ DeviceBuildInfo{bid=eng.hayley.20200226.150234, serial=10.190.0.22:5555} on device '10.190.0.22:5555']
03-02 15:00:47 D/ResultReporter: Initializing result directory
...
...
...
03-02 15:01:31 I/VtsFilePusher: Copying from /media/baitaochen/56f995bb-e300-4bbd-bf63-05bed0458739/hayley/android_4.9srccode/android/out/host/linux-x86/vts/android-vts/testcases/DATA/lib64/libvts_multidevice_proto.so
03-02 15:01:31 E/VtsVendorConfigFileUtil: Vendor test config file /config/vts-tradefed-vendor-config-prod.json does not exist
03-02 15:01:50 E/VtsMultiDeviceTest: Device 10.190.0.22:5555 not available.
03-02 15:01:50 E/TestInvocation: Unexpected exception when running invocation: java.lang.RuntimeException: Failed to get device information
03-02 15:01:50 E/TestInvocation: Failed to get device information
java.lang.RuntimeException: Failed to get device information
    at com.android.tradefed.testtype.VtsMultiDeviceTest.generateJsonDeviceItem(VtsMultiDeviceTest.java:586)
    at com.android.tradefed.testtype.VtsMultiDeviceTest.updateVtsRunnerTestConfig(VtsMultiDeviceTest.java:742)
    at com.android.tradefed.testtype.VtsMultiDeviceTest.doRunTest(VtsMultiDeviceTest.java:1121)
    at com.android.tradefed.testtype.VtsMultiDeviceTest.run(VtsMultiDeviceTest.java:640)
    at com.android.compatibility.common.tradefed.testtype.ModuleDef.run(ModuleDef.java:263)
    at com.android.compatibility.common.tradefed.testtype.ModuleDefMultiDevice.run(ModuleDefMultiDevice.java:143)
    at com.android.compatibility.common.tradefed.testtype.CompatibilityTest.run(CompatibilityTest.java:491)
    at com.android.tradefed.invoker.InvocationExecution.runTests(InvocationExecution.java:384)
    at com.android.tradefed.invoker.TestInvocation.prepareAndRun(TestInvocation.java:358)
    at com.android.tradefed.invoker.TestInvocation.performInvocation(TestInvocation.java:205)
    at com.android.tradefed.invoker.TestInvocation.invoke(TestInvocation.java:667)
    at com.android.tradefed.command.CommandScheduler$InvocationThread.run(CommandScheduler.java:566)
0

There are 0 best solutions below