NordicSemiconductor / Android-nRF-Connect

Documentation and issue tracker for nRF Connect for Android.
1.32k stars 312 forks source link

Cannot use key-value pairs for TIMEOUT parameter #195

Open yoshiharu-oke opened 1 year ago

yoshiharu-oke commented 1 year ago

Describe the bug Cannot use key-value pairs for TIMEOUT parameter.

To Reproduce Steps to reproduce the behavior:

  1. Make scan.xml(see below)

    <?xml version="1.0" encoding="UTF-8"?>
    <test-suite>
    <set name="TIMEOUT_MS" value="30000" />
    <test id="try_scan">
        <scan timeout="${TIMEOUT_MS}"/>
    </test>
    <run-test ref="try_scan" />
    </test-suite>
  2. Run the test

    % adb push scan.xml /sdcard/Android/data/no.nordicsemi.android.mcp/files/Test/
    % adb -d shell am startservice -a no.nordicsemi.android.action.START_TEST -e no.nordicsemi.android.test.extra.EXTRA_FILE_PATH "/sdcard/Android/data/no.nordicsemi.android.mcp/files/Test/scan.xml"
  3. Show scan_result.txt

    
    % adb shell cat /sdcard/Android/data/no.nordicsemi.android.mcp/files/Test/scan_result.txt
    29-06-2023 20:06:33
    Version: 4.26.1
    Device: SC-42A, Android version: 11 (RP1A.200720.012.SC42AOMU1BVH1)

Parsing test suite...FAIL For input string: "${TIMEOUT_MS}"%



**Expected behavior**
Key-value pair can be used for TIMEOUT parameter

**Versions (please complete the following information):**
Occurs on at least two models.

> Version: 4.26.1
> Device: FIG-LA1, Android version: 8.0.0 (FIG-LA1 8.0.0.139(C635)) 

> Version: 4.26.1
> Device: SC-42A, Android version: 11 (RP1A.200720.012.SC42AOMU1BVH1)