MCPcopy
hub / github.com/owtf/owtf / start_timer

Method start_timer

owtf/utils/timer.py:24–34  ·  view source on GitHub ↗

Adds a start time to the timer :param offset: Timer index :type offset: `str` :return: The start time for the timer :rtype: `datetime`

(self, offset="0")

Source from the content-addressed store, hash-verified

22 self.date_time_format = datetime_format
23
24 def start_timer(self, offset="0"):
25 """ Adds a start time to the timer
26
27 :param offset: Timer index
28 :type offset: `str`
29 :return: The start time for the timer
30 :rtype: `datetime`
31 """
32 self.timers[offset] = {}
33 self.timers[offset]["start"] = self.get_current_date_time()
34 return self.timers[offset]["start"]
35
36 def get_current_date_time_as_str(self):
37 """Returns a datetime object as a string in a particular format

Callers 5

process_pluginMethod · 0.80
RunCommandMethod · 0.80
LogURLsFromStrMethod · 0.80
start_cmdMethod · 0.80
startMethod · 0.80

Calls 1

get_current_date_timeMethod · 0.95

Tested by

no test coverage detected