Skip to content
Snippets Groups Projects
Commit 6684b3d5 authored by Piotr Maślanka's avatar Piotr Maślanka
Browse files

more unit tests

parent 36b21cb9
No related branches found
No related tags found
No related merge requests found
...@@ -56,6 +56,11 @@ class TestConcurrent(unittest.TestCase): ...@@ -56,6 +56,11 @@ class TestConcurrent(unittest.TestCase):
fc = FutureCollection((PythonFuture() for i in range(3))) fc = FutureCollection((PythonFuture() for i in range(3)))
self.assertEqual(len(fc), 3) self.assertEqual(len(fc), 3)
fc.set_running_or_notify_cancel()
fc.set_exception(IndexError())
fc = FutureCollection((PythonFuture() for i in range(3)))
self.assertRaises(WouldWaitMore, lambda: fc.result(0.5))
self.assertRaises(WouldWaitMore, lambda: fc.exception(0.5))
def test_future_collection_callbacks_one(self): def test_future_collection_callbacks_one(self):
a = {'count': 0} a = {'count': 0}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment