autotest: explicltly dis/reconnect when customising commandline

We *know* the connection is going away, so wecan force the reconnect rather than waiting for mavtcp's reconnect logic to kick in
This commit is contained in:
Peter Barker 2022-08-26 13:03:32 +10:00 committed by Peter Barker
parent 1f430daef6
commit b6c4930b3a

View File

@ -2517,11 +2517,13 @@ class AutoTest(ABC):
set_streamrate_callback=None):
'''customisations could be "--uartF=sim:nmea" '''
self.contexts[-1].sitl_commandline_customised = True
self.mav.close()
self.stop_SITL()
self.start_SITL(model=model,
defaults_filepath=defaults_filepath,
customisations=customisations,
wipe=wipe)
self.mav.do_connect()
tstart = time.time()
while True:
if time.time() - tstart > 30: