diff --git a/scripts/tests/chiptest/test_definition.py b/scripts/tests/chiptest/test_definition.py index 8b622cc194bbff..304454d600ea1d 100644 --- a/scripts/tests/chiptest/test_definition.py +++ b/scripts/tests/chiptest/test_definition.py @@ -69,21 +69,32 @@ def stop(self): return False def factoryReset(self): + reset_start = time.monotonic() logging.error("FACTORY RESET: %s" % self.command) logging.error("self.killed: %s" % self.killed) + stop_start = time.monotonic() wasRunning = (not self.killed) and self.stop() - logging.error("wasRunning: %s" % wasRunning) + stop_end = time.monotonic() + logging.error("wasRunning: %s, took %s to stop" % (wasRunning, stop_end - stop_start)) for kvs in self.kvsPathSet: if os.path.exists(kvs): - logging.error("UNLINKING: %s" % kvs) + unlink_start = time.monotonic() os.unlink(kvs) + unlink_end = time.monotonic() + logging.error("UNLINKING: %s, took %s" % (kvs, unlink_start - unlink_end)) if wasRunning: + start_start = time.monotonic() started = self.start() - logging.error("STARTED: %s" % started) + start_end = time.monotonic() + logging.error("STARTED: %s in %s" % (started, start_end - start_start)) + reset_end = time.monotonic() + logging.error("RESET DONE, took %s" % (reset_end - reset_start)) return started + reset_end = time.monotonic() + logging.error("RESET DONE, took %s" % (reset_end - reset_start)) return True def waitForAnyAdvertisement(self):