File tree Expand file tree Collapse file tree 3 files changed +14
-4
lines changed
Expand file tree Collapse file tree 3 files changed +14
-4
lines changed Original file line number Diff line number Diff line change @@ -291,7 +291,14 @@ jobs:
291291
292292 - name : Test on actual hardware
293293 run : |
294- python3 test/hil/hil_test.py ${{ env.HIL_JSON }} $SKIP_BOARDS
294+ python3 test/hil/hil_test.py ${{ env.HIL_JSON }} $SKIP_BOARDS || \
295+ (if [ -f "${{ env.HIL_JSON }}.skip" ]; then
296+ SKIP_BOARDS=$(cat "${{ env.HIL_JSON }}.skip")
297+ echo "Re-running with SKIP_BOARDS=$SKIP_BOARDS"
298+ python3 test/hil/hil_test.py ${{ env.HIL_JSON }} $SKIP_BOARDS
299+ else
300+ exit 1
301+ fi)
295302
296303 # ---------------------------------------
297304 # Hardware in the loop (HIL)
Original file line number Diff line number Diff line change 66
77jobs :
88 claude-review :
9+ if : false
910 runs-on : ubuntu-latest
1011 permissions :
1112 contents : read
Original file line number Diff line number Diff line change @@ -153,14 +153,16 @@ def open_mtp_dev(uid):
153153 # MTP seems to take a while to enumerate
154154 timeout = 2 * ENUM_TIMEOUT
155155 while timeout > 0 :
156- # run_cmd(f"gio mount -u mtp://TinyUsb_TinyUsb_Device_{uid}/")
156+ # unmount gio/gvfs MTP mount which blocks libmtp from accessing the device
157+ subprocess .run (f"gio mount -u mtp://TinyUsb_TinyUsb_Device_{ uid } /" ,
158+ shell = True , stdout = subprocess .DEVNULL , stderr = subprocess .DEVNULL )
157159 for raw in mtp .detect_devices ():
158160 mtp .device = mtp .mtp .LIBMTP_Open_Raw_Device (ctypes .byref (raw ))
159161 if mtp .device :
160162 sn = mtp .get_serialnumber ().decode ('utf-8' )
161- #print(f'mtp serial = {sn}')
162163 if sn == uid :
163164 return mtp
165+ mtp .disconnect ()
164166 time .sleep (1 )
165167 timeout -= 1
166168 return None
@@ -753,7 +755,7 @@ def test_device_mtp(board):
753755 'device/cdc_msc_freertos' ,
754756 'device/hid_boot_interface' ,
755757 'device/printer_to_cdc' ,
756- # 'device/mtp'
758+ 'device/mtp'
757759]
758760
759761dual_tests = [
You can’t perform that action at this time.
0 commit comments