Parcourir la source

[2574] commented about faking time.time()

JINMEI Tatuya il y a 12 ans
Parent
commit
217087aad0
1 fichiers modifiés avec 2 ajouts et 0 suppressions
  1. 2 0
      src/bin/loadzone/loadzone.py.in

+ 2 - 0
src/bin/loadzone/loadzone.py.in

@@ -115,6 +115,8 @@ class LoadZoneRunner:
         self._log_debuglevel = 0
         self._report_interval = LOAD_INTERVAL_DEFAULT
         self._start_time = None
+        # This one will be used in (rare) cases where we want to allow tests to
+        # fake time.time()
         self._get_time = time.time
 
         self._config_log()