mirror of
https://github.com/python/cpython.git
synced 2025-11-01 02:38:53 +00:00
parent
0278032110
commit
31f65044a9
2 changed files with 16 additions and 5 deletions
|
|
@ -1160,6 +1160,7 @@ class EventLoopTestsMixin:
|
|||
# FIXME: remove this imports, used for debug purpose (issue #20452)
|
||||
import time
|
||||
import platform
|
||||
import os
|
||||
|
||||
def _run_once():
|
||||
self.loop._run_once_counter += 1
|
||||
|
|
@ -1181,11 +1182,16 @@ class EventLoopTestsMixin:
|
|||
|
||||
self.loop.run_until_complete(wait())
|
||||
calls.append(self.loop._run_once_counter)
|
||||
try:
|
||||
SC_CLK_TCK = os.sysconf('SC_CLK_TCK')
|
||||
except Exception:
|
||||
SC_CLK_TCK = None
|
||||
self.assertEqual(calls, [1, 3, 5, 6],
|
||||
# FIXME: remove these info, used for debug purpose (issue #20452)
|
||||
(self.loop._granularity,
|
||||
self.loop._selector.resolution,
|
||||
time.get_clock_info('monotonic'),
|
||||
SC_CLK_TCK,
|
||||
platform.platform()))
|
||||
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue