summaryrefslogtreecommitdiff
path: root/bgproc_tests.py
diff options
context:
space:
mode:
authorLars Wirzenius <liw@liw.fi>2011-05-25 17:18:54 +0100
committerLars Wirzenius <liw@liw.fi>2011-05-25 17:18:54 +0100
commit675238bc117a77a3f30785f085846b70c593bcee (patch)
tree624be85cdeab05e526cd872ed46080f5dacb2374 /bgproc_tests.py
parent818761a95e7701d9ca6c27c8f288b54312043dcc (diff)
downloadbgproc-675238bc117a77a3f30785f085846b70c593bcee.tar.gz
Implement processing, simplistic, synchronous.
This is just to get the API working enough to get a feeling if it works well.
Diffstat (limited to 'bgproc_tests.py')
-rw-r--r--bgproc_tests.py5
1 files changed, 5 insertions, 0 deletions
diff --git a/bgproc_tests.py b/bgproc_tests.py
index 9709636..885a223 100644
--- a/bgproc_tests.py
+++ b/bgproc_tests.py
@@ -45,3 +45,8 @@ class BackgroundProcessingTests(unittest.TestCase):
self.bg.enqueue_request(0)
self.assertEqual(self.bg.pending_requests, 1)
+ def test_processes_stuff(self):
+ self.bg.enqueue_request(0)
+ self.assertEqual(self.bg.wait_for_results(), True)
+ self.assertEqual(list(self.bg), [1])
+