コード例 #1
0
 def testGetWinNowFunction_QPC(self):
   if not (sys.platform.startswith(trace_time._PLATFORMS['windows'])
           or sys.platform.startswith(trace_time._PLATFORMS['cygwin'])):
     return True
   # Test requires QPC to be available on platform.
   if not trace_time.IsQPCUsable():
     return True
   self.assertGreater(trace_time.monotonic(), 0)
コード例 #2
0
 def testGetWinNowFunction_GetTickCount(self):
   if not (sys.platform.startswith(trace_time._PLATFORMS['windows'])
           or sys.platform.startswith(trace_time._PLATFORMS['cygwin'])):
     return True
   with self.ReplaceQPCCheck(lambda: False):
     self.assertGreater(trace_time.monotonic(), 0)