Hi, guys,

 

I have a job like next:

 

- test:

    timeout:

      minutes: 10

    docker:

      image: terceiro/android-platform-tools

    definitions:

    - from: inline

      name: smoke-case

      path: inline/install-google-fastboot.yaml

      repository:

        metadata:

          format: Lava-Test Test Definition 1.0

          name: smoke-case-run

          description: Run smoke case

        run:

          steps:

            - env

            - sleep 10

            - adb devices

            - adb root

            - sleep 10

            - adb devices

           - lava-test-case get-release-version --shell adb shell getprop ro.vendor.build.fingerprint

 

It output as next:

 

+ sleep 10

+ adb devices

* daemon not running; starting now at tcp:5037

* daemon started successfully

List of devices attached

040c41d4d72d7393     device

+ adb root

+ sleep 10

+ adb devices

List of devices attached

+ lava-test-case get-release-version --shell adb shell getprop ro.vendor.build.fingerprint

<LAVA_SIGNAL_STARTTC get-release-version>

Received signal: <STARTTC> get-release-version

error: device '040c41d4d72d7393' not found

<LAVA_SIGNAL_ENDTC get-release-version>

Received signal: <ENDTC> get-release-version

<LAVA_SIGNAL_TESTCASE TEST_CASE_ID=get-release-version RESULT=fail>

Received signal: <TESTCASE> TEST_CASE_ID=get-release-version RESULT=fail

 

You know “adb root” will make usb bus change during run, so could docker shell handle this? How can I make above work? Thanks.