summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorhathach <[email protected]>2024-08-13 14:35:42 +0700
committerhathach <[email protected]>2024-08-13 14:35:42 +0700
commit5f8599f6d44c1b1741f3e0edf0d342720c0c17d8 (patch)
tree3f81fee0f2c8237f131ab2633bae1bac5eaac337
parent525406597627fb9307425539b86dddf10278eca8 (diff)
metro m7 has issue with cdc_msc example randomly on hil test. Exclude it for now
-rw-r--r--test/hil/hil_test.py11
-rw-r--r--test/hil/rpi.json2
2 files changed, 8 insertions, 5 deletions
diff --git a/test/hil/hil_test.py b/test/hil/hil_test.py
index ff8034b95..c6feb7de2 100644
--- a/test/hil/hil_test.py
+++ b/test/hil/hil_test.py
@@ -88,15 +88,16 @@ def read_disk_file(uid, lun, fname):
timeout = ENUM_TIMEOUT
while timeout:
if os.path.exists(dev):
- fat = fs.open_fs(f'fat://{dev}')
+ fat = fs.open_fs(f'fat://{dev}?read_only=true')
try:
- assert fat.exists(fname), f'File {fname} not found in {dev}'
with fat.open(fname, 'rb') as f:
- return f.read()
+ data = f.read()
finally:
fat.close()
+ assert data, f'Cannot read file {fname} from {dev}'
+ return data
time.sleep(1)
- timeout = timeout - 1
+ timeout -= 1
assert timeout, f'Storage {dev} not existed'
return None
@@ -322,7 +323,7 @@ def test_hid_boot_interface(board):
time.sleep(1)
timeout = timeout - 1
- assert timeout, 'Device not available'
+ assert timeout, 'HID device not available'
def test_hid_composite_freertos(id):
diff --git a/test/hil/rpi.json b/test/hil/rpi.json
index fd00913f3..a4f6073eb 100644
--- a/test/hil/rpi.json
+++ b/test/hil/rpi.json
@@ -17,6 +17,8 @@
{
"name": "metro_m7_1011",
"uid": "9CE8715DD71137363E00005002004200",
+ "tests_skip": ["cdc_msc", "cdc_msc_freertos"],
+ "comment": "Somehow has issue with cdc_msc example randomly",
"flasher": "jlink",
"flasher_sn": "000611000000",
"flasher_args": "-device MIMXRT1011xxx5A"