Tools: autotest: raise exception on get_parameter failure

This commit is contained in:
Peter Barker 2018-10-09 13:53:28 +11:00 committed by Peter Barker
parent 6585b6036d
commit 8985cc05c7

View File

@ -663,8 +663,8 @@ class AutoTest(ABC):
self.mavproxy.expect("%s = ([-0-9.]*)\r\n" % (name,), timeout=timeout/retry) self.mavproxy.expect("%s = ([-0-9.]*)\r\n" % (name,), timeout=timeout/retry)
return float(self.mavproxy.match.group(1)) return float(self.mavproxy.match.group(1))
except pexpect.TIMEOUT: except pexpect.TIMEOUT:
if i < retry: pass
continue raise NotAchievedException("Failed to retrieve parameter")
def context_get(self): def context_get(self):
"""Get Saved parameters.""" """Get Saved parameters."""