def _get_exe_status(self): try: status = str(pykd.getExecutionStatus()) return status except Exception as err: self.logger.debug("Can't get process execution status because of: %s" % err) return None
def _state(self): """ Get the state of a given target. Internal use. """ s = pykd.getExecutionStatus() if s == pykd.executionStatus.Break: state = 'stopped' elif s == pykd.executionStatus.Go: state = 'running' else: state = 'invalid' return state
def testExecutionStatus(self): self.assertEqual(pykd.DEBUG_STATUS_BREAK, pykd.getExecutionStatus()) pykd.setExecutionStatus(pykd.DEBUG_STATUS_GO) pykd.waitForEvent() self.assertEqual(pykd.DEBUG_STATUS_BREAK, pykd.getExecutionStatus())