summaryrefslogtreecommitdiffstats
path: root/Lib/test/test_selectors.py
diff options
context:
space:
mode:
authorVictor Stinner <victor.stinner@gmail.com>2014-01-25 13:56:48 (GMT)
committerVictor Stinner <victor.stinner@gmail.com>2014-01-25 13:56:48 (GMT)
commit635fca9704b102a97233a3af18231a7b649d0169 (patch)
tree581707f774cffe719a80b08297f0bb9ce5eb342c /Lib/test/test_selectors.py
parent2041859f279423c06a707899b4a66e3f0aba3dfb (diff)
downloadcpython-635fca9704b102a97233a3af18231a7b649d0169.zip
cpython-635fca9704b102a97233a3af18231a7b649d0169.tar.gz
cpython-635fca9704b102a97233a3af18231a7b649d0169.tar.bz2
Issue #20311: selectors: Add a resolution attribute to BaseSelector.
Diffstat (limited to 'Lib/test/test_selectors.py')
-rw-r--r--Lib/test/test_selectors.py5
1 files changed, 5 insertions, 0 deletions
diff --git a/Lib/test/test_selectors.py b/Lib/test/test_selectors.py
index 5292904..f7e84b7 100644
--- a/Lib/test/test_selectors.py
+++ b/Lib/test/test_selectors.py
@@ -363,6 +363,11 @@ class BaseSelectorTestCase(unittest.TestCase):
self.assertFalse(s.select(2))
self.assertLess(time() - t, 2.5)
+ def test_resolution(self):
+ s = self.SELECTOR()
+ self.assertIsInstance(s.resolution, (int, float))
+ self.assertGreater(s.resolution, 0.0)
+
class ScalableSelectorMixIn: