diff options
| author | Ryan Williams <rdw@lindenlab.com> | 2010-02-20 14:29:02 -0500 |
|---|---|---|
| committer | Ryan Williams <rdw@lindenlab.com> | 2010-02-20 14:29:02 -0500 |
| commit | 46234611411f75294acce37e8f3a56b409786c40 (patch) | |
| tree | eee11d40113592afca6c59c627e909aeaa852608 /tests/semaphore_test.py | |
| parent | 092b17ce9fee6aa2619ce6805fb7bb2651eda248 (diff) | |
| download | eventlet-46234611411f75294acce37e8f3a56b409786c40.tar.gz | |
Documented the hell out of semaphore, noticed that BoundedSemaphore had the wrong semantics so created a new BoundedSemaphore, renaming the old to CappedSemaphore, to correct for that.
Diffstat (limited to 'tests/semaphore_test.py')
| -rw-r--r-- | tests/semaphore_test.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/tests/semaphore_test.py b/tests/semaphore_test.py index 131c0be..64153ed 100644 --- a/tests/semaphore_test.py +++ b/tests/semaphore_test.py @@ -5,7 +5,7 @@ from tests import LimitedTestCase class TestSemaphore(LimitedTestCase): def test_bounded(self): - sem = semaphore.BoundedSemaphore(2, limit=3) + sem = semaphore.CappedSemaphore(2, limit=3) self.assertEqual(sem.acquire(), True) self.assertEqual(sem.acquire(), True) gt1 = eventlet.spawn(sem.release) @@ -21,7 +21,7 @@ class TestSemaphore(LimitedTestCase): gt2.wait() def test_bounded_with_zero_limit(self): - sem = semaphore.BoundedSemaphore(0, 0) + sem = semaphore.CappedSemaphore(0, 0) gt = eventlet.spawn(sem.acquire) sem.release() gt.wait() |
