Author: Armin Rigo <[email protected]>
Branch: bag
Changeset: r1580:93786da12927
Date: 2015-01-24 10:36 +0100
http://bitbucket.org/pypy/stmgc/changeset/93786da12927/
Log: one more passing test
diff --git a/c7/test/test_bag.py b/c7/test/test_bag.py
--- a/c7/test/test_bag.py
+++ b/c7/test/test_bag.py
@@ -67,3 +67,15 @@
assert got == lp2
py.test.raises(BagLooksEmpty, b_pop, q)
py.test.raises(BagLooksEmpty, b_pop, q)
+
+ def test_large_push_pop(self):
+ self.start_transaction()
+ q = self.allocate_bag()
+ lps = [stm_allocate(16) for i in range(65)]
+ for lp in lps:
+ b_add(q, lp)
+ for lp in lps:
+ got = b_pop(q)
+ assert got == lp
+ py.test.raises(BagLooksEmpty, b_pop, q)
+ py.test.raises(BagLooksEmpty, b_pop, q)
_______________________________________________
pypy-commit mailing list
[email protected]
https://mail.python.org/mailman/listinfo/pypy-commit