mirror of
https://github.com/python/cpython.git
synced 2026-01-06 15:32:22 +00:00
Issue #20311: add debug help in test_selectors
This commit is contained in:
parent
c520edc08b
commit
da94b9ebeb
1 changed files with 5 additions and 2 deletions
|
|
@ -5,7 +5,7 @@
|
|||
import signal
|
||||
import socket
|
||||
from test import support
|
||||
from time import sleep, perf_counter
|
||||
from time import sleep, perf_counter, get_clock_info
|
||||
import unittest
|
||||
import unittest.mock
|
||||
try:
|
||||
|
|
@ -377,7 +377,10 @@ def test_timeout_rounding(self):
|
|||
t0 = perf_counter()
|
||||
s.select(timeout)
|
||||
dt = perf_counter() - t0
|
||||
self.assertGreaterEqual(dt, timeout)
|
||||
clock = get_clock_info('perf_counter')
|
||||
self.assertGreaterEqual(dt, timeout,
|
||||
"%.30f < %.30f ; clock=%s"
|
||||
% (dt, timeout, clock))
|
||||
|
||||
|
||||
class ScalableSelectorMixIn:
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue