aboutsummaryrefslogtreecommitdiff
path: root/automated/android/multinode/remote-adb-devices-smoke-test.yaml
blob: 838b866f1cec6f212ae94a2bcf8c613daa17189a (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
metadata:
    name: remote-adb-devices-smoke-test
    format: "Lava-Test-Shell Test Definition 1.0"
    description: "Smoke test demonstrating access to adb devices over TCP/IP."
    maintainer:
        - karsten@fairphone.com
        - softwareteam@fairphone.com
    os:
        - debian
        - ubuntu
    devices:
        - lxc
    scope:
        - functional

params:
    DEVICE_WORKER_MAPPING_FILE: "/tmp/deviceWorkerMapping"

run:
    steps:
        - device_worker_mapping="$(cat "${DEVICE_WORKER_MAPPING_FILE}")"
        - |
            for device_to_worker in ${device_worker_mapping}; do
              device="$(echo ${device_to_worker} | cut -d';' -f1)"
              echo "${device}: $(adb -s "${device}" shell service call iphonesubinfo 1 | \
                grep -oE '(\.[0-9])|([0-9]\.)' | grep -oE '[0-9]' | tr -d '\n')"
            done