How to detect/handle USB device disconnect during test run?

393 views Asked by At

So I'm currently working on a method to enable/disable USB tethering via API. I have the code working perfectly; however, when changing the USB tethering state the device disconnects then reconnects briefly.

This small hiccup causes my test runs to fail with the message:

"Test failed to run to completion. Reason: 'Test run failed to complete. Expected 1 tests, received 0"

So my question is, is there any way to handle disconnects in such a way that it won't fail the test?

0

There are 0 answers